Table

R

Rick

Just started using Access. I key in 15-20 new records in
my form then go to table and they are not in the same
order in the table that I keyed them in originally. I
need to keep them in the same order. What am I doing to
cause the rows/records in the table to switch their order?
 
R

Rick Brandt

Rick said:
Just started using Access. I key in 15-20 new records in
my form then go to table and they are not in the same
order in the table that I keyed them in originally. I
need to keep them in the same order. What am I doing to
cause the rows/records in the table to switch their order?

Tables in relational databases are by definition, unordered. If you need
to see or interact with records in a particular order then you need to use
a Query with an explicit ORDER BY clause (which is nothing more than
specifying a sort order in the query builder).

To that end you will need *data* that can be used to determine the entry
order. Either an incrementing number field where every new record is
guaranteed to have a value higher than all previous records or you need to
record the Date and Time for each record insertion (the latter is more
reliable). The query can sort on that data to give you a listing in data
entry order.

My suggestion would be to add a DateTime field named "EntryDate" or similar
and assign a default value of Now().
 
V

Van T. Dinh

Records are stored *unordered* in the Table. If you want them to appear in
a particular order in your Form, use a Query with Order By Clause (to sort
the Records the way you want) as the RecordSource for your Form.

Alternatively, you can use the OrderBy and OrderByOn Property of the Form.

Check Access Help on the special terms mentioned above.
 

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