用C SQL语法分析器 [英] SQL parser in C

查看:168
本文介绍了用C SQL语法分析器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想分析和存储SQL DML的列和值(INSERT,UPDATE,DELETE)在声明中C.需要开源$ C ​​$ C的URL或库,我可以链接我的C程序。该平台的SUSE Linux。试图使和不成功使用libSQL。详细的答案是AP preciated。谢谢你。

I want to parse and store the columns and values of a SQL DML (INSERT, UPDATE, DELETE) statement in C. Need the URL of the open source code or a library with which I can link my C program. The platform is SUSE Linux. Have tried to make and use libSQL unsuccessfully. A detailed answer is appreciated. Thanks.

其他注意事项:的请建议库/ code,我可以用我的C程序链接。在我的节目,我想使用这个库的功能解析和使用代币进行进一步的处理。

Additional Notes: Please suggest a library/code that I can link with my C program. In my program I want to use the functions of this library to parse and use the tokens for further processing.

推荐答案

您可以看看源$ C ​​$ C SQLite的。它使用一种叫做柠檬解析器。

You can have a look at the source code for SQLite. It uses a parser called Lemon.

链接:

SQLite的架构

柠檬解析器

您还可以查看源$ C ​​$ C PostgreSQL的-plpython3。看起来有一个纯C基于SQL解析器。

You can also look at the source code for postgresql-plpython3. Looks like it has a pure C based SQL parser.

链接:

<一个href=\"http://github.com/jwp/postgresql-plpython3/tree/1e8d471f071ec0d4fceb1041d2ede113a70e002f/src/backend/parser\">postgresql-plpython3 @ github上

这篇关于用C SQL语法分析器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆