sqlingvo
sqlingvo copied to clipboard
A Clojure & ClojureScript DSL for SQL
Given a table definition such as : ```sql create table sample_relation ( id text not null, b_id int not null, c_id int, unique(id, b_id, c_id), foreign key (id) references sample_relation_2(id),...
Firstly thanks for the lib =)... Two quick questions, if I define an enum as: ```clojure (sql/create-type sql-db :gender (sql/enum ["male" "female"])) ``` Is there no better api than: ```clojure...
I want to pass the value of a var to my SQL function. ```clojure (sql/sql (sql/select db [:*] (sql/from `(:my-func ~arg)))) ``` But I get an error: ``` ExceptionInfo Can't...
I can't find any documentation or code.
It would be really helpful for me, especially as a novice clojure user, to have a description of the differences between `sqlingvo` and the others sql libraries along with the...
I had a sql such as: ``` select * from t, LATERAL (select * from jsonb_to_recordset(meta->'conditions') as x(op text, condition jsonb,duration jsonb,time jsonb)) ``` how can i use it?
The only change required to make the code self-host compatible was to remove the `defdb` calls in `db.cljc`.
Would you accept a PR to add ALTER TABLE functionality?
Hi Roman. After reading sqlingvo source I'm confused with `db` argument of functions such as `select`, `insert` and others. `db` contains information about how to escape various SQL literals, so...
SQL Server does not support LIMIT and OFFSET, but it does support TOP at the start of a SELECT statement, e.g. `SELECT TOP 500 * FROM Table` I looked at...