class Importer : problem with getImportedIDs method

User 48bff09cff

22-03-2007 09:14:14

Hi,





I use JChem Base to stock in a database a lot of molecules. Then, I use ConnectionHandler to connect in my database and after I use Importer class to import all molecules grouped in a file. My database correctly get all molecules but I would like to know all cd_id for all molecules imported.








I try to use :


Code:



Importer ithread = new Importer();


...


IntArray ia = ithread.getImportedIDs();





My ia.size() is at 0, since my molecules file is well imported in database.





How can I use the getImportedIDs() method ?





Thanks,





Cyrielle

ChemAxon e274e1bada

22-03-2007 17:10:16

Hi Cyrielle,





If you want to get stored cd_ids, you should use setStoreImportedIDs(true) method before you import your compounds.





See API docs: http://chemaxon.com/jchem/doc/api/chemaxon/jchem/db/Importer.html#getImportedIDs()


and http://chemaxon.com/jchem/doc/api/chemaxon/jchem/db/Importer.html#setStoreImportedIDs(boolean)





Sorry if that API descriptions was not obvious, we will improve our API documentation.





Regards,


Edvard