Importing XML into database
Hi All
I have to import data(present in csv file format) into database.
The csv data is first converted to a XML file .Then transformed to another XML file , the resolution of keys takes place and then loaded into databse.
Precisely the steps are:
csv to xml1,xml1 to xml2,xml2 to xml3
and xml3 loaded to db
xml1 to xml2 uses a xsl file
The requirement is to create a mapping of input data(coming from csv format) to database table column specified .This mapping is done in xsl file used in transformation(xml1 to xml2).
The xsl file has to be written in a manner so that loading data doesnot fails(coming from csv file) due to relationships(PK,FK or other constraints).But I am not able to handle these relationships in my xsl file.
Hence getting an error:
The insert or update value of the FOREIGN KEY "ADMINISTRATOR.CATENTRY.F_204" is not equal to any value of the parent key of the parent table. SQLSTATE=23503
on record [catentry: [CATENTRY_ID=13651][MEMBER_ID=-700][CATENTTYPE_ID=AP01][PARTNUMBER=MFCS01-CD][MARKFORDELETE=0]]. [sqlcode: -530, sqlstate: 23503]
Looking for suh=ggestions soon,its high priority
Cheers
Ritu
|