Date: Fri, 29 Aug 2014 06:24:32 -0700
Subject: [PATCH 005/119] updated docs: pg-bricks & ~800 lines
---
index.html | 5 ++++-
readme.md | 8 ++++++--
2 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/index.html b/index.html
index ac97a9e..2a7077e 100644
--- a/index.html
+++ b/index.html
@@ -236,7 +236,10 @@ SQL Bricks.js
In addition, SQL Bricks contains a few conveniences to aid in re-use and to make SQL generation a little less of a chore: automatic quoting of columns that collide with keywords (order, desc, etc) & columns that contain capital letters, automatic alias expansion, user-supplied join criteria functions.
SQL Bricks differs from similar libraries in that it does not require a schema and it is designed to be transparent, matching SQL so faithfully that developers with SQL experience will immediately know the API.
SQL Bricks supports the four CRUD statements (SELECT, INSERT, UPDATE, DELETE) and all of their clauses as defined by SQL-92 as well as some additional clauses supported by Postgres and SQLite. Adding support for other SQL statements (CREATE, ALTER TABLE, etc) would clutter the library without providing much real benefit.
- The source is on GitHub and over 175 tests are available for your perusal.
+ The source is on GitHub and over 200 tests are available for your perusal.
+
+ Related Libraries
+ pg-bricks adds postgres connections, transactions, query execution and data accessors on top of SQLBricks.
Use
diff --git a/readme.md b/readme.md
index 8101c91..19edf7f 100644
--- a/readme.md
+++ b/readme.md
@@ -5,7 +5,7 @@
SQL Bricks.js is a transparent, schemaless library for building and composing SQL statements.
- Supports all [SQL-92](http://www.contrib.andrew.cmu.edu/~shadow/sql/sql1992.txt) clauses for select/insert/update/delete (plus some postgres & sqlite additions)
-- Over [175 tests](http://csnw.github.io/sql-bricks/browser-tests.html)
+- Over [200 tests](http://csnw.github.io/sql-bricks/browser-tests.html)
- Easy-to-use, comprehensive [docs](http://csnw.github.io/sql-bricks)
- Single straightforward [source file](sql-bricks.js) (less than 1,000 lines), easy to understand & debug
@@ -19,7 +19,7 @@ library | lines | files | schema | language | other notes
[node-sql][3] | 2600 | 59 | schema | javascript |
[mongo-sql][4] | 1700 | 49 | schemaless | javascript |
[gesundheit][5] | 1600 | 21 | schemaless | coffeescript | uses Any-DB to wrap the DB driver
-[sql-bricks][6] | 750 | 1 | schemaless | javascript |
+[sql-bricks][6] | 800 | 1 | schemaless | javascript |
[1]: https://github.com/tgriesser/knex
[2]: https://github.com/hiddentao/squel
@@ -28,6 +28,10 @@ library | lines | files | schema | language | other notes
[5]: https://github.com/BetSmartMedia/gesundheit
[6]: https://github.com/CSNW/sql-bricks
+# Related Libraries
+
+[pg-bricks](https://github.com/Suor/pg-bricks) adds postgres connections, transactions, query execution and data accessors on top of SQLBricks.
+
# Use
SQLBricks' only dependency is [Underscore.js](http://underscorejs.org/).
From 2483d1fba6ce68b4975d531e6d1c39c0aff4717d Mon Sep 17 00:00:00 2001
From: Peter Rust
Date: Fri, 29 Aug 2014 06:24:40 -0700
Subject: [PATCH 006/119] 0.14.0
---
package.json | 103 ++++++++++++++++++++++++++++-----------------------
1 file changed, 57 insertions(+), 46 deletions(-)
diff --git a/package.json b/package.json
index 70c6482..9408397 100644
--- a/package.json
+++ b/package.json
@@ -1,46 +1,57 @@
-{
- "name": "sql-bricks",
- "version": "0.13.0",
- "author": "Peter Rust ",
- "description": "Transparent, Schemaless SQL Generation",
- "homepage": "http://csnw.github.io/sql-bricks",
- "bugs": "https://github.com/CSNW/sql-bricks/issues",
- "scripts": {
- "prepublish": "node tests/gen-tests.js",
- "test": "mocha tests/tests.js tests/doctests.js"
- },
- "main": "sql-bricks.js",
- "repository": {
- "type": "git",
- "url": "https://github.com/CSNW/sql-bricks.git"
- },
- "keywords": [
- "sql", "generation", "generate", "query", "pg", "postgres", "sqlite", "builder", "select", "insert", "update", "delete"
- ],
- "engines": {
- "node": "*"
- },
- "dependencies": {
- "underscore": "1.4.x"
- },
- "devDependencies": {
- "mocha": "1.13.x"
- },
- "license": "MIT",
- "testling": {
- "html": "browser-tests.html",
- "browsers": [
- "chrome/29.0",
- "iexplore/8.0",
- "iexplore/9.0",
- "iexplore/10.0",
- "firefox/4.0",
- "firefox/6.0",
- "firefox/24.0",
- "safari/6.0",
- "iphone/6.0",
- "ipad/6.0",
- "android-browser/4.2"
- ]
- }
-}
+{
+ "name": "sql-bricks",
+ "version": "0.14.0",
+ "author": "Peter Rust ",
+ "description": "Transparent, Schemaless SQL Generation",
+ "homepage": "http://csnw.github.io/sql-bricks",
+ "bugs": "https://github.com/CSNW/sql-bricks/issues",
+ "scripts": {
+ "prepublish": "node tests/gen-tests.js",
+ "test": "mocha tests/tests.js tests/doctests.js"
+ },
+ "main": "sql-bricks.js",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/CSNW/sql-bricks.git"
+ },
+ "keywords": [
+ "sql",
+ "generation",
+ "generate",
+ "query",
+ "pg",
+ "postgres",
+ "sqlite",
+ "builder",
+ "select",
+ "insert",
+ "update",
+ "delete"
+ ],
+ "engines": {
+ "node": "*"
+ },
+ "dependencies": {
+ "underscore": "1.4.x"
+ },
+ "devDependencies": {
+ "mocha": "1.13.x"
+ },
+ "license": "MIT",
+ "testling": {
+ "html": "browser-tests.html",
+ "browsers": [
+ "chrome/29.0",
+ "iexplore/8.0",
+ "iexplore/9.0",
+ "iexplore/10.0",
+ "firefox/4.0",
+ "firefox/6.0",
+ "firefox/24.0",
+ "safari/6.0",
+ "iphone/6.0",
+ "ipad/6.0",
+ "android-browser/4.2"
+ ]
+ }
+}
From d875f84625808a61cdbc555e38a56d41ca0dd946 Mon Sep 17 00:00:00 2001
From: Peter Rust
Date: Fri, 19 Sep 2014 11:25:11 -0700
Subject: [PATCH 007/119] First pass at dialect extension mechanism
* Moved LIMIT ... OFFSET to a limit-offset extension (used by both sqlite/pg)
* Moved OR (replace/abort/etc) to sqlite extension
* Moved RETURNING & DELETE ... USING to postgres extension
* Removed MINUS support (Oracle only; if someone wants to create an
Oracle extension and maintain it in their own repo, they're welcome to)
* Removed unnecessary layer of method-building functions
---
browser-tests.html | 7 +
index.html | 8 +-
limit-offset.js | 46 +
package.json | 4 +-
postgres.js | 36 +
readme.md | 6 +-
sql-bricks.js | 1683 ++++++++++++++++++-----------------
sqlite.js | 32 +
tests/doctests.js | 26 +-
tests/doctests.tmpl | 12 +-
tests/limit-offset-tests.js | 72 ++
tests/postgres-tests.js | 61 ++
tests/sqlite-tests.js | 49 +
tests/tests.js | 52 +-
14 files changed, 1182 insertions(+), 912 deletions(-)
create mode 100644 limit-offset.js
create mode 100644 postgres.js
create mode 100644 sqlite.js
create mode 100644 tests/limit-offset-tests.js
create mode 100644 tests/postgres-tests.js
create mode 100644 tests/sqlite-tests.js
diff --git a/browser-tests.html b/browser-tests.html
index 9a11784..349be5b 100644
--- a/browser-tests.html
+++ b/browser-tests.html
@@ -10,7 +10,14 @@
+
+
+
+
+
+
+
-
-
-
-
-
-