ms access - Select only some rows from database -


i have following query:

string query = string.format("select articlename tblarticles userid={0} order postdate desc", userid); 

i want not more 3 different values 'articlename'.
possible that? (without select 'articlename' 3 of them?)

thanks.

typically can use limit 3 @ end of query achieve this

string query = string.format(     "select articlename tblarticleas userid={0} order postdate desc limit 3",     userid ); 

or microsoft access db apparently need use top 3 @ start instead, eg:

string query = string.format(     "select top 3 articlename tblarticleas userid={0} order postdate desc",     userid ); 

Popular posts from this blog

How to calculate SNR of signals in MATLAB? -

java - How to create Table using Apache PDFBox -

mpi - Why is MPI_Bsend not returning error even when the buffer is insufficient to accommodate all the messages -