330 Commits

Author SHA1 Message Date
Brian Black
c6230568cd SqlString is now per-dialect 2015-11-29 18:44:12 -05:00
Dustin Martin
d9ac2c1f8f Add status method
Returns 0 if all migrations are run and DB is up to date. Return negative number if DB is missing migrations. Return positive number if DB is ahead (rare case, e.g. if migrations were run then code is reverted)
2015-11-23 10:50:19 -06:00
Rhys van der Waerden
ebd361ffce Merge pull request #994 from wubzz/bugfix/query_event_when_using_transactions
Query event in Transaction should be proxied to the main client
2015-11-17 23:27:15 +11:00
Hannah Wolfe
f72892b5b9 Distinct modifier support for aggregate functions
closes #1028

- add support for count(distinct *), avg(distinct *) and sum(distinct *)
- min and max don't really make sense with distinct, so didn't add those
2015-11-09 12:48:42 +00:00
blah238
1ee32292d4 Add Travis testing for Node v4.x
- Update node-mariasql to 0.2.x
 - Closes #970
 - Closes #977
 - Closes #995
2015-10-27 17:38:56 -05:00
wubzz
4cba0d963c Query Event is now proxied to the main client like in previous versions of knex. Fixes #855 2015-09-19 14:45:01 +02:00
Mikael Lepistö
fef0a09197 Did npm run build 2015-08-25 10:23:34 +03:00
Daniel Teixeira
70e4692638 add support to postgres search_path 2015-08-09 23:04:57 -03:00
Daniel Teixeira
3f8f50425f add schema support for schema builder 2015-08-09 23:04:53 -03:00
Daniel Teixeira
402dbd9903 add schema support for postgres queries 2015-08-09 20:48:33 -03:00
Rhys van der Waerden
556fa6c76a Merge pull request #896 from helios1138/patch-1
fixed connection error handling for oracle dialect
2015-07-21 13:38:41 +10:00
Daniel Qin
c57d7e3de9 re-create fk with ref.CONSTRAINT_NAME instead of ref.COLUMN_NAME 2015-07-16 14:40:04 +08:00
Helios
962d09de6d fixed connection error handling for oracle dialect 2015-07-13 12:04:40 +03:00
Daniel Qin
19acfaffd6 fixed issue cannot rename column in migrations when there is FK references 2015-07-07 12:35:55 +08:00
Tim Griesser
6dbcaaaeaf Empty queries should be no-ops on mysql 2015-06-30 19:37:07 -04:00
Tim Griesser
04c20439ec Recompile after merging oracle patch, #876 2015-06-29 13:07:28 -04:00
Tim Griesser
6cef074236 Fix correct files for #851 2015-06-01 09:22:27 -04:00
Tim Griesser
421cb4f4eb Commit compiled files 2015-06-01 09:17:11 -04:00
Tim Griesser
ccc1c6ce23 Fix #843, pass compress option to mysql2 2015-06-01 08:33:32 -04:00
Kris Reeves
c1c6d401b8 Also fix up postgres _stream function to bind an error handler on the query object 2015-05-29 12:41:33 -04:00
Tim Griesser
e3ef628156 Beginning to use => 2015-05-09 14:07:58 -04:00
Tim Griesser
521a6f9e97 Remove use strict, assumed in ES6 2015-05-09 14:01:19 -04:00
Tim Griesser
7e884cb325 Babel src -> lib, remove gulp 2015-05-09 13:58:18 -04:00
Tim Griesser
6d93ba2c21 #805 - mysql2 doesn't include errno, sidorares/node-mysql2#168 2015-05-01 11:53:55 -04:00
Tim Griesser
12e6ada1a3 Fix for #805, warn for non-existent savepoints
In MySQL if a savepoint is missing, it means something
else (most likely DDL) triggered an implicit commit. In this
case rather than erroring, let's give a warning message
so it's possible to use the same codepath as a DB where
this actually works.
2015-05-01 11:26:29 -04:00
Tim Griesser
e179634600 Switch to shell script for release, other tidying of config/directories 2015-04-29 19:13:50 -04:00
Tim Griesser
c40b1339aa Update process for web script build 2015-04-29 17:11:52 -04:00
Tim Griesser
ff76297506 Normalize connection config, fix #789 2015-04-29 15:14:41 -04:00
Tim Griesser
2e47b9d2e8 Nicer query builder interface 2015-04-28 09:14:13 -04:00
Tim Griesser
ca158836a0 Cast buffer to string, #796 2015-04-28 08:14:22 -04:00
Tim Griesser
7b17cc404a Oracle test suite up to date 2015-04-27 20:22:05 -04:00
Tim Griesser
f735dcb9c8 Raw identifiers and named parameters
Adds ?? for interpolating identifiers in raw
statements. Also adds raw(sql, obj) for
named :key syntax. Alternatively, 🔑
(trailing colon) may be used to specify an
identifier as a parameter.
2015-04-27 15:58:48 -04:00
Tim Griesser
04a0aa6935 Removing explicit build directory, building lib in docs instead 2015-04-27 15:48:23 -04:00
Tim Griesser
ebcc22176f Make websql transaction api similar to others, jshint cleanup 2015-04-24 12:44:01 -04:00
Tim Griesser
3e47fafbe8 Cleaning up build process, WebSQL dialect 2015-04-24 12:19:33 -04:00
Tim Griesser
36ced91ed5 Testing transactions, beginning to use tape, adding query to error message 2015-04-24 10:10:34 -04:00
Tim Griesser
46e318d6da Cleaning up transactions, passing options arg to pipe 2015-04-23 14:51:33 -04:00
Tim Griesser
c8232d11d3 Merge with master, cleanup on mysql2/maria 2015-04-22 16:19:59 -04:00
Tim Griesser
f662bca81d Merge pull request #588 from shutterstock/fix/mysql2-can-use-other-port
Allow mysql2 to use a non-default port
2015-04-22 15:53:18 -04:00
Tim Griesser
e570c167c1 JSHint and formatting 2015-04-22 15:39:29 -04:00
Tim Griesser
871b50b5aa Cleaning up WebSQL & Oracle transaction implementations 2015-04-22 15:24:29 -04:00
Tim Griesser
7dfad30ff0 browserify -> webpack 2015-04-22 14:53:31 -04:00
Tim Griesser
2bc85cb7a5 Pool should be 1 for sqlite3 unless WAL is enabled 2015-04-22 11:45:12 -04:00
Tim Griesser
f9aab9dc76 Major internal refactor
Beefed up transaction implementation, still needs tests
and cleanup of nested transaction queues.

Left todo:
- Fix commented out tests
- Fix oracle driver's transactions
2015-04-22 10:34:14 -04:00
Tim Griesser
eee4e9c005 Fixing the overall class dependency approach, lots of internal cleanup, WIP 2015-04-19 16:31:52 -04:00
Tim Griesser
27cd9f12c5 Cleanup pool implementation, preparing things for new release 2015-04-17 15:00:08 -04:00
Calvin Metcalf
c00ff3d814 Allow t.binary to specify a length for MySQL
Closes #774
2015-04-16 15:39:02 -04:00
Ben Drucker
7cdda834ef Remove FoundationDB
Reverts c199761c597c93136a6d38bc4ecf26a693560322 and #641

Foundation was acquired and shut down immediately
2015-03-24 17:48:14 -07:00
Vincent Schoettke
5cd47fab98 Fixed returning bug with oracle
Fixes non working returning() with oracle introduced with #580 (strong-oracle support)
2015-03-16 10:04:49 +01:00
Tim Griesser
e9782a8932 Merge branch 'master' of github.com:tgriesser/knex
* 'master' of github.com:tgriesser/knex:
  Allow debugging to be disabled for a query
  fix float for oracle dialect. fixes #735
2015-03-13 01:33:36 -04:00