Develpment Quetion impor gz file

User 0f28873a29

23-02-2008 15:03:33


I have some quetion related with the chemaxon, perhaps this is a developer quetion.

-First of all I'll want to import a gz file (mol2) to my own database.

- I'll want to take from each molecule the @<TRIPOS>MOLECULE


the field of name of molecule to insert in the database.

- I'll want to take the offset of the molecule in the file to insert.

Are these things posible.

Thanks for all.


ChemAxon fa971619eb

23-02-2008 17:03:02

I don't think this is directly possible as IJC does not currently support import of Tripos mol2 format files.

However, I think there are ways of doing this. Firstly I would look at using the molconvert program

With this you can convert the format to SDF or MRV which are supported by


And if this is sufficient then you could possibly write a small program using the Marvin API that would reformat the file as needed.The main class you would need to use is MolImporter:

I hope one of these options helps.

If you can provide a sample file then we might be able to assist further.


User 0f28873a29

23-02-2008 19:11:46

Thanks for all...

User 0f28873a29

27-02-2008 21:49:31

When I run the import option to database whit a mol2 file via Desktop application (jcman). What is the options that the function (API) used to convert mol2 to smile file, because I used (u,a-h) in my script and my smile and the smile that jcman insert in the database are different.

Thank in advance

ChemAxon fa971619eb

29-02-2008 08:20:12

If you are referring to the cd_smiles column in the database then this is a column that is used internally by JChem as part of the searching process. It is not possible to specify the format of this column as a specific format is required by JChem.

The cd_structure column contains the structure in whatever format it was supplied (e.g mol2 in your case). Again, it is not possible to change this as the column is designed to be an exact record of the structure that was imported.

If you want a smiles representation of your format to be present in the database then you have 2 options:

1. Convert all structures to smiles before import, in which case the smiles will be in the cd_structure column, but of course you will loose the features that were present in the mol2 format such as coordinates.

2. Add a chemical terms column to the table that generates the smiles format you require. This is probably your best option. The only downside is that the import will be very slightly slower as the smiles has to be generated and inserted.

See here for more information on adding a chemical terms column in jcman:

See here for more information on the chemical terms language: