123456789101112131415161718192021222324252627282930313233343536373839404142 |
- var Test = require('../../support/test-runner');
- describe('Query Generation ::', function() {
- describe('GROUP BY statements', function() {
- it('should generate a group by query', function(done) {
- Test({
- query: {
- select: ['*'],
- from: 'users',
- groupBy: 'count'
- },
- outcomes: [
- {
- dialect: 'postgresql',
- sql: 'select * from "users" group by "count"',
- bindings: []
- },
- {
- dialect: 'mysql',
- sql: 'select * from `users` group by `count`',
- bindings: []
- },
- {
- dialect: 'sqlite3',
- sql: 'select * from "users" group by "count"',
- bindings: []
- },
- {
- dialect: 'oracle',
- sql: 'select * from "users" group by "count"',
- bindings: []
- },
- {
- dialect: 'mariadb',
- sql: 'select * from `users` group by `count`',
- bindings: []
- }
- ]
- }, done);
- });
- });
- });
|