Dear all, I have a "meta" application that's a bit like the sqlite shell (except it's not interactive) in which people write statements that are parsed by Perl that contain SQL statements that are passed *unparsed* by Perl to SQLite via DBD::SQLite.
Some of the queries are long. To save time, users would like to be able to parse the SQL in the meta app before actually running the meta app. Clearly since this is going to run through SQLite, it'd be nice if the actual SQLite parser could parse it 1st. (I looked at SQL::Statement::Structure and wasn't happy with it - broke on things that sqlite accepts - and I didn't want to have to rewrite the grammar to append sqlite-OK items) So, having looked at the source code for the DBD driver and sqlite3, it would seem that the appropriate function to call would be sqlite3RunParser. Is there any extant code that would show this being used more or less "by itself" in an application, (i.e. w/o the heavy weight of the rest of the sqlite code scaffolding)? C code would be fine (and I'd call it as an external app 1st of all and maybe integrate later) - though I'd like to really have this as a Perl module if possible. (I wanted to avoid the trial and error of figuring out which headers and what linkage and which data structures I would need to establish to minimally call this function I guess.) Any help appreciated. Thanks! Kind regards Derek Jones. BTW: Richard, if you read this - I still have the core dump problem from the other thread... :-( The good news is I've been coding the Perl & SQL around it to optimize which has been a useful exercise in its own right.