Re: Forcing a sequence in a table
From: John Nurick (j.mapSoN.nurick_at_dial.pipex.com)
Date: 06/01/04
- Next message: John Nurick: "Re: Deleting/creating Database"
- Previous message: Beth Hulbert: "Creating mailing list and labels"
- In reply to: Victor Boris Arnold: "Forcing a sequence in a table"
- Next in thread: Adrian Jansen: "Re: Forcing a sequence in a table"
- Reply: Adrian Jansen: "Re: Forcing a sequence in a table"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 01 Jun 2004 22:09:13 +0100
Hi Victor,
One of the consequences of a table having no inherent order is that
there is no guarantee that the records will appear in the same order
each time you look at them.
This means that you cannot meaningfully speak of inserting a new row
"between" two existing ones unless there is some key, a field or
combination of fields, on which the records are already sorted.
If you need to create one, consider using a Double field, I'll call it
SortOrder. Add it to the table and use some code to insert values in
order 1.00, 2.00, 3.00...
Then when inserting a record "between" two others, get the SortOrder
values from those two and give the new record a SortOrder that is the
average of the two.
On Tue, 1 Jun 2004 10:09:10 -0700, "Victor Boris Arnold"
<anonymous@discussions.microsoft.com> wrote:
>I understand that the rows in a table have no inherent
>sequence, but I'm wondering if anyone has come up with a
>successful scheme to do just that.
>
>Let's say I have two rows in my table and want to insert
>another row, then be able to present all the rows as if
>the new row was inserted in between the two existing rows.
>(There would not be a field that is entered by the user
>that would allow sorting these rows in the desired
>sequence.)
-- John Nurick [Microsoft Access MVP] Please respond in the newgroup and not by email.
- Next message: John Nurick: "Re: Deleting/creating Database"
- Previous message: Beth Hulbert: "Creating mailing list and labels"
- In reply to: Victor Boris Arnold: "Forcing a sequence in a table"
- Next in thread: Adrian Jansen: "Re: Forcing a sequence in a table"
- Reply: Adrian Jansen: "Re: Forcing a sequence in a table"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|