User 0908c5ccdd
20-11-2007 12:45:43
I wondered if you could advise me on a query I need to run please? I have two tables containing different sets of structures. Table A contains almost 1 million structures and Table B contains approx 80,000 structures. I need to establish the alternate ids of structures that exist in both tables, using an exact search. The structure ids (cd_id) are different in both tables, although each has its own alternate identifier. I was hoping to run the query in a single statement, rather than through a PL/SQL procedure involving an explicit cursor.
Something like:
Although I don't think I can use a.cd_smiles = b.cd_smiles
Is there an alternative using a ChemAxon function on the cd_smiles column that might be suitable to use in the WHERE clause?
Something like:
Code: |
SELECT a.altid_a, b.altid_b FROM table1 a, table 2 b WHERE a.cd_smiles = b.cd_smiles |
Although I don't think I can use a.cd_smiles = b.cd_smiles
Is there an alternative using a ChemAxon function on the cd_smiles column that might be suitable to use in the WHERE clause?