SQL plugin for the views library. Allows for plain ol' SQL strings to be used.
Go to file
Gered a86d4eef17 add ability to manually provide table name hints for unparseable sql
an important backup to allow SQL that JSqlParser cannot handle still
be used in the views system. JSqlParser is still actively maintained
and will get better over time, but it cannot handle everything thrown
at it.
2016-05-22 22:07:26 -04:00
src/views/sql add ability to manually provide table name hints for unparseable sql 2016-05-22 22:07:26 -04:00
.gitignore initial commit 2016-05-22 15:26:20 -04:00
LICENSE initial commit 2016-05-22 15:26:20 -04:00
project.clj initial commit 2016-05-22 15:26:20 -04:00
README.md update README.md 2016-05-22 15:38:36 -04:00

views-sql

SQL plugin for the views library. Allows for plain SQL strings to be used.

Implementation is largely based on the views-honeysql library. As such, the hints generated by either of these libraries are compatible with each other. So you can opt to include honeysql and sql views in the same view system if you wish and vexec! calls will trigger updates as you would expect across all of these views.

Note that this library leverages JSqlParser for parsing SQL queries and extracting the view system hint information needed. JSqlParser is not perfect and will not be able to parse some more complex queries and/or queries using some vendor-specific extensions.

License

Copyright © 2016 Gered King

Distributed under the MIT License.