Tobie Morgan Hitchcock
b988b2c890
Remove ‘url’ and ‘color’ SQL field types
2018-04-05 00:35:08 +01:00
Tobie Morgan Hitchcock
b8972ae2c2
Mathmatical sql functions must be prefixed with ‘math’
...
All mathmatical functions must now be used by specifying the full function name. For example `avg` is now `math.avg`.
2018-04-05 00:34:09 +01:00
Tobie Morgan Hitchcock
0dc9ad339c
Enable multiple expressions with database events
...
It is now possible to run multiple query expressions when an event on a table has occured. Query expressions can be separated with a semicolon, and will be run in the same transaction as the main query.
2018-04-04 19:20:07 +01:00
Tobie Morgan Hitchcock
085ba565b2
The SQL function string.reverse should take 1 argument
2018-04-02 23:44:51 +01:00
Tobie Morgan Hitchcock
ca392f87a7
Add ON SIGNUP and ON SIGNIN events to SQL SCOPE
...
It is now possible to run queries when a user signs-up or signs-in, by specifying multiple queries within an ON SIGNUP (…) clause, or a ON SIGNIN (...) clause.
2018-03-18 21:30:02 +00:00
Tobie Morgan Hitchcock
0dae9d2366
Add sql.MultExpression type
2018-03-18 21:01:29 +00:00
Tobie Morgan Hitchcock
f77daca0da
Simplify subquery parsing
2018-03-18 20:01:41 +00:00
Tobie Morgan Hitchcock
3436634586
Add SQL either function for simplified IF ELSE clauses
2018-03-18 19:03:14 +00:00
Tobie Morgan Hitchcock
926ef37234
LET and RETURN should not need SC level permissions
2018-02-12 15:38:34 +00:00
Tobie Morgan Hitchcock
2f23e84877
Parse times and records within json content
2018-01-10 13:17:50 +00:00
Tobie Morgan Hitchcock
b54e551353
No need to pass sql.parser into sql.scanner
2018-01-10 13:07:09 +00:00
Tobie Morgan Hitchcock
cc8f4ec29e
Use special SQL type for null values
2017-12-12 01:10:37 +00:00
Tobie Morgan Hitchcock
cacdf6dd49
Add SQL function for creating an array
2017-12-12 00:54:18 +00:00
Tobie Morgan Hitchcock
8849c7c30a
Enable specifying a regex using a function
2017-12-11 17:49:58 +00:00
Tobie Morgan Hitchcock
0c607302ed
Ensure one can specify regexes in sql expressions
2017-12-11 15:59:55 +00:00
Tobie Morgan Hitchcock
e3c7aacd66
Enable parameters in LIVE queries
2017-12-08 10:29:52 +00:00
Tobie Morgan Hitchcock
84b9cdc93a
Fix binary equality tree parsing and calculations.
2017-12-06 20:18:57 +00:00
Tobie Morgan Hitchcock
19ce0b7cad
Improve IF / ELSE statement formatting
2017-12-05 11:09:06 +00:00
Tobie Morgan Hitchcock
ccdc6fb8ea
Add ability to define the order fields are processed
2017-12-05 01:57:25 +00:00
Tobie Morgan Hitchcock
e27a9e78a7
Enable password field type without need to quote
2017-12-05 01:13:50 +00:00
Tobie Morgan Hitchcock
449ce9a4a8
Make sure ORDER BY clauses are formatted correctly
2017-12-04 18:45:51 +00:00
Tobie Morgan Hitchcock
14d3539dbf
Add SQL functions for parsing urls
2017-12-04 10:06:01 +00:00
Tobie Morgan Hitchcock
42bbc078e0
Don’t allow params inside SQL PathExpressions
2017-11-29 10:21:02 +00:00
Tobie Morgan Hitchcock
ba4af9a305
Remove unused SQL keyword
2017-11-28 19:02:11 +00:00
Tobie Morgan Hitchcock
475899960b
Remove unused code
2017-11-28 01:18:41 +00:00
Tobie Morgan Hitchcock
93d154a099
Add sql functions for generating GUIDs
2017-11-27 11:35:26 +00:00
Tobie Morgan Hitchcock
cfa573e7cf
Ensure Model can be encoded<->decoded into CORK
2017-11-27 11:16:29 +00:00
Tobie Morgan Hitchcock
a569ad78d6
Improve statement read/write status detection
...
Only store read-write statement status in the database for statements which can be either read or write. For those statements which are always write statements (Live, Kill, Create, Update, Delete, Relate, Insert, Upsert, Define, Remove….), then hardcode this on the statement itself.
2017-11-24 12:56:53 +00:00
Tobie Morgan Hitchcock
8de7424efb
Ensure the IfStatement can be encoded and decoded into cork
2017-11-24 12:47:59 +00:00
Tobie Morgan Hitchcock
1d08949fff
Full update of the SQL package
2017-11-16 20:53:13 +00:00
Tobie Morgan Hitchcock
4c16dafcf3
Add duration method to killable statements
2017-04-28 17:12:11 +01:00
Tobie Morgan Hitchcock
b60c663fdd
SQL models need a different min and max value
...
If the same minimum and maximum value is used in a SQL model … |person:1..1| then the sql query parser will fail.
2017-04-28 17:09:35 +01:00
Tobie Morgan Hitchcock
dacf7b954b
Enable WITH aswell as TO in RELATE clause
2017-04-28 17:07:38 +01:00
Tobie Morgan Hitchcock
8a53ed3617
Fix SQL tests
2017-04-14 13:24:53 +01:00
Tobie Morgan Hitchcock
7aca98a581
No need to generate codec code definitions
...
SQL ASTs are never outputted to the end user, but instead are only ever encoded/decoded using CORK, so we don’t need to pre-generate any code definitions for codec (JSON, BINC, CBOR, MsgPack).
2017-04-14 13:22:29 +01:00
Tobie Morgan Hitchcock
aa7e4ac561
Enable model expressions in SQL parser
...
The SQL parser now supports model expressions for defining ranges using the |table:0,0.5..100| notation syntax.
2017-04-14 13:21:08 +01:00
Tobie Morgan Hitchcock
2de5a8fa3f
Simplify parsing @table:thing definitions
2017-04-14 13:13:31 +01:00
Tobie Morgan Hitchcock
a3da779190
Improve SQL error messages
2017-04-12 18:45:52 +01:00
Tobie Morgan Hitchcock
9df4c5041a
Use pointer
2017-04-12 18:44:01 +01:00
Tobie Morgan Hitchcock
17b1f9ff55
Fix JSON parsing in SQL
...
Previously, JSON which contained bracket `[]` or brace `{}` characters inside strings would fail to parse as valid JSON.
2017-04-12 17:44:27 +01:00
Tobie Morgan Hitchcock
5a558c0d6f
Implement Authable statements for improved logging
2017-03-24 21:25:22 +00:00
Tobie Morgan Hitchcock
7a071af821
Download generate dependencies in each gen files
2017-03-04 10:55:58 +00:00
Tobie Morgan Hitchcock
a96a8466cb
Add initial golang code tracing and logging
2017-03-03 21:39:37 +00:00
Tobie Morgan Hitchcock
98db89a2d7
Implement query statement timeout functionality
2017-03-02 14:38:56 +00:00
Tobie Morgan Hitchcock
378bbe6dae
Ensure default tables/fields are private by default
2017-03-02 10:55:42 +00:00
Tobie Morgan Hitchcock
2d5151c8ba
Enable SQL AST string formatting
2017-03-02 10:47:10 +00:00
Tobie Morgan Hitchcock
1157835a29
Don’t perform cpu intensive operations in SQL parser
2017-03-02 10:32:20 +00:00
Tobie Morgan Hitchcock
6e223f5f08
Move authentication level constants to cnf package
...
Instead of defining the authentication level types as ints in the sql package, there is now a specific type which is now located in the cnf package.
2017-02-24 13:33:03 +00:00
Tobie Morgan Hitchcock
e4bef0c4b7
Differentiate between IDENT and EXPR in SQL
...
Previously it was possible to CREATE/UPDATE/DELETE path expressions as this would satisfy an IDENT in the SQL parser.
Now however, there is a difference between an IDENT and an EXPR…
IDENT: person | person_main | person123
EXPR: person | person.path | person[0].path
As a result, path expressions are only possible when setting data or setting conditional conditions.
2017-02-24 13:05:07 +00:00
Tobie Morgan Hitchcock
d27e00e737
Fix sql tests
2017-02-23 15:09:02 +00:00