Hi All,
I need to insert new records in existing Tables of Access. The two tables are related by Primary and Foreign key relation. The new data to be imported is in Excel sheet which I have imported into new table.
Now,
Some columns needs to be inserted into Parent table and some would be inserted to child table.
The parent table has an automatically incremented ID column which is foreign key for the child table.
The insert into Parent table works fine but nothing's happening when I try to append records to the child table.
I used this query to insert values into child tables foreign key from parent tables primary key.
No-Luck. :(
INSERT INTO ChildTable(FID)
SELECT ID
FROM Parent table
WHERE ID > 4430
NOTE: 4430 is the last number that existed in both tables before my inserts to the Parent table.
Can anyone help me ?
Thanks very much !!
I need to insert new records in existing Tables of Access. The two tables are related by Primary and Foreign key relation. The new data to be imported is in Excel sheet which I have imported into new table.
Now,
Some columns needs to be inserted into Parent table and some would be inserted to child table.
The parent table has an automatically incremented ID column which is foreign key for the child table.
The insert into Parent table works fine but nothing's happening when I try to append records to the child table.
I used this query to insert values into child tables foreign key from parent tables primary key.
No-Luck. :(
INSERT INTO ChildTable(FID)
SELECT ID
FROM Parent table
WHERE ID > 4430
NOTE: 4430 is the last number that existed in both tables before my inserts to the Parent table.
Can anyone help me ?
Thanks very much !!
Comment