Insert record always at the end of db ???? 
Author Message
 Insert record always at the end of db ????

Hi All,

When I insert a new record in a DBase IV database somewhere in the
middle of the table (which is not indexed) The record is always posted

to the end of the database.
Even when I programmatically insert a new record (with InsertRecord).
The help file states that InsertRecord inserts the record at the
cursor position (which it doesn't).
I don't want to use an index but physically insert a record at a
specific place.
Anyone knows how ??

Thanks in advance.

Frank Vogel



Wed, 18 Jun 1902 08:00:00 GMT  
 Insert record always at the end of db ????
I think the phrase "cursor position" is the problem. The help file
states:

"For unindexed Paradox and dBASE tables, the record is inserted into
the dataset at the current cursor position."

However, if you read further:

"The newly inserted record becomes the current record."

I think it adds the record at the end (as you stated) then moves the
cursor to the new record (so it is now at the current cursor
position). I don't think it has any idea what the BDE physically does
with the record.

It makes sense too. Say you have a 900MB file. You gonna move 900MB of
data just to insert one record physically at the front? Thats what
indexes are for.

Scott

Quote:

>Hi All,

>When I insert a new record in a DBase IV database somewhere in the
>middle of the table (which is not indexed) The record is always
posted

>to the end of the database.
>Even when I programmatically insert a new record (with InsertRecord).
>The help file states that InsertRecord inserts the record at the
>cursor position (which it doesn't).
>I don't want to use an index but physically insert a record at a
>specific place.
>Anyone knows how ??

>Thanks in advance.

>Frank Vogel



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Retrieving Serial Key from record inserted into Informix DB from Delphi 1

2. Updating/ Inserting Records into Informix DB

3. Inserting a DB lLook Up Combo Box into a DB Grid

4. how to return always the same record num.?

5. want better DB front-end

6. FindKey does not always find a record

7. best inexpensive, DB Front End Development tool ?

8. copying data from one record to the next when inserting a new record

9. Moving a pointer to the end of a record file

10. Trap Insert Key in DB Grid

11. Accessing data from one db and insert them to another

12. Insert in a DB

 

 
Powered by phpBB® Forum Software