XML to MSAccess ...

hello !I Have to store the data from XML file to MSAccess without duplication .... i have done this , using array but when the data are large , using array is a tedious job ... so i need a code without using array ... can any one help me ?
[253 byte] By [suresh_segara] at [2007-11-26 16:32:32]
# 1
USE DOM PARSER TO PARSE AN XML FILE , AND THEN TRANSFER THE DATA FROM DOM TO MS-ACESS
JDOMa at 2007-7-8 22:57:10 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 2
thanks , i did it but i have stored the data in the array using DOM and then i have transfered it to ACESSS ... is there any way to elimate the array in this stage .regards ,S.Suresh Kumar
suresh_segara at 2007-7-8 22:57:10 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 3

If you want to skip duplicates, then regardless of the fact the data is coming from XML, and regardless of the fact that you are writing it to MS Access, you must have a list of the distinct items you have already seen, so you can tell whether a new item is a duplicate of any of them.

I would use a Map for that and not an array, because unless you screw it up the lookup time is O(1) instead of O(N), but in any case you still need the list of distinct items somewhere. If it's overflowing your available memory (you didn't really describe your problem) then you could use the data you have already written to the database as the list of distinct items. Slower but uses less memory.

DrClapa at 2007-7-8 22:57:10 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...