I am creating a query to find unmatched rows between a local access table and an online MS SQL Server table based on the PK field ID. This is working without any flaws. My problems start when I run a append query with INSERT INTO based on the result of the former. I get the following error:
"Database set 0 field(s) to null due to a type conversion failure and it didnt add 1 record(s) to the table due to key violations, 0 record(s)due to lock violations, and 0 record(s) due to validations rule violations...."
I have enclosed an screen dump of the error
The strange thing is that query fires normally after a while!! My other append and update queries dont have this problem, I have also a append query going in the oppisite direction, from the online SQL table to the local Access table, and this error does not show up in that case.
I have two tables for the export to the online tables, one is the parent table and a child table, I see to it that the parent table gets upploaded before the child table, I do this in a macro, could it be a problem with the parent table not being able to uploaded before the child table event fires? Is it poosible to have som time delay in between? if this could be the issue?
I got this response on of the forums: "Perhaps a timing problem. The "parent" record gets added later or it gets "cached" on the SQL server and not "posted" until a bit later."
Is there a macro o vba code I could initiate to paus after the first query for a predifined amount of time? I am able to fire both the queries at a later time. I also see to it that the parent table is uploaded first and the the child has a FK for the parent table, so it cant be a issue with reference keys, because the record is saved locally without any problem
thanks
-Sohail
"Database set 0 field(s) to null due to a type conversion failure and it didnt add 1 record(s) to the table due to key violations, 0 record(s)due to lock violations, and 0 record(s) due to validations rule violations...."
I have enclosed an screen dump of the error
The strange thing is that query fires normally after a while!! My other append and update queries dont have this problem, I have also a append query going in the oppisite direction, from the online SQL table to the local Access table, and this error does not show up in that case.
I have two tables for the export to the online tables, one is the parent table and a child table, I see to it that the parent table gets upploaded before the child table, I do this in a macro, could it be a problem with the parent table not being able to uploaded before the child table event fires? Is it poosible to have som time delay in between? if this could be the issue?
I got this response on of the forums: "Perhaps a timing problem. The "parent" record gets added later or it gets "cached" on the SQL server and not "posted" until a bit later."
Is there a macro o vba code I could initiate to paus after the first query for a predifined amount of time? I am able to fire both the queries at a later time. I also see to it that the parent table is uploaded first and the the child has a FK for the parent table, so it cant be a issue with reference keys, because the record is saved locally without any problem
thanks
-Sohail