>I'm using VFP tables in a VFP Database accessing through local views also in the VFP Database. When I add a new record to the table using cListObjEdit class it seems to be triggering the newid() stored procedure when adding a new record to the view and newid() triggers again when the tableupdate() command is issued.
>
>This is causing a problem when I'm a parent/child relationship and adding to both. I can't seem to get the correct unique id's to jive, hence no relation.
>
>I'd appreciate the help... thanks
>
>Vic
Vic,
Not sure if I have this right, but are you saying the newid() stored procedure is firing twice, once for the parent table and then a second time for the child table? If so, this is correct procedure to ensure unique id's in each table. In a parent/child relationship, you need to add another field to the child table, something like parentid. Then when you go to save changes, the parent table has a unique id, which you can store to a child(s) record in the parentid field. Each child record though will have it's own unique id to ensure the primary index of that table.
Kind Regards,
Mat