General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
>I would like to create a SQL query in which one column contains a counter that increments by one for each record in the query result. This would be just like the count function which can be set for a report in the report designer. However I can't seem to find any function that would generate the numbers into the query result. As this must have come up at other times, I am hoping that some one might be able to give me an idea in this regard.
>
>Thanks
>
>Porter Bailey
Sometimes SQL is not always the answer. Although it is possible to do what you want with a function it would probably be easier to add a column for what you want and do a simple SCAN ... ENDSCAN to fill in the value of your counter.
HTH
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only