Page 1 of 1

Inserting records into different tables from a single Input

Posted: Tue Sep 13, 2005 9:39 pm
by pkdash25
Hi,

My input is an XML type data and for each record there are 3 different fields are present (Author, Subject, BookName) and the Output is MS Access Database. I have 3 different tables in the database, each to handle the corresponding records for each subject.

For my Input, there are 5 records, with 3 different Subjects. So, I want the records should be inserted through 3 tables based on the subject value for each record.

I have passed each record in the Functional Map (F_Map) and used Insert statement in DBLOOKUP Statement. But, I am not getting any record in tables neither any .dbl file getting created even though I have passed -TRACE command option and set the uodate keys for each of those table in the .MDQ File. I am specifiying the rules for the Functional Map:
DBQUERY("INSERT INTO " + Subject:ElemDecl Books:Input +" (Author, BookName) VALUES ('"+ Author:ElemDecl Books:Input + "','" + Title:ElemDecl Books:Input + "')","-MDQ SampleMDQ.mdq -DBNAME SampleDB -UPDATE -TRACE")

Kindly suggest me something to get solution for this.

Thanks in advance,
Pranab

Posted: Wed Sep 14, 2005 2:47 am
by janhess
If you are not getting any trace or records in the table, I would suggest that the map is never performing the functional map. Functional maps will only be actioned if all the defined parameters are present.
It might be worth posting your rule for calling the functional map.