cyberfly 1 Report post Posted April 4, 2008 Table markahSeperti gmbar diatas,aku perlu mencari History Peserta tersebut dalam table markah.(berapa kali dia telah menyertai pertandingan).Masalah sekarang :1.dalam table markah tu,mungkin ada idPeserta yg sama,tetapi mungkin idFormat atau idPertandingan yg berlainan.2.so kalau blh,nak count dari berdasarkan idPertandingan tu,tapi camne kalau dlm tble markah tu ada ada jgk data yg mempunyai idPeserta dan idPertandingan yg sama?Sape2 blh tlg englighten aku Quote Share this post Link to post Share on other sites
ejoe 0 Report post Posted April 5, 2008 erk aku tak nampak sebarang masalah kat sini kalo idPeserta, idFormat, idPertandingan dah ader... or aku yg tak faham hehe Quote Share this post Link to post Share on other sites
cyberfly 1 Report post Posted April 5, 2008 erk aku tak nampak sebarang masalah kat sini kalo idPeserta, idFormat, idPertandingan dah ader... or aku yg tak faham heheerk..aku pn dah tukar lojik.sebenarnya kalau blh kalau pertandingan sama,aku taknak view.just nak count jer.last2 aku tukar lojik aku kepada list semua acara dan pertandingan yg dia masuk.count tu pandai2 org yg tgk la camne. Quote Share this post Link to post Share on other sites
ejoe 0 Report post Posted April 5, 2008 kalo nak cari yg sama bleh guna DISTINCTSQL DISTINCTThe SQL DISTINCT command used along with the SELECT keyword retrieves only unique data entries depending on the column list you have specified after it. ...www.sql-tutorial.com/sql-distinct-sql-tutorial/ Quote Share this post Link to post Share on other sites
cyberfly 1 Report post Posted April 6, 2008 kalo nak cari yg sama bleh guna DISTINCTthanks Ejoe.tambah satu ilmu baru. Quote Share this post Link to post Share on other sites