Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

help needed in finding last 24 records

Status
Not open for further replies.

tecassitant

Technical User
Dec 30, 2002
32
US
i have a database which has fields like stocknumber,grn_dt,po_dt
now i want to see last 24 records for one stock number.for criteria consideration we can use grn_dt.i think this should be possible.
any help appreciated.

learn something new everyday!!!!!!!!!!!!!!!
 
What's grn_dt??

Hopefully not something obvious or won't i look silly :)

Try something like

Select top 24 fieldname
from tablename
orderby stocknumber DESC

Transcend
[gorgeous]
 

[tt]select top 24
stocknumber,grn_dt,po_dt
from yourtable
where stocknumber = 'foo'
order by grn_dt desc[/tt]


rudy
 
hey thankx i have a combo box for stock+_no and i want to make a graph for the list of item s i the combo and i want the graph to get changed when i select a stock_no from the combo bow help me out if anyone knows
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top