sequential query record numbering

D

DevourU

Viewing a query will show record number and total records in the record
navigator. Can I show the record numbers in the record itself? I have no
uniqueid to work with. I just need to have a
autonumber/sequential/incrementing column. Help? TIA

-JS
 
D

DevourU

I figured it out!
tick: DCount("field1","ABC Table","field1 <='" & [field1] & "'")

-JS
 
D

DevourU

I was too quick on the answer. This returns the record number from the
table, not sequential in my query. D'oh!

-JS

DevourU said:
I figured it out!
tick: DCount("field1","ABC Table","field1 <='" & [field1] & "'")

-JS

DevourU said:
Viewing a query will show record number and total records in the record
navigator. Can I show the record numbers in the record itself? I have no
uniqueid to work with. I just need to have a
autonumber/sequential/incrementing column. Help? TIA

-JS
 
J

John Vinson

I was too quick on the answer. This returns the record number from the
table, not sequential in my query. D'oh!
Ok, if the query is named QueryName:

DCount("field1","QueryName","field1 <='" & [field1] & "'")

Don't expect this to run really fast...

John W. Vinson[MVP]
 
D

DevourU

Hey John, how the heck are ya. I decided that I would try to number the
records, then have the query list all record#'s < Form.unbound value. (I was
the guy trying to limit the amount of query records from a form.unbound
value.)

-JS


John Vinson said:
I was too quick on the answer. This returns the record number from the
table, not sequential in my query. D'oh!
Ok, if the query is named QueryName:

DCount("field1","QueryName","field1 <='" & [field1] & "'")

Don't expect this to run really fast...

John W. Vinson[MVP]
 
D

DevourU

John, I have a question for you. Think of what I'm doing is like ranking
scores (actually dollar values). The counting and sorting I'm doing works,
but occasionally I have a tie, same score, and it effects my results.

SELECT DISTINCT [ABC Cycle Preview].extcost AS ExtStdCost, Sum([ABC Cycle
Preview].extcost) AS SumOfExtCost, Format(DSum("ExtCost","ABC Cycle
Preview","[ExtCost]>=" & [ExtStdCOst] & ""),"0,000.00") AS RS, [ABC Cycle
Preview].descript, [ABC Cycle Preview].onhand, [ABC Cycle Preview].stdcost

This gives me a runningsum in a query. When [ExtCost] hits a duplicate, RS
does not change. Got an idea? TIA!

-JS

John Vinson said:
I was too quick on the answer. This returns the record number from the
table, not sequential in my query. D'oh!
Ok, if the query is named QueryName:

DCount("field1","QueryName","field1 <='" & [field1] & "'")

Don't expect this to run really fast...

John W. Vinson[MVP]
 

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

Top