.Net SQL Parser

I had a requirement to parse SQL string, in particular with CONTAINS(column_list) and modify SELECT column list.
I've found two most promising implementations General SQL Parser from   http://www.sqlparser.com/  and SharpHSQL from http://www.c-sharpcorner.com/database/SharpHSQL.asp article.
General SQL Parser has quite qood API, but it doesn't have open source and doesn't recognize contains with column_list.

SharpHSQL is a early C# port of the HSQL Database Engine which has a source code, but also doesn't  recognize CONTAINS(column_list) and additionally doesn't re-construct SQL from previously parsed SQL string. I've tried to add the functionality that I wanted,but it wasn't easy.

Finally I gave up with SharpHSQL code and used a few RegEx pattern to modify SQL  as I needed. Unfortunately the code is not bullet-prove and will not work if sub-queries will be used in SELECT columns list.

Recently I  was pointed to GOLD Parser Engine, which I didn't research yet.

posted @ Saturday, August 12, 2006 3:36 PM

Print

Comments on this entry:

# re: .Net SQL Parser

Left by James at 9/22/2006 2:37 PM
Gravatar
The new version support CONTAINS now, you may
have a try here:
http://www.sqlparser.com

# re: .Net SQL Parser

Left by jhonny at 5/13/2009 10:39 PM
Gravatar
me parece interezante la herramienta la voy a provar muchas grasias por el aporte se lo garedesco mucho de todo corazon ,bay

# re: .Net SQL Parser

Left by Michael Freidgeim at 5/14/2009 12:18 AM
Gravatar
jhonny,
Thank to http://babelfish.yahoo.com/translate_txt
I can understand your comment.

Your comment:



 (will not be displayed)


 
 
 
 
 

Live Comment Preview:

 
«November»
SunMonTueWedThuFriSat
25262728293031
1234567
891011121314
15161718192021
22232425262728
293012345