record numbers

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I ahve a need to do thefollowing:

When I retrieve records in a query, i need a field within the query that is
the current record number retrieved (of the query not of any of the
underlying tables),,, ie if 10 records are retrieved i need a field that
says it is record nubmer x of the records retrieved. helppppppp
 
A query just sorts / filters / collates data.When you present it, it's done
via a form or report and that's where the sequence number is best displayed.

If you need it in a query, for example you are exporting the data, use a
dcount. Try this in NWind to demonstrate

SELECT Customers.CompanyName, Customers.CustomerID,
DCount("*","Customers","CustomerID<='" & [CustomerID] & "'") AS Expr1
FROM Customers;


PS if the field you use for the Order By is numeric, remove the additional
quotes
 
Back
Top