Simon Binder
4940ed5be8
Fix broken sqlparser test
2021-01-18 19:24:47 +01:00
Simon Binder
a375caaa44
Add lint for duplicate PRIMARY KEY constraints
2021-01-18 15:11:46 +01:00
Simon Binder
5ff74c7bcb
Improve table analysis, parse key ordering ( #1007 )
2021-01-18 14:44:05 +01:00
Simon Binder
1ff10f47c2
Remove part files of parser
2021-01-18 11:15:31 +01:00
Simon Binder
b8eed2f75b
Make order by placeholders optional ( #998 )
2021-01-08 22:30:17 +01:00
Simon Binder
6aa022e547
Add nullability hints, generate nullable variables
2020-12-14 18:35:19 +01:00
Simon Binder
efe0df519b
Improve type inference around IS expressions
2020-12-14 17:48:50 +01:00
Simon Binder
a749f38e2b
Make columns from LEFT OUTER joins nullable
2020-12-12 23:22:21 +01:00
Simon Binder
1d0cba14cd
Merge types2 and rest of types
2020-12-12 21:31:27 +01:00
Simon Binder
9025280a89
Migrate sqlparser to null safety
2020-12-11 10:53:17 +01:00
Simon Binder
0c075a2b44
Support overriding column getters and table classes ( #932 )
2020-11-23 20:01:31 +01:00
Simon Binder
a73b9334b6
Reduce usages of covariant
2020-11-23 19:00:29 +01:00
Simon Binder
bf7a8bc872
Fix resolving some references ( #917 )
2020-11-16 16:22:18 +01:00
Simon Binder
1d7479226a
Parse NULL column constraints to fix parsing errors ( #909 )
2020-11-07 12:32:45 +01:00
Simon Binder
71e5c4941e
Support comparing types with different names
2020-10-23 19:22:30 +02:00
Simon Binder
732369c25c
sqlparser: Give CASE a higher precedence
2020-10-22 13:30:43 +02:00
Simon Binder
89e019f756
Resolve type of EXISTS expressions in types2 ( #874 )
2020-10-16 12:31:18 +02:00
Simon Binder
fac99e1d6b
Run CI with Dart 2.10
2020-10-02 18:43:27 +02:00
Simon Binder
fa432ee17a
Add test for type hints in between expressions
2020-09-06 13:27:30 +02:00
Simon Binder
2ae2388878
Support default values for Dart placeholders ( #753 )
2020-08-30 13:48:47 +02:00
Simon Binder
57efa4bb89
Add more tests for node to text
2020-08-22 12:36:36 +02:00
Simon Binder
6fba2555c1
Api to turn AST nodes into a textual represenation
2020-08-21 16:44:17 +02:00
Simon Binder
a037de6621
Support rowid resolution outside of selects
...
This fixes #754
2020-08-10 10:46:33 +02:00
Simon Binder
0d9196dca8
Resolve columns in CREATE TRIGGER declaration ( #751 )
2020-08-07 20:38:32 +02:00
Simon Binder
c2ce934361
Apply type converters on variables ( #730 )
2020-07-23 17:30:26 +02:00
Simon Binder
640cae1244
Scan [identifiers] in sql queries ( #724 )
2020-07-22 10:43:44 +02:00
Simon Binder
144116b5e1
Re-run generator in Flutter example, fix type inference bug ( #715 )
2020-07-18 13:38:21 +02:00
Simon Binder
cb7c36d63b
sqlparser: Improve numeric token parsing
2020-07-18 11:01:04 +02:00
Simon Binder
800ee8ac3a
Add implicit cast when inferring binary expressions
2020-07-18 09:49:49 +02:00
Simon Binder
74caeced85
Fix typo in parsing error message
2020-07-12 17:59:24 +02:00
Simon Binder
7ff91a620a
Some improvements related to generator error recovery
2020-07-07 23:01:02 +02:00
Simon Binder
2897dd4ae0
Parse NULLS FIRST and NULLS LAST
2020-06-27 14:38:16 +02:00
Simon Binder
5136412573
Parse DEFERRABLE clauses on foreign key constraints
2020-06-27 14:26:09 +02:00
Simon Binder
211b6fa2e9
sqlparser: Support remaining sqlite keywords
2020-06-26 22:54:42 +02:00
Simon Binder
d5c6467e37
Finish documentation, remove unnecessary null hint
2020-06-24 17:11:41 +02:00
Simon Binder
ccea0a5d36
Don't throw parsing errors for top-level statements
2020-06-24 17:08:13 +02:00
Simon Binder
c342b29b33
Fix sqlparser crashes related to unknown tables
2020-06-19 13:43:16 +02:00
Simon Binder
5c9c175c85
Merge branch 'develop' of gh:simolus3/moor into develop
2020-06-17 23:00:56 +02:00
Markus Richter
f298a10636
Allow Backticks(`) for escaping identifiers
...
This is sqlite-conformant behaviour according to https://sqlite.org/lang_keywords.html .
2020-06-17 17:20:44 +02:00
Simon Binder
1e8a1de6c0
sqlparser: Add visit methods for Queryable subclasses
2020-06-16 14:25:31 +02:00
Simon Binder
5c6331e486
sqlparser: Make InsertSource an AstNode
2020-06-15 17:45:28 +02:00
Simon Binder
7ae3783473
sqlparser: Make TriggerTarget an ast node
2020-06-15 17:21:49 +02:00
Simon Binder
896d62d76c
Support nested CASE expressions ( #609 )
2020-06-02 12:05:02 +02:00
Simon Binder
fee32fc302
Start with transformers in sqlparser
2020-05-24 22:30:25 +02:00
Simon Binder
01e5a47189
Make utility visitor methods an extension
2020-05-24 19:53:36 +02:00
Simon Binder
e772ca0225
Support views in ReferencedTablesVisitor
2020-05-23 15:27:58 +02:00
Simon Binder
8aca8db941
Merge branch 'views' of https://github.com/mqus/moor into mqus-views
...
# Conflicts:
# sqlparser/test/analysis/schema/from_create_table_test.dart
2020-05-22 17:29:04 +02:00
Simon Binder
5d93f9fcf9
Analysis support for custom result sets
2020-05-21 15:22:49 +02:00
Markus Richter
5596c30cc7
Support subquery expressions in types2 ( #583 )
2020-05-19 19:42:36 +02:00
Simon Binder
52fd09c041
Fix reading a column without datatype
2020-05-17 15:18:25 +02:00
Simon Binder
a1304c537f
Formatting
2020-05-16 19:42:33 +02:00
Simon Binder
888e131d50
Report analysis error for view column mismatches
2020-05-16 19:36:56 +02:00
Simon Binder
58335958c0
Test selecting from a view
2020-05-16 19:29:11 +02:00
Simon Binder
46ba81b672
Interface for columns with type, resolve in ViewReader
2020-05-16 19:16:06 +02:00
Simon Binder
f7e7622b4c
Rename resultset.dart to result_set.dart, format parser test
2020-05-16 18:55:07 +02:00
Markus Richter
df6f6fafa2
Add NamedResultSet type, adress review issues
2020-05-16 13:50:30 +02:00
mqus
0bc2a7548d
Apply suggestions from code review
...
Co-authored-by: Simon Binder <oss@simonbinder.eu>
2020-05-16 12:08:05 +02:00
Markus Richter
186153e585
Add parser test,advance analyzer,fix review issues
...
Also:
- Add toString method to Literal and alter the one on Reference to make debugging and analysing tests easier
- Add `@required` to columns in SelectStatement constructor to make it clear that it can't be null (required by childNodes getter)
2020-05-15 19:58:16 +02:00
Simon Binder
cf830165e1
Support enum converters for moor files, add documentation
2020-05-13 21:43:58 +02:00
Markus Richter
d86d7ab7e3
Parser is ready, work on analyzer was started.
2020-05-13 14:29:22 +02:00
Simon Binder
9841c960d1
Parse row values, warn on misuse
2020-05-06 21:08:47 +02:00
Simon Binder
8b6abd7140
Move referenced table finder to sqlparser package ( #537 )
2020-05-04 22:00:41 +02:00
Simon Binder
bd250ee9e7
Support collate expression with new type inference ( #533 )
2020-05-03 21:13:29 +02:00
Simon Binder
fc0b1f4388
Use package:charcode for sql scanning
2020-05-02 14:17:49 +02:00
Simon Binder
453ccbefdc
Support double-equals in types2
2020-04-19 13:43:42 +02:00
Simon Binder
6b2bd27d4d
Parse and analyze VALUES clause for selects
2020-04-16 22:41:21 +02:00
Simon Binder
c007e1f9ac
Sort token types and keywords
2020-04-16 21:14:51 +02:00
Simon Binder
9a78604d98
Fix issues with new inference, enable it by default
2020-04-16 19:07:30 +02:00
Simon Binder
af5333db3c
Support compound select statements in from
2020-04-07 15:37:35 +02:00
Simon Binder
dcb4c4b972
Resolve nested result sets in generator
2020-04-03 20:30:41 +02:00
Simon Binder
d5ad3c6d34
Parse nested star columns
2020-04-03 18:37:33 +02:00
Simon Binder
2b9a85714f
Improve nullability detection in new type inference
2020-03-24 19:33:57 +01:00
Simon Binder
1a2d3bdee7
Parse comma separated tables as proper join ( #453 )
2020-03-22 11:51:39 +01:00
Simon Binder
d533a0a254
Fix error recovery on early finished statements #453
2020-03-21 22:02:27 +01:00
Simon Binder
990755f170
Static analysis for moor_ffi functions
2020-02-19 12:25:40 +01:00
Simon Binder
10b12a5976
Remove two more tiny deprecated members
2020-02-17 21:22:43 +01:00
Simon Binder
7fc1671bf8
Fix null pointer in SqlEngine constructor
2020-02-12 19:52:19 +01:00
Simon Binder
814e7bf61d
SqlEngine: Migrate default construtor to options
2020-02-10 18:48:03 +01:00
Simon Binder
b143ee5a4b
Refactor sql scoping, make aliased tables explicit
2020-02-05 22:52:45 +01:00
Simon Binder
aa52c4ba3d
Analysis for upsert clauses
2020-02-05 12:26:14 +01:00
Simon Binder
8839ec75a8
types2: Inference for upsert clauses
2020-02-03 21:54:49 +01:00
Simon Binder
0c171c3b81
sqlparser: Support upsert clauses ( #367 )
2020-02-03 21:43:18 +01:00
Simon Binder
fbe061c84d
Support current time literals in the sql parser
2020-02-01 13:18:53 +01:00
Simon Binder
27430cbb07
Add table-valued query to test moor file
2020-01-26 15:37:46 +01:00
Simon Binder
71ef9b8cd7
Support table-valued json1 functions
2020-01-26 14:42:52 +01:00
Simon Binder
5268d88344
Extract json1 support into an extension
2020-01-26 14:22:07 +01:00
Simon Binder
c82bff8c97
Analysis support for table-valued functions
2020-01-26 14:04:35 +01:00
Simon Binder
5622ed5c43
Analysis support for table-valued functions
2020-01-26 13:51:53 +01:00
Simon Binder
223f1615ab
Support parsing table valued functions
2020-01-26 13:13:44 +01:00
Simon Binder
ceb300e32e
Parse rowid as a valid expression in the sql parser
2020-01-26 12:23:47 +01:00
Simon Binder
de38761db9
Support type converters in moor files ( #103 )
2020-01-25 15:43:55 +01:00
Simon Binder
8c62365f26
Improve type inference for parentheses
2020-01-19 13:07:47 +01:00
Simon Binder
c8a155a44b
Autocomplete table names in sqlparser
2020-01-18 21:41:36 +01:00
Simon Binder
eb77d06cac
sqlparser: Recover from invalid column definitions
2020-01-18 15:09:42 +01:00
Simon Binder
4a2184110f
Run tests for types1 for types2 resolver
2020-01-16 22:07:02 +01:00
Simon Binder
8ae68707f8
Smarter many-to-one propagation in types2
2020-01-15 22:10:18 +01:00
Simon Binder
ddda6797e1
types: Analyze functions
2020-01-13 20:40:46 +01:00
Simon Binder
5d8040554f
CLI tool to export a moor schema to json
2020-01-12 10:38:03 +01:00
Simon Binder
9c38ed1ea5
Support CASE expressions in the new type resolver
2020-01-10 21:31:22 +01:00
Simon Binder
6434f7a7d5
Support virtual tables in the analyzer plugin
2020-01-09 22:45:25 +01:00
Simon Binder
643ef5640c
Faster sql tokenization with char codes
2020-01-09 22:09:17 +01:00
Simon Binder
5c82b2f2a7
Loose coupling between highlighter and analyzer plugin
2020-01-09 13:50:11 +01:00
Simon Binder
a3708b7230
Remove deprecated usages of SqlEngine constructor
2020-01-07 11:40:43 +01:00
Simon Binder
70259c8f83
Build options to enable types2 inference
2020-01-04 22:29:21 +01:00
Simon Binder
523eabaa2a
Support LIKE expressions in the new type resolver
2020-01-04 21:36:06 +01:00
Simon Binder
a8ffd0a7f3
Support LIMIT clauses in the new type resolver
2020-01-04 21:26:47 +01:00
Simon Binder
49d251f819
Support single quote escapes in sql ( #317 )
2020-01-04 17:32:55 +01:00
Simon Binder
282af57c78
Report a parsing error for invalid queries in moor files
...
We used to return null when the query didn't start with SELECT, INSERT, UPDATE or DELETE, which causes errors later on. Now, we don't accept the query and report a parsing error.
2020-01-04 17:06:45 +01:00
Simon Binder
c362e08e6e
types2: Respect variable hints from options
2020-01-04 16:55:34 +01:00
Simon Binder
92030c07a8
types2: Support inference for insert statements ( #297 )
2020-01-04 14:38:37 +01:00
Simon Binder
c95a5f0aad
New type resolver: Start propagating known types
2020-01-04 13:22:29 +01:00
Simon Binder
de67ca6e7b
Parse ISNULL and NOTNULL postfix expressions
2020-01-03 17:39:35 +01:00
Simon Binder
6924543a47
sqlparser: Parse CREATE INDEX statements
2020-01-03 17:14:42 +01:00
Simon Binder
75cbe74b53
Make "new" and "old" table available for triggers
2020-01-01 20:37:34 +01:00
Simon Binder
8b86143ebb
Generate code for triggers
2019-12-31 16:03:03 +01:00
Simon Binder
a3697c6f38
Find references of a trigger
2019-12-31 15:07:08 +01:00
Simon Binder
04f75d11d3
Migrate some trigger code to refactorings on develop
2019-12-30 21:38:24 +01:00
Simon Binder
ba603f22cc
Merge branch 'develop' into views-triggers-indexes
...
# Conflicts:
# moor/lib/moor.dart
# moor/lib/src/runtime/api/query_engine.dart
# moor/lib/src/runtime/query_builder/schema/entities.dart
# moor/test/data/tables/custom_tables.g.dart
# moor/test/data/tables/tables.moor
# moor/test/parsed_sql/moor_files_integration_test.dart
# moor_generator/lib/src/analyzer/moor/parser.dart
# moor_generator/lib/src/analyzer/runner/steps.dart
# moor_generator/lib/src/analyzer/runner/steps/analyze_dart.dart
# moor_generator/lib/src/model/specified_db_classes.dart
# moor_generator/lib/src/writer/database_writer.dart
# sqlparser/lib/src/ast/ast.dart
# sqlparser/lib/src/ast/statements/create_table.dart
# sqlparser/lib/src/ast/statements/statement.dart
# sqlparser/lib/src/reader/parser/schema.dart
# sqlparser/lib/src/reader/tokenizer/token.dart
# sqlparser/test/engine/autocomplete/static_test.dart
2019-12-30 21:08:32 +01:00
Simon Binder
c54a62120d
sqlparser: Support CAST expressions
2019-12-30 20:46:54 +01:00
Simon Binder
4484890609
Types2: Initial support for binary expressions
2019-12-30 20:14:29 +01:00
Simon Binder
927fbf561b
Begin architecture of a new type resolver in sqlparser
2019-12-26 21:55:02 +01:00
Simon Binder
7abda32ac4
Add argument to sql visitor class
2019-12-26 12:35:29 +01:00
Simon Binder
d2b70e69dc
Support explicit type arguments in moor_generator
2019-12-25 21:07:08 +01:00
Simon Binder
868dde358f
Parse variable type hints in queries
2019-12-25 20:24:03 +01:00
Simon Binder
412e8b4c83
Ability to override variable types in the sqlparser
2019-12-25 19:50:32 +01:00
Simon Binder
4a2273c1e8
Show available columns when failing to resolve a reference
2019-12-24 14:07:12 +01:00
Simon Binder
3f0c35abff
Improve changelog, error description for columns
2019-12-23 12:24:22 +01:00
Simon Binder
cb38590ee4
Parse special `@`-queries (not analyzed yet), #280
2019-12-17 22:03:59 +01:00
Simon Binder
0335e2482b
Scan @-variable tokens (not used yet)
2019-12-17 20:48:18 +01:00
Simon Binder
ffe4bb8c82
Don't crash when trying to resolve variables
2019-12-16 13:24:29 +01:00
Simon Binder
8661e0a28a
Refactoring on the model classes in moor_generator
2019-12-14 21:43:04 +01:00
Simon Binder
c9f29fab5b
Support detailed analysis for fts5 functions
2019-12-13 22:30:36 +01:00
Simon Binder
94634bd48b
Support custom fts5 queries
2019-12-12 18:56:37 +01:00
Simon Binder
a23ff772fa
Improve syntax highlighting in the sql IDE
2019-12-11 21:14:33 +01:00
Simon Binder
99cf31bb61
Don't attempt to type unresolved references
2019-12-11 10:12:30 +01:00
Simon Binder
74ebb8a9ab
Ability to create fts5 tables in moor files ( #196 )
2019-12-10 20:24:08 +01:00
Simon Binder
28b1e19145
Test that dart components can be used from UseMoor/Dao
...
Fixes #267
2019-12-05 19:23:52 +01:00
Simon Binder
3c74a20f56
Enable more recent lints and enforce them
2019-12-04 21:45:09 +01:00
Simon Binder
f4c05f44c7
sqlparser: Read table schemas for fts5 tables
2019-12-04 19:55:23 +01:00
Simon Binder
325820af80
Parse CREATE VIRTUAL TABLE statements
2019-12-04 15:36:23 +01:00
Simon Binder
a0ce3421c9
Resolve json functions when option is set ( #235 )
2019-11-28 21:50:55 +01:00
Simon Binder
bb1fcc1590
Fix analyzer crash at CTE ( #255 )
2019-11-24 14:46:20 +01:00
Simon Binder
598fef750e
RELEASE
...
- moor 2.1.0
- moor_generator 2.1.0
- sqlparser 0.4.0
- moor_ffi 0.2.0
2019-11-16 11:23:11 +01:00
Simon Binder
a304d13927
Use enforceHasSpan on all parse results in tests
2019-10-27 11:51:09 +01:00
Simon Binder
591e1b2bff
Support WITH clause for inner select statements
2019-10-27 10:47:21 +01:00
Simon Binder
9372178204
INSERT INTO SELECT: Support with clause
2019-10-25 23:18:21 +02:00
Simon Binder
d43a23eb88
Don't crash when a table wasn't resolved
2019-10-24 22:26:27 +02:00
Simon Binder
b8af08919a
Handle recursive CTEs in analyzer
2019-10-23 18:03:24 +02:00
Simon Binder
d55e1de66d
Handle common table expressions in the analyzer
2019-10-23 17:07:44 +02:00
Simon Binder
29a7b4853d
Parse common table expressions (no analysis yet)
2019-10-21 22:10:19 +02:00
Simon Binder
8a54fd4729
Generate code for CREATE TRIGGER statements
2019-10-21 18:13:28 +02:00
Simon Binder
e553d37de6
Fix autocomplete tests
2019-10-21 17:27:38 +02:00
Simon Binder
8de2b141a9
Parse CREATE TRIGGER statements
2019-10-20 17:48:17 +02:00
Simon Binder
8a8b811643
Fix more sqlparser crashes in the resolver
2019-10-20 11:28:05 +02:00
Simon Binder
a69f469444
Support sqlite_master, sqlite_sequence tables ( #197 )
2019-10-19 16:56:36 +02:00
Simon Binder
fd27c878d4
Fix errors in sqlparser that were swallowed before
2019-10-19 16:41:30 +02:00
Simon Binder
d8226aeb23
Handle aliases references to rowid ( #197 )
2019-10-19 16:09:44 +02:00
Simon Binder
4c090af98c
Ability to override json keys in moor files ( #176 )
2019-10-14 19:59:52 +02:00
Simon Binder
ed03bff4c2
Recognize boolean and datetime column in moor
2019-10-05 21:24:41 +02:00
Simon Binder
ef1dd8d2c5
Scan \r as whitespace ( #170 )
2019-10-04 22:21:17 +02:00
Simon Binder
1ba687696f
Plugin: Navigation support for table references
2019-09-28 23:15:23 +02:00
Simon Binder
b9f934c1d4
Report information about where a column was declared
2019-09-28 22:01:28 +02:00
Simon Binder
ab787b82be
Use existing parser code for auto-complete
...
This works very well when the user is typing at the end of a statement, but won't provide accurate results when editing in the middle.
2019-09-27 22:06:14 +02:00
Simon Binder
a6cfc5fdd8
Better types for nested expressions, more 2.0 docs
2019-09-26 22:46:19 +02:00
Simon Binder
c4f321748a
Prepare release for sqlparser 0.3.0
2019-09-25 20:19:39 +02:00
Simon Binder
2a782a010e
Resolve types of columns in compound select statements
2019-09-25 19:46:39 +02:00
Simon Binder
f6a5009380
Report errors when ORDER or LIMIT is used in compound stmt
2019-09-25 18:08:24 +02:00
Simon Binder
0cbac2ee37
Parse compound select statements
2019-09-25 14:58:44 +02:00
Simon Binder
d9c2b5f342
Parse JOIN and INDEXED as identifiers when appropriate
2019-09-25 11:37:03 +02:00
Simon Binder
bf6d60b170
Fix column parser not accepting columns without type
2019-09-24 22:45:18 +02:00
Simon Binder
ba21a594af
Fix autocomplete and suggestions in the analyzer plugin
2019-09-24 20:50:23 +02:00
Simon Binder
1bdfa0289b
Make the parser set a span on each AST node.
2019-09-18 21:36:25 +02:00
Simon Binder
1bd856e9c5
Fix scanner crashing when the last line contains a comment
2019-09-18 20:53:49 +02:00
Simon Binder
7121bac866
More work on the analyzer plugin
...
- finish migration to refactored generator
- document how to use the analysis plugin
- better error reporting without redundant messages
2019-09-18 20:48:44 +02:00
Simon Binder
00b2956b35
Allow data class names to be overridden in sql
...
Closes #147
2019-09-17 15:23:24 +02:00
Simon Binder
746b8401ec
Scan comments in sql
2019-09-16 22:33:36 +02:00
Simon Binder
5f2d5d3258
Parse <expression> IN (<select-stmt>) again
2019-09-15 21:41:32 +02:00
Simon Binder
25ceda3505
Report lints about invalid Dart Templates in SQL
2019-09-15 11:59:47 +02:00
Simon Binder
3abfbd5963
Don't parse tuples as expressions
2019-09-15 11:19:32 +02:00
Simon Binder
c95a3badb2
Infer types for dart placeholder expressions
...
Also, infer where clauses to have a bool type
2019-09-14 22:44:20 +02:00
Simon Binder
349b245089
Write implementation for Dart placeholders
2019-09-14 16:42:24 +02:00
Simon Binder
bf7c9feddf
Write parameter declarations for Dart placeholders
2019-09-14 12:26:58 +02:00
Simon Binder
f171098789
Parse Dart placeholders based on their context
2019-09-14 11:44:15 +02:00
Simon Binder
7a8191fe7e
Fix moor queries not expanding array vars properly
2019-09-14 09:27:36 +02:00
Simon Binder
4c250c8f40
Parse dart template expressions and limit clauses
2019-09-13 23:08:29 +02:00
Simon Binder
44a2319bba
Improve variable tokenization for easier parsing logic
2019-09-13 22:48:55 +02:00
Simon Binder
6a0716daaf
Handle import statements and declared queries in .moor
2019-09-12 19:51:15 +02:00
Simon Binder
a5cecd3ba6
Support moor file AST in the plugin
2019-09-09 20:34:14 +02:00
Simon Binder
1b7721a98f
Plugin: Import assists for column nullability
2019-09-08 21:36:26 +02:00
Simon Binder
e807822f3f
Make plugin operate on the new MoorFile AST node
2019-09-08 10:29:59 +02:00
Simon Binder
7354b56712
Merge branch 'develop' into analyzer-plugin
...
# Conflicts:
# moor_generator/lib/src/analyzer/moor/parser.dart
# sqlparser/lib/src/engine/sql_engine.dart
2019-09-07 23:05:36 +02:00
Simon Binder
a62c076c4c
Suggest CREATE TABLE statements in moor files
2019-09-07 22:49:23 +02:00
Simon Binder
ee9b413e5d
Start experimenting with auto-completion features
2019-09-07 22:18:45 +02:00
Simon Binder
35e5bdb317
Introduce new top-level ast node for moor files
2019-09-07 21:33:56 +02:00
Simon Binder
1ed1e3ba94
Parse declared statements in moor files
2019-09-07 20:26:51 +02:00
Simon Binder
8268867369
Fix analyzer errors, re-run build_runner
2019-09-07 20:01:33 +02:00
Simon Binder
1fcc6facee
Implement basic functionality of the analyzer plugin
2019-09-07 18:49:11 +02:00
Simon Binder
b550afd68f
Merge branch 'develop' into analyzer-plugin
...
# Conflicts:
# moor_generator/lib/src/parser/moor/moor_analyzer.dart
2019-09-07 11:31:34 +02:00
Simon Binder
6ccaad866b
Parse import statements in moor files
2019-09-05 10:52:33 +02:00
Simon Binder
ba772ef07f
Better error handling when parsing multiple sql statements
2019-09-03 21:24:59 +02:00
Simon Binder
fcdbc309b7
Fix resolver not finding window expressions
2019-08-30 19:36:23 +02:00
Simon Binder
4af370f0cb
Tests: Verify that an executor is open when used.
2019-08-30 19:32:44 +02:00
Simon Binder
876db0671e
Provide lints on insert statements that will fail
2019-08-29 21:09:20 +02:00
Simon Binder
241baed0c3
Generate query implementations for insert statements
2019-08-29 16:27:55 +02:00
Simon Binder
dd8b4ab03a
Infer types for insert statements
2019-08-29 15:32:45 +02:00
Simon Binder
2f8dc6d68e
Parse insert statements
2019-08-29 15:04:39 +02:00
Simon Binder
5d2149d727
Parse MAPPED BY constraints for moor files
2019-08-27 12:33:48 +02:00
Simon Binder
aa13aad276
Introduce moor-specific tokens for type converters
2019-08-27 12:15:32 +02:00
Simon Binder
3612c78241
Introduce special token class for keywords
2019-08-27 11:54:56 +02:00
Simon Binder
4b0add64de
Provide better error messages at unknown tables
2019-08-26 22:26:38 +02:00
Simon Binder
a3f6f1e326
Merge branch 'develop' into analyzer-plugin
...
# Conflicts:
# moor_generator/pubspec.yaml
2019-08-26 15:32:28 +02:00
Simon Binder
26e28e9ddc
Fix AggregateExpression not reporting content equality
2019-08-19 20:51:10 +02:00
Simon Binder
e911e74af2
Support window declarations on select statements
2019-08-19 18:06:25 +02:00
Simon Binder
3dcf59af63
Fix some bugs in the sql parser, another integration test
2019-08-17 22:21:34 +02:00
Simon Binder
7d89f12aa7
Use explicit indices for array parameters
2019-08-15 21:26:27 +02:00
Simon Binder
7ba89c099f
Resolve and infer types for window expressions
2019-08-14 18:00:41 +02:00
Simon Binder
1d3d68fb54
Parse aggregate functions and window definitions
2019-08-13 14:11:13 +02:00
Simon Binder
515b95acfe
Add AST classes to model windowing in sql
2019-08-12 16:50:13 +02:00
Simon Binder
4210c0c836
Start some work on the analyzer plugin
...
Of course it's not working at all
2019-07-30 18:34:33 +02:00
Simon Binder
5df5e3cacc
Fix typename parsing, set span on default constraint
2019-07-30 09:35:19 +02:00
Simon Binder
4798d0a7e5
Parse specified tables from .moor files
2019-07-29 12:54:49 +02:00
Simon Binder
a550a49705
Export table structure from CREATE TABLE statements
2019-07-28 22:09:20 +02:00
Simon Binder
3a2646e837
Only use the current analysis steps for CRUD statements
2019-07-28 21:22:18 +02:00
Simon Binder
0bad842735
Parse table constraints
2019-07-28 21:01:48 +02:00
Simon Binder
7e0bfa9cf9
Parse foreign clauses as column constraints
2019-07-28 20:18:22 +02:00
Simon Binder
7b6802e1c5
Split parser implementation into multiple files
2019-07-27 20:47:11 +02:00
Simon Binder
1766bb3f77
Fix tests that used "table" as a table name
...
(we now recognize that as a keyword)
2019-07-26 13:49:25 +02:00
Simon Binder
dee9993c83
Parse CREATE TABLE statements
2019-07-26 13:35:49 +02:00
Simon Binder
888e429467
Write model classes to represent CREATE TABLE statements
2019-07-26 11:35:53 +02:00
Simon Binder
6c84013cfa
Correctly find references to aliased columns
2019-07-25 17:44:59 +02:00
Simon Binder
82f84732d0
Resolve aliased columns
2019-07-25 17:33:01 +02:00
Simon Binder
d01b5c750f
Fix order in limit expressions with comma
...
Fixes #73
2019-07-10 17:29:03 +02:00
Simon Binder
aeb9b6ba41
Parse COLLATE expressions in the sql parser
...
For #67
2019-07-08 23:03:03 +02:00
Simon Binder
b0ca66bc06
Parse empty tuples
...
Closes #54
2019-07-02 22:30:54 +02:00
Simon Binder
1654193af4
Make parser assert it's at end after finishing
2019-07-02 22:21:20 +02:00
Simon Binder
c5d46adcb5
Parse JOIN clauses without additional operators
...
Fixes #56
2019-07-02 22:07:30 +02:00
Simon Binder
3024157ec9
Parse and analyze tuples, rework type resolution for `IN`
2019-07-02 14:38:28 +02:00
Simon Binder
285113717f
Parse tuples
2019-07-02 12:48:08 +02:00
Simon Binder
316f9e1052
Only resolve columns declared in scope of a statement
...
Fixes #52
2019-07-02 12:28:54 +02:00
Simon Binder
3dddc6993a
Remove outdated todo entries
2019-07-01 21:37:08 +02:00
Simon Binder
a45d73a6cf
Update documentation, fix multiline parsing
2019-07-01 21:20:59 +02:00
Simon Binder
da07be2da4
Parse exists expressions
2019-07-01 14:27:08 +02:00
Simon Binder
3e910123d2
Resolve and infer types related to like expressions
2019-07-01 13:59:52 +02:00
Simon Binder
791afdb6bf
Support ESCAPE clause for LIKE and similar expressions
2019-07-01 13:52:46 +02:00
Simon Binder
464754267e
Document new features for version 1.5
2019-06-30 22:16:58 +02:00
Simon Binder
baf3c9ce88
Parse update statements
2019-06-30 15:25:39 +02:00
Simon Binder
3f0776faf8
Fix tests, parse delete statements
2019-06-29 22:47:40 +02:00
Simon Binder
ff530dd4ea
Improve documentation of the sqlparser library
2019-06-29 22:29:16 +02:00
Simon Binder
d9f5cf0e69
Resolve types for case expressions
2019-06-29 18:02:44 +02:00
Simon Binder
9c07eaa465
Parse case expressions
2019-06-29 17:59:18 +02:00