How to customize the numbering in a query?

  • Thread starter Thread starter Jon
  • Start date Start date
J

Jon

I want to customize the numbering in a query. In other word, I want to make
customized numbering in a column in query but as formatted below:
001
002
003
…
…
etc
any help please?
 
Hello Jon,

The table in your query must contain a unique index such as an autonumer
field. As an example in a report of customers, CustomerID would be a unique
field used in the query.
Example: To list all customers in the table, "TblCustomer" and auto number
the output rows, you would enter the following in a blank field of the
customers query:
RowNum: (Select Count (*) FROM [TblCustomer] as Temp
WHERE [Temp].[CustomerID] < [TblCustomer].[CustomerID])+1

To get the format you want, you would then need to add another field to your
query:
CustomRowNum:Format([RowNum],"000")

Steve
(e-mail address removed)
 
On Sat, 22 May 2010 19:18:58 -0400,
Hello Jon,

The table in your query must contain a unique index such as an autonumer
field. As an example in a report of customers, CustomerID would be a unique
field used in the query.
Example: To list all customers in the table, "TblCustomer" and auto number
the output rows, you would enter the following in a blank field of the
customers query:
RowNum: (Select Count (*) FROM [TblCustomer] as Temp
WHERE [Temp].[CustomerID] < [TblCustomer].[CustomerID])+1

To get the format you want, you would then need to add another field to your
query:
CustomRowNum:Format([RowNum],"000")

Steve
(e-mail address removed)


Jon said:
I want to customize the numbering in a query. In other word, I want to make
customized numbering in a column in query but as formatted below:
001
002
003
.
.
etc
any help please?
test
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Auto Generate Primary Field Value 5
Record output in queries 1
Numbering documents (revised) 1
Extraction of Dates 4
Number Format 7
form combo box question 4
ADDRESS LABELS 1
Data Access Page - Subtotal 4

Back
Top