Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » DTP » Any way to implement DDL parser
Any way to implement DDL parser [message #597858] Thu, 12 August 2010 05:58 Go to next message
Pradeep  is currently offline Pradeep
Messages: 2
Registered: August 2010
Junior Member
I need to parse DDL statements like create,alter and drop and extract all the field and their datatype info in each tables . I found that DTP model base project only parses select query and other related statements. So can i really do this using model base project? or some other library
Brian Payton who have commented about parsers in other threads can help me with this
Re: Any way to implement DDL parser [message #597863 is a reply to message #597858] Thu, 12 August 2010 09:33 Go to previous message
David Maier is currently offline David Maier
Messages: 2
Registered: August 2010
Junior Member
Hi,

we are using ANTLR for this purpose. I have two grammar files those are doing stuff like this. One is the grammar of the Ingres Database System and another one is derived from MySQL's grammar and was created for the purpose to migrate Procedures from MySQL to Ingres. Here are the links to them:

* http://code.ingres.com/apps/IngresMigrationToolSet/IngresPar serCollectionLib/trunk/src/com/ingres/antlr/sql/resources/In gresSQL.g

* http://code.ingres.com/apps/IngresMigrationToolSet/IngresPar serCollectionLib/trunk/src/com/ingres/antlr/idiom/resources/ mysql/MySQLASTGen.g

I hope this is helpful for you.

Regards, David
Previous Topic:Any way to implement DDL parser
Next Topic:How to get (db2, oracle etc.) dialect SQL Query Parser
Goto Forum:
  


Current Time: Fri Aug 01 02:01:47 EDT 2014

Powered by FUDForum. Page generated in 0.02069 seconds