It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming Java Forum

I am reading an xml file content successfully but the proble

I am reading an xml file content successfully but the proble

Postby sasi on Thu Aug 30, 2007 7:25 am

Hello everybody plz tell me some solution regarding xml file reading,

I am reading the content in the xml file of a customer data successfully and placing the data into the database but i have to eliminate the duplicate records. how can i get the distinct values from the xml file. Means I dont want the data of the same records with in the 2 or more records.

The xml file contains around 14 colums.

plz tell me the solution.
sasi
 
Posts: 13
Joined: Mon Apr 23, 2007 1:10 pm

Postby nanair01 on Tue Sep 04, 2007 11:47 am

i think this can be done in ur dtd file..... or r u using XML schema for parsing? ok lemm etell u about dtd file.... In the dtd file there is a field where u can specify whether the value needs to be unique or not.....
+ ===> must appear atleast once
* ====> can appear any number of times including 0
there is one more operator but i don exactly remember... refer ur dtd and make appropriate chnages...
====================================================
or another option is to store the data in a SET coz SET data type doesnt allow duplicate elements.. Get back to me in case of any doubts
nanair01
 
Posts: 4
Joined: Tue Sep 04, 2007 11:31 am
Location: india


Who is online

Users browsing this forum: No registered users and 2 guests