Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to insert a record in a table ?
Message
From
09/02/2005 03:57:13
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00984818
Message ID:
00985040
Views:
42
For this to work, you need to have the table opend exclusively. Then, behind the scene VFP will internally
1. copy record 1-4 to a temp table
2. use the temp table
3. add the blank record to the temp table
4. append the rest of the records from the original table
5. delete the original table
6. rename the temp table to the original table's name

Or the routine may be in a different order, but there is a lot of work going on behind the scene to insert one record. Also note that INSERT BLANK is not mentioned in help anymore, which is with a good reason. So the really GOOD answer is NO, use indexes, and NEVER rely on the record numbers. But of course, technically your answer is correct, but I am in favour of teaching people how they should do it, even though it sometimes means that they have to rethink a little bit.

>>how to insert a record in a table ? for example i want to insert a record between row 4 and 5. how to do it ?
>
>GO RECORD 4
>INSERT BLANK
>* "BLANK" means do not open an editing window.
Previous
Reply
Map
View

Click here to load this message in the networking platform