Jens Rehsack wrote:
Am 11.04.2012 04:58, schrieb Darren Duncan:
That's what I would do if I were making a SQL parser.  Oh wait, I am!

Just another SQL Parser? Why not taking/improving one of the
existing ones? Or is it, because they're not invented "here"?

No, not "just another"; I don't do that kind of thing.

I'm creating a new general purpose but database savvy programming language, first implemented in Perl 5 but that ultimately would self-host, which one can either use to write an application in or write a DBMS in. I am also writing a module in this language which provides all the API and semantics of SQL. Thereby, one can "write SQL" using either the native syntax of the language, which looks loosely like Perl, but I would also provide a parser for actual SQL syntax that maps to the SQL-semantics module, so one can take existing SQL code and run it in Perl. The initial Perl 5 implementation would implement a DBMS natively, but subsequently there is the option to farm out to or map to existing DBMSs, which can be quite direct for code mapped to the SQL-semantics module.

I expect that I will try to utilize existing SQL parsing modules on CPAN for my project where they are capable enough or are designed in a manner that they can be made capable enough without a rewrite. My reason to exist isn't SQL parsing for its own sake, but SQL parsing would support the other things.

Do you know any SQL parsing modules that can actually *run* the SQL in Perl or that generate Perl code from SQL that does the same thing with Perl data?

-- Darren Duncan

Reply via email to