append records without duplicates keys 
Author Message
 append records without duplicates keys

Hi All,

 I need append news records on a table, but I have to heck that the key field do
not exist on the table. With the clipper language this is very easy whit the
'VALID' clause of the 'GET' statement. But I unknow how do it with delphi

 Tanks in advance ...

 F.J. Botellero.



Mon, 23 Nov 1998 03:00:00 GMT  
 append records without duplicates keys

Quote:

> Hi All,

>  I need append news records on a table, but I have to heck that the key field do
> not exist on the table. With the clipper language this is very easy whit the
> 'VALID' clause of the 'GET' statement. But I unknow how do it with delphi

What is your database actualy? Cann't you do with an autoincrement
field?

Jasper

PS: please take into consideration
- when replying, I just think I know;
- when asking, be sure that I don't.



Tue, 24 Nov 1998 03:00:00 GMT  
 append records without duplicates keys

Quote:

> Hi All,

>  I need append news records on a table, but I have to heck that the key field do
> not exist on the table. With the clipper language this is very easy whit the
> 'VALID' clause of the 'GET' statement. But I unknow how do it with delphi

>  Tanks in advance ...

>  F.J. Botellero.

Try this:

  if not MyTable.FindKey['keyvalue'] then AppendRecord;



Wed, 25 Nov 1998 03:00:00 GMT  
 append records without duplicates keys


Quote:

>Hi All,

> I need append news records on a table, but I have to heck that the
key field do
>not exist on the table. With the clipper language this is very easy
whit the
>'VALID' clause of the 'GET' statement. But I unknow how do it with
delphi

> Tanks in advance ...

> F.J. Botellero.

Do a findkey on secondary tTable using the on exit event of the control
you are using for entry.

Ben
Arrow



Fri, 27 Nov 1998 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Changing Key Fields in Master Record without Orphaning Detail Records

2. Help !!! Table.Append =>Record/Key deleted

3. Changing Key Fields Without Orphaning Linked Records

4. Preventing Key Violation for duplicate keys

5. How to append fields to existing tables, without damageing the existing data

6. Duplicate key in paradox table

7. Duplicate Key in DBase

8. How to handle duplicated keys?

9. Duplicate keys

10. Check Duplicate in Primary key?

11. Duplicate key inserted with dBase Unique index

12. duplicate key

 

 
Powered by phpBB® Forum Software