Sql Get the last 6 -


I need a SQL query that also uses the record ID to get the number of times for the last 6 times of the trip. Does. / P>

The records in the table are of the following types,

 RecordInd notphotite day and time 1001 1 12/11/2009 14:11 1001 2 13/11/2009 12:11 1001 3 14 / 11/2009 11:11 1001 4 16/11/2009 14:11 1001 5 17/11/2009 14:11 1001 6 20/11/2009 13:11 1001 7 25/11/2009 09:11 

I need a query that only shows the last 6 vist and in one line.

If you are working with SQL Server

  And select from the top 6 record id, no overtime, day and time by DESC  
.

Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

jquery - SimpleModal Confirm fails to submit form -

php - Multiple Select with Explode: only returns the word "Array" -