Table sort order

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

Guest

I am writing records to a table through a adodb connection using a string SQL
statement and for some reason the records do not stay in the same order that
they are placed in the table, the table is not Indexed and I cannot get them
to stay in the original order
 
David said:
I am writing records to a table through a adodb connection using a
string SQL statement and for some reason the records do not stay in
the same order that they are placed in the table, the table is not
Indexed and I cannot get them to stay in the original order

Data is not maintained in any order in a table. That is what queries
are for. In a database a table is like a bucket holding data. If you want
"original" order you need to provide some sort of data that can be sorted to
provide that order. That may be a date created or a incremental number
added at the time the record is created.

Note: autonumber is not your answer as autonumber is designed to provide
unique number not consecutive numbers.

After that you can use a query to sort on that field and base any forms
etc you like on that query.
 
Data in a table is not guaranteed to be in any specific order. (Part of the
definition of a table in relational theory is that it is an unordered set of
rows). If you need the data in a specific order, you need to specify the
required order in the ORDER BY clause when retrieving the data.
 

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

Back
Top