-
Notifications
You must be signed in to change notification settings - Fork 664
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AlaSQL v3 #1240
Comments
@mathiasrw Thank you for the interest in my approach. First I want to clarify that my approach (initial phase) it is focused more on the long term future and vision but still does not neglect topics about performance, quality, library size etc. Here is a simple presentation: Core
Input Adapters - Integrate data to the standard of JSON Data Tables. Live/Passthrough option available. *I strongly recommend limiting SQL syntax only to data query for 3 main reasons: 1. Less parsing needed so smaller and simpler parsing library. 2. The real power of SQL is in the querying capability (no doubt about that). 3. JS is much better for the rest of DML features in SQL language. Doing this only with JS will be much more performant also. Another big reason is convenience. Usually users already have or can easily import data to an object, but it's not so easy to transform an object to a SQL insert statement. With JS you can just run db.insert(data_object). Source: I have been writing complex SQL/NoSQL queries for enterprises for the last 10 years to feed my family. |
I still have trouble understanding how the current parser works. Do you have any additional documentation for this? |
@noid2 Thank you for taking the time document how you are thinking. I am sorry that I did not have time this week to go fully into the dialogue. The box you call the core will probably need two more boxes. One for parsing the SQL string -> AST (abstract syntax tree) and one that generates the functions that does the actual work of selecting/filtering from the AST. There is no additional documentation about the parser. You can have a look at https://zaa.ch/jison/docs to see more about how Jison works, but I am not sure this will help you understand how the parser and the compiling of the function actually works. The model in alasqlparser.jison basically outputs an ATS. |
@mathiasrw I have assumed SQL Parsing, Compiling and Executing in the SQL Box. This could be the reason why AlaSQL is so popular. :) |
Lets move the discussion to #1558 |
The codebase is a single file monolit at the moment. This makes it hard to use only the parts you need. The structure also makes it hard to introduce new maintainers as things are not aligned with how JS development is done today.
Lets discuss the next version of AlaSQL in this card. Some old ideas has been documented in https://github.com/agershun/alasql/milestone/7 and @noid2 had a great input here: #157 (comment)
I suggest the goals for the next version to be:
INSERT
,SELECT
,WHERE
from in-memory is the foundation (no join, sub query) together with user defined functionsThe text was updated successfully, but these errors were encountered: