Gluesql

Latest version: v0.15.0

Safety actively analyzes 623608 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 4

0.14.0

We now provide an official documentation website at **https://gluesql.org/docs**

πŸš€ Features

πŸ€ Schemaless data support

GlueSQL now supports creating tables without a schema, allowing for both structured and unstructured data to be stored in the same table.
To create a schemaless table, simply run CREATE TABLE without specifying any columns. For more information on querying schemaless data, please refer to the following link: **[querying schemaless data](https://gluesql.org/docs/dev/sql-syntax/statements/querying/schemaless)**

sql
CREATE TABLE Bar;


To insert values,
sql
INSERT INTO Bar VALUES
('{ "name": "ast", "value": 30 }'),
('{ "name": "glue", "rate": 3.0, "list": [1, 2, 3] }'),


Then, selecting values from schemaless table is simple.
sql
SELECT name, rate, list[0] FROM Bar WHERE name = 'glue';


e.g.
sql
CREATE TABLE Names (id INTEGER, name TEXT);
INSERT INTO Names VALUES (1, 'glue'), (2, 'sql');

CREATE TABLE Logs;
INSERT INTO Logs VALUES
('{ "id": 1, "value": 30 }'),
('{ "id": 2, "rate": 3.0, "list": [1, 2, 3] }'),
('{ "id": 3, "rate": 5.0, "value": 100 }');

SELECT * FROM Names JOIN Logs ON Names.id = Logs.id;
/*
| id | list | name | rate | value |
|----|---------|------|------|-------|
| 1 | | glue | | 30 |
| 2 |[1, 2, 3]| sql | 3 | |
*/

- Schemaless data support [panarch](https://github.com/panarch) ([#1046](https://github.com/gluesql/gluesql/pull/1046))

πŸ€ IndexedDB & WebStorage supports in JavaScript package

GlueSQL supports handling in-memory, localStorage, sessionStorage, and even IndexedDB using the same SQL syntax. All you need to know is how to specify the `ENGINE` when creating a table.

e.g.
sql
CREATE TABLE Mem (mid INTEGER) ENGINE = memory;
CREATE TABLE Loc (lid INTEGER) ENGINE = localStorage;
CREATE TABLE Ses (sid INTEGER) ENGINE = sessionStorage;
CREATE TABLE Idb (iid INTEGER) ENGINE = indexedDB;

SELECT
mid, lid, sid, iid
FROM Mem
JOIN Loc
JOIN Ses
JOIN Idb;


- Apply CompositeStorage to JS package [panarch](https://github.com/panarch) ([#1084](https://github.com/gluesql/gluesql/pull/1084))

πŸ€ Data Types - `UINT32`, `UINT64`, `UINT128`, `POINT` and `FLOAT32`
- implement f32 data type [pythonbrad](https://github.com/pythonbrad) ([#1145](https://github.com/gluesql/gluesql/pull/1145))
- Implement geometric `POINT` Type and geometric functions [seonghun-dev](https://github.com/seonghun-dev) ([#1048](https://github.com/gluesql/gluesql/pull/1048))
- Add `UINT32`, `UINT64` and `UINT128` data types [ChobobDev](https://github.com/ChobobDev) ([#1019](https://github.com/gluesql/gluesql/pull/1019))
- Add inet datatype [pythonbrad](https://github.com/pythonbrad) ([#1080](https://github.com/gluesql/gluesql/pull/1080))

πŸ€ Functions - `APPEND`, `PREPEND`, `RAND`, `FIND_IDX`, `INITCAP` and `CALC_DISTANCE`

- Feat : add calc\_distance function [seonghun-dev](https://github.com/seonghun-dev) ([#1153](https://github.com/gluesql/gluesql/pull/1153))
- Add `PREPEND` function for `LIST` data type [seonghun-dev](https://github.com/seonghun-dev) ([#1149](https://github.com/gluesql/gluesql/pull/1149))
- add initcap function [pythonbrad](https://github.com/pythonbrad) ([#1064](https://github.com/gluesql/gluesql/pull/1064))
- Implement `FIND_IDX` function [zmrdltl](https://github.com/zmrdltl) ([#1100](https://github.com/gluesql/gluesql/pull/1100))
- Implement Rand function [pythonbrad](https://github.com/pythonbrad) ([#1063](https://github.com/gluesql/gluesql/pull/1063))
- Add Append Function to LIST DataType [seonghun-dev](https://github.com/seonghun-dev) ([#1047](https://github.com/gluesql/gluesql/pull/1047))

πŸ€ Store traits

User-level custom function
By implementing both the CustomFunction and CustomFunctionMut traits, users can create, use, and delete user-level custom functions. Although GlueSQL plans to continuously add various functions, users may still find them insufficient. In such cases, users can create their own user-level custom functions to supplement the built-in functions. Additionally, if there are repetitive business logic codes, they can be stored as custom functions.
e.g.
sql
CREATE FUNCTION ADD_ONE (n INT, x INT DEFAULT 1) RETURN n + x;

SELECT ADD_ONE(10) AS test;

DROP FUNCTION ADD_ONE;


- Support user level sql function [pythonbrad](https://github.com/pythonbrad) ([#1095](https://github.com/gluesql/gluesql/pull/1095))

Metadata
The Metadata trait is an optional implementation for providing additional metadata support in GlueSQL. GlueSQL does not enforce any specific metadata implementation, allowing custom storage developers to decide which type of metadata, such as create time, modify time, etc., they want to provide.

- Support Metadata trait [devgony](https://github.com/devgony) ([#1096](https://github.com/gluesql/gluesql/pull/1096))

πŸ€ Storages

JSON Storage
- Add JsonStorage support to CLI [devgony](https://github.com/devgony) ([#1135](https://github.com/gluesql/gluesql/pull/1135))
- Rename `Jsonl`Storage to `Json`Storage [devgony](https://github.com/devgony) ([#1128](https://github.com/gluesql/gluesql/pull/1128))
- Support `JSON` format in `JSONL storage` [devgony](https://github.com/devgony) ([#1123](https://github.com/gluesql/gluesql/pull/1123))
- Support `Jsonl` Storage [devgony](https://github.com/devgony) ([#1053](https://github.com/gluesql/gluesql/pull/1053))

Composite Storage
- Add CompositeStorage which bundles multiple storages [panarch](https://github.com/panarch) ([#1068](https://github.com/gluesql/gluesql/pull/1068))

IndexedDB Storage
- Add IndexedDB storage support [panarch](https://github.com/panarch) ([#1067](https://github.com/gluesql/gluesql/pull/1067))

Web Storage
- Add WebStorage - support localStorage \& sessionStorage for web browsers [panarch](https://github.com/panarch) ([#1050](https://github.com/gluesql/gluesql/pull/1050))

πŸ€ Other new features

- Wrap identifiers with double quote (`"`) at `to_sql` [devgony](https://github.com/devgony) ([#1130](https://github.com/gluesql/gluesql/pull/1130))
- Support Values Query at ASTBuilder [devgony](https://github.com/devgony) ([#1041](https://github.com/gluesql/gluesql/pull/1041))
- Support `Schema::from_ddl(ddl: &str) -> String` [devgony](https://github.com/devgony) ([#1089](https://github.com/gluesql/gluesql/pull/1089))
- Support column alias for Table, Derived Table [ding-young](https://github.com/ding-young) ([#1065](https://github.com/gluesql/gluesql/pull/1065))
- Support `TableFactor::{Derived, Dictionary, Series}` in AstBuilder [devgony](https://github.com/devgony) ([#1007](https://github.com/gluesql/gluesql/pull/1007))

🌊 Interface Changes

- Remove Store trait related cfg features, [panarch](https://github.com/panarch) ([#1091](https://github.com/gluesql/gluesql/pull/1091))
- Refactor CreateTable.columns from `Vec<ColumnDef>` to `Option<Vec<ColumnDef>>` [devgony](https://github.com/devgony) ([#1086](https://github.com/gluesql/gluesql/pull/1086))
- Remove `MutResult` [panarch](https://github.com/panarch) ([#1073](https://github.com/gluesql/gluesql/pull/1073))
- Update all store mut trait methods to take \&mut self [panarch](https://github.com/panarch) ([#1072](https://github.com/gluesql/gluesql/pull/1072))
- Change StoreMut interface to use \&mut self, not to take ownership [panarch](https://github.com/panarch) ([#1071](https://github.com/gluesql/gluesql/pull/1071))
- Modify default ColumnOption from NOT NULL to NULL [devgony](https://github.com/devgony) ([#997](https://github.com/gluesql/gluesql/pull/997))

🌟 Improvements

- Add a case for insert with source [devgony](https://github.com/devgony) ([#1211](https://github.com/gluesql/gluesql/pull/1211))
- Apply workspace inheritance to remaining Cargo.toml in storages/, [panarch](https://github.com/panarch) ([#1181](https://github.com/gluesql/gluesql/pull/1181))
- Add nullable, key, default to `GLUE_TABLE_COLUMNS` [devgony](https://github.com/devgony) ([#1177](https://github.com/gluesql/gluesql/pull/1177))
- Update core to bundle all errors using error module, [panarch](https://github.com/panarch) ([#1178](https://github.com/gluesql/gluesql/pull/1178))
- Update global Error enum to display with error module prefix [panarch](https://github.com/panarch) ([#1175](https://github.com/gluesql/gluesql/pull/1175))
- fix: typo [ever0de](https://github.com/ever0de) ([#1161](https://github.com/gluesql/gluesql/pull/1161))
- Move the SCHEMA\_PREFIX const into an impl in SledStorage [garypen](https://github.com/garypen) ([#1151](https://github.com/gluesql/gluesql/pull/1151))
- Merge evaluate\_stateless into evaluate, [panarch](https://github.com/panarch) ([#1132](https://github.com/gluesql/gluesql/pull/1132))
- Remove memory-storage dep from JsonStorage/ Cargo.toml [panarch](https://github.com/panarch) ([#1131](https://github.com/gluesql/gluesql/pull/1131))
- Simplify JsonlStorage codes [panarch](https://github.com/panarch) ([#1126](https://github.com/gluesql/gluesql/pull/1126))
- Bump rust version to 1.68 [ever0de](https://github.com/ever0de) ([#1125](https://github.com/gluesql/gluesql/pull/1125))
- Keep `Cargo.lock` [ever0de](https://github.com/ever0de) ([#1121](https://github.com/gluesql/gluesql/pull/1121))
- Replace closure to variable in `data/interval` module [ever0de](https://github.com/ever0de) ([#1118](https://github.com/gluesql/gluesql/pull/1118))
- Add `f64` support to `data::Key` [panarch](https://github.com/panarch) ([#1114](https://github.com/gluesql/gluesql/pull/1114))
- Add Ord impl for Key, [panarch](https://github.com/panarch) ([#1110](https://github.com/gluesql/gluesql/pull/1110))
- join\_expr when in\_subquery, exists expr in join constraint [ding-young](https://github.com/ding-young) ([#1112](https://github.com/gluesql/gluesql/pull/1112))
- Split JS related GitHub action, [panarch](https://github.com/panarch) ([#1109](https://github.com/gluesql/gluesql/pull/1109))
- Fix error handling for `ilike` function on `Literal` being treated as… [ever0de](https://github.com/ever0de) ([#1107](https://github.com/gluesql/gluesql/pull/1107))
- Remove `Rc` in `validate.rs` [ever0de](https://github.com/ever0de) ([#1106](https://github.com/gluesql/gluesql/pull/1106))
- Remove `Error::Storage` variant [ever0de](https://github.com/ever0de) ([#1105](https://github.com/gluesql/gluesql/pull/1105))
- Replace `Box::pin` to `futures_enum::Stream` [ever0de](https://github.com/ever0de) ([#1103](https://github.com/gluesql/gluesql/pull/1103))
- Remove stream unneeded map ok uses [panarch](https://github.com/panarch) ([#1104](https://github.com/gluesql/gluesql/pull/1104))
- Replace `TryStream` to `Stream` [ever0de](https://github.com/ever0de) ([#1102](https://github.com/gluesql/gluesql/pull/1102))
- Remove `Rc` from `ColumnValidation` [ever0de](https://github.com/ever0de) ([#1101](https://github.com/gluesql/gluesql/pull/1101))
- Remove unneeded Rc uses in fetch\_labels [panarch](https://github.com/panarch) ([#1098](https://github.com/gluesql/gluesql/pull/1098))
- Simplify TryStreamExt using codes in join executor, [panarch](https://github.com/panarch) ([#1097](https://github.com/gluesql/gluesql/pull/1097))
- Fix typo in plan/validate.rs [ever0de](https://github.com/ever0de) ([#1093](https://github.com/gluesql/gluesql/pull/1093))
- Update IdbStorage to use Schema::{to\_ddl, from\_ddl} to manage schema … [panarch](https://github.com/panarch) ([#1090](https://github.com/gluesql/gluesql/pull/1090))
- Update Cargo.toml files to inherit workspace level configs, [panarch](https://github.com/panarch) ([#1088](https://github.com/gluesql/gluesql/pull/1088))
- Add Error enum to core::prelude [panarch](https://github.com/panarch) ([#1087](https://github.com/gluesql/gluesql/pull/1087))
- Update `StringExt` implementation to use `str` [ever0de](https://github.com/ever0de) ([#1082](https://github.com/gluesql/gluesql/pull/1082))
- Add enum `StrSlice` under enum `Evaluated` [zmrdltl](https://github.com/zmrdltl) ([#999](https://github.com/gluesql/gluesql/pull/999))
- refactor plan::validate::Context.labels from String to str [devgony](https://github.com/devgony) ([#1079](https://github.com/gluesql/gluesql/pull/1079))
- Replace `dyn object` to generic [ever0de](https://github.com/ever0de) ([#1075](https://github.com/gluesql/gluesql/pull/1075))
- Implement ValidationContext(schema\_map + alias) to enhance validation of ambiguous columns [devgony](https://github.com/devgony) ([#883](https://github.com/gluesql/gluesql/pull/883))
- Remove `clone` in `check_table_factor` [ever0de](https://github.com/ever0de) ([#1058](https://github.com/gluesql/gluesql/pull/1058))
- Bump rust-toolchain version to `1.66` [ever0de](https://github.com/ever0de) ([#1057](https://github.com/gluesql/gluesql/pull/1057))
- Bump `sqlparser` version to `0.30` [ever0de](https://github.com/ever0de) ([#1056](https://github.com/gluesql/gluesql/pull/1056))
- Replace `Box::pin` to `futures_enum` in aggregate module [ever0de](https://github.com/ever0de) ([#1055](https://github.com/gluesql/gluesql/pull/1055))
- Update js/ Cargo.toml to use gloo-utils for serde handling [panarch](https://github.com/panarch) ([#1049](https://github.com/gluesql/gluesql/pull/1049))
- Remove ast::ColumnOption and merge UNIQUE option to ColumnDef [panarch](https://github.com/panarch) ([#1044](https://github.com/gluesql/gluesql/pull/1044))
- Rewrite \& simplify plan/context.rs codes, [panarch](https://github.com/panarch) ([#1045](https://github.com/gluesql/gluesql/pull/1045))
- Move ast::ColumnOption::Default variant to ColumnDef [panarch](https://github.com/panarch) ([#1042](https://github.com/gluesql/gluesql/pull/1042))
- [AST-Builder] Remove unused prebuild nodes [ding-young](https://github.com/ding-young) ([#1043](https://github.com/gluesql/gluesql/pull/1043))
- Remove data::RowError, [panarch](https://github.com/panarch) ([#1040](https://github.com/gluesql/gluesql/pull/1040))
- Reorder project in ASTBuilder (project -> ordery\_by -> limit,offset) [devgony](https://github.com/devgony) ([#1039](https://github.com/gluesql/gluesql/pull/1039))
- Remove unused LimitOffsetNode in AST builder [panarch](https://github.com/panarch) ([#1038](https://github.com/gluesql/gluesql/pull/1038))
- Rename executor/ blend.rs module to project.rs [SaumyaBhushan](https://github.com/SaumyaBhushan) ([#1036](https://github.com/gluesql/gluesql/pull/1036))
- Add Debug to AST builder nodes [panarch](https://github.com/panarch) ([#1022](https://github.com/gluesql/gluesql/pull/1022))
- Bump rust toolchain version to 1.65 [ever0de](https://github.com/ever0de) ([#1035](https://github.com/gluesql/gluesql/pull/1035))
- Remove `Content::Shared` variant in executor/ `RowContext` [ever0de](https://github.com/ever0de) ([#1032](https://github.com/gluesql/gluesql/pull/1032))
- Merge insert logics in row.rs \& execute.rs into executor/insert.rs [panarch](https://github.com/panarch) ([#1031](https://github.com/gluesql/gluesql/pull/1031))
- Merge FilterContext and BlendContext into RowContext [panarch](https://github.com/panarch) ([#1029](https://github.com/gluesql/gluesql/pull/1029))
- Update `data::Row` to contain columns [panarch](https://github.com/panarch) ([#1026](https://github.com/gluesql/gluesql/pull/1026))
- Add LIST type support in CONCAT function [seonghun-dev](https://github.com/seonghun-dev) ([#1021](https://github.com/gluesql/gluesql/pull/1021))
- Remove LimitOffsetNode in AST builder [panarch](https://github.com/panarch) ([#1023](https://github.com/gluesql/gluesql/pull/1023))
- Fix typo [ever0de](https://github.com/ever0de) ([#1020](https://github.com/gluesql/gluesql/pull/1020))
- Add NumericNode to handle numeric value inputs in AST builder [panarch](https://github.com/panarch) ([#1017](https://github.com/gluesql/gluesql/pull/1017))
- Update ValueError::InvalidJsonString error to show input text [panarch](https://github.com/panarch) ([#1018](https://github.com/gluesql/gluesql/pull/1018))
- Add null() func which makes NULL value in AST builder [panarch](https://github.com/panarch) ([#1016](https://github.com/gluesql/gluesql/pull/1016))
- Add --all-targets option to cargo clippy rust gh-action [panarch](https://github.com/panarch) ([#1015](https://github.com/gluesql/gluesql/pull/1015))
- Move import `ColumnOption` used only by `alter-table` feature in ast-builder [ever0de](https://github.com/ever0de) ([#1014](https://github.com/gluesql/gluesql/pull/1014))
- Add value/ binary\_op `Parital{Ord,Cmp}` impl macro [ever0de](https://github.com/ever0de) ([#1013](https://github.com/gluesql/gluesql/pull/1013))
- Change to use internal chrono errors in parsing datetime [ever0de](https://github.com/ever0de) ([#1010](https://github.com/gluesql/gluesql/pull/1010))
- Resolve unreachable branch of `Value::position` [ever0de](https://github.com/ever0de) ([#1012](https://github.com/gluesql/gluesql/pull/1012))
- Apply binary\_op macros to existing data types [ChobobDev](https://github.com/ChobobDev) ([#987](https://github.com/gluesql/gluesql/pull/987))
- chore: Use rust-cache action to cache dependencies [jongwooo](https://github.com/jongwooo) ([#1006](https://github.com/gluesql/gluesql/pull/1006))
- Group the import statements [yugeeklab](https://github.com/yugeeklab) ([#1005](https://github.com/gluesql/gluesql/pull/1005))
- Make Tester::new async [ShaddyDC](https://github.com/ShaddyDC) ([#1004](https://github.com/gluesql/gluesql/pull/1004))
- Make MemoryStorage Store trait features optional, [panarch](https://github.com/panarch) ([#1003](https://github.com/gluesql/gluesql/pull/1003))
- Replace `double quotes` to `identifier` [devgony](https://github.com/devgony) ([#1001](https://github.com/gluesql/gluesql/pull/1001))
- Change chrono `from_*` methods to `from_*_opt` [ever0de](https://github.com/ever0de) ([#1000](https://github.com/gluesql/gluesql/pull/1000))
- Improve duplicate column names validation [devgony](https://github.com/devgony) ([#995](https://github.com/gluesql/gluesql/pull/995))
- Register `lock` when `fetch_all_schemas` face `idle` [devgony](https://github.com/devgony) ([#996](https://github.com/gluesql/gluesql/pull/996))
- Merge ColumnOption::{Null, NotNull} into a single option [devgony](https://github.com/devgony) ([#986](https://github.com/gluesql/gluesql/pull/986))
- Update rust.yml github action to test examples/ [panarch](https://github.com/panarch) ([#994](https://github.com/gluesql/gluesql/pull/994))


🌳 Documentation

**We now provide an official documentation website at https://gluesql.org/docs**

- Add documentation for CLI [devgony](https://github.com/devgony) ([#1183](https://github.com/gluesql/gluesql/pull/1183))
- Add ast\_builder null handling doc [LEE026](https://github.com/LEE026) ([#1209](https://github.com/gluesql/gluesql/pull/1209))
- Add document of datetime current date and time for ast-builder [heewoneha](https://github.com/heewoneha) ([#1208](https://github.com/gluesql/gluesql/pull/1208))
- docs: write position and indexing docs [Bangseungjae](https://github.com/Bangseungjae) ([#1206](https://github.com/gluesql/gluesql/pull/1206))
- Add docs/formatting for ast\_builder [sooyeonyim-t](https://github.com/sooyeonyim-t) ([#1200](https://github.com/gluesql/gluesql/pull/1200))
- Update math basic arithmetic docs for ast\_builder [changi1122](https://github.com/changi1122) ([#1202](https://github.com/gluesql/gluesql/pull/1202))
- Add pattern-matching doc for ast\_builder [LEE026](https://github.com/LEE026) ([#1199](https://github.com/gluesql/gluesql/pull/1199))
- Add ast builder Trimming function docs [Bangseungjae](https://github.com/Bangseungjae) ([#1197](https://github.com/gluesql/gluesql/pull/1197))
- Add doc about the function Date \& Time Conversion [heewoneha](https://github.com/heewoneha) ([#1196](https://github.com/gluesql/gluesql/pull/1196))
- add Docs/case conversion(upper, lower, InitCap) in ast builder [sooyeonyim-t](https://github.com/sooyeonyim-t) ([#1195](https://github.com/gluesql/gluesql/pull/1195))
- Add math conversion docs for ast\_builder [changi1122](https://github.com/changi1122) ([#1192](https://github.com/gluesql/gluesql/pull/1192))
- Added documentation for the round, ceil, and floor functions in ast-builder [LEE026](https://github.com/LEE026) ([#1191](https://github.com/gluesql/gluesql/pull/1191))
- Add documentation layout for AstBuilder [devgony](https://github.com/devgony) ([#1184](https://github.com/gluesql/gluesql/pull/1184))
- Add documentation for Json Storage [devgony](https://github.com/devgony) ([#1170](https://github.com/gluesql/gluesql/pull/1170))
- Add documentation for math functions [panarch](https://github.com/panarch) ([#1173](https://github.com/gluesql/gluesql/pull/1173))
- Add doc for datetime, geometry, list \& map and other functions, [panarch](https://github.com/panarch) ([#1172](https://github.com/gluesql/gluesql/pull/1172))
- Add documentation for text functions in SQL [panarch](https://github.com/panarch) ([#1167](https://github.com/gluesql/gluesql/pull/1167))
- Write docs/ Supported Storages section contents, [panarch](https://github.com/panarch) ([#1165](https://github.com/gluesql/gluesql/pull/1165))
- Add SQL function list with categories to docs/ [panarch](https://github.com/panarch) ([#1166](https://github.com/gluesql/gluesql/pull/1166))
- Write docs/getting-started/javascript-web.md [panarch](https://github.com/panarch) ([#1159](https://github.com/gluesql/gluesql/pull/1159))
- Write docs/ Developing Custom Storages contents [panarch](https://github.com/panarch) ([#1155](https://github.com/gluesql/gluesql/pull/1155))
- docs: add newly added data type into README.md [ChobobDev](https://github.com/ChobobDev) ([#1137](https://github.com/gluesql/gluesql/pull/1137))
- docs(readme): add discord icon to chat badge [LeoDog896](https://github.com/LeoDog896) ([#1122](https://github.com/gluesql/gluesql/pull/1122))
- docs(javascript): update examples link [LeoDog896](https://github.com/LeoDog896) ([#1108](https://github.com/gluesql/gluesql/pull/1108))

Docs - setup

- Add gh-action for docs build - runs on both push \& pr [panarch](https://github.com/panarch) ([#1215](https://github.com/gluesql/gluesql/pull/1215))
- Setup blog based on docusaurus, [panarch](https://github.com/panarch) ([#1212](https://github.com/gluesql/gluesql/pull/1212))
- Remove mdbook which is replaced by docs/ (docusaurus based) [panarch](https://github.com/panarch) ([#1164](https://github.com/gluesql/gluesql/pull/1164))
- Add docusaurus deployment github action setup [panarch](https://github.com/panarch) ([#1163](https://github.com/gluesql/gluesql/pull/1163))
- Update coverage, javascript and rust gh action to ignore `docs/**` pa… [panarch](https://github.com/panarch) ([#1168](https://github.com/gluesql/gluesql/pull/1168))
- Update docs/ global styles, [panarch](https://github.com/panarch) ([#1156](https://github.com/gluesql/gluesql/pull/1156))
- Setup new documentation based on docusaurus [panarch](https://github.com/panarch) ([#1136](https://github.com/gluesql/gluesql/pull/1136))


πŸ“‹ Tests

- Add ifnull test suite for ast\_builder [LEE026](https://github.com/LEE026) ([#1207](https://github.com/gluesql/gluesql/pull/1207))
- Add datetime current date and time test case for ast builder [heewoneha](https://github.com/heewoneha) ([#1205](https://github.com/gluesql/gluesql/pull/1205))
- Add Position and Indexing test code [Bangseungjae](https://github.com/Bangseungjae) ([#1203](https://github.com/gluesql/gluesql/pull/1203))
- Add math basic arithmetic test case for ast\_builder [changi1122](https://github.com/changi1122) ([#1201](https://github.com/gluesql/gluesql/pull/1201))
- Add testcase/formatting for ast\_builder [sooyeonyim-t](https://github.com/sooyeonyim-t) ([#1198](https://github.com/gluesql/gluesql/pull/1198))
- Add pattern\_matching test cases for ast\_builder [LEE026](https://github.com/LEE026) ([#1194](https://github.com/gluesql/gluesql/pull/1194))
- Add test code function / text / trimming [Bangseungjae](https://github.com/Bangseungjae) ([#1190](https://github.com/gluesql/gluesql/pull/1190))
- Add Testcase/case conversion [sooyeonyim-t](https://github.com/sooyeonyim-t) ([#1193](https://github.com/gluesql/gluesql/pull/1193))
- Add datetime conversion test cases for ast\_builder [heewoneha](https://github.com/heewoneha) ([#1187](https://github.com/gluesql/gluesql/pull/1187))
- Add math conversion test case for ast\_builder [changi1122](https://github.com/changi1122) ([#1189](https://github.com/gluesql/gluesql/pull/1189))
- Add rounding test cases for ast\_builder [LEE026](https://github.com/LEE026) ([#1186](https://github.com/gluesql/gluesql/pull/1186))
- Update delete and insert tests in test-suite/, [panarch](https://github.com/panarch) ([#1180](https://github.com/gluesql/gluesql/pull/1180))
- Remove gen-\_transaction\_dictionary\_tests! in test-suite, [panarch](https://github.com/panarch) ([#1179](https://github.com/gluesql/gluesql/pull/1179))
- Refactor geometry function tests in test-suite, [panarch](https://github.com/panarch) ([#1176](https://github.com/gluesql/gluesql/pull/1176))
- Refactor SQL function tests in test-suite, [panarch](https://github.com/panarch) ([#1174](https://github.com/gluesql/gluesql/pull/1174))
- fix : fix missing intg test for new data type [ChobobDev](https://github.com/ChobobDev) ([#1143](https://github.com/gluesql/gluesql/pull/1143))
- Add unit tests for `TryFrom<&Value> for Decimal` [ChobobDev](https://github.com/ChobobDev) ([#1139](https://github.com/gluesql/gluesql/pull/1139))
- Add "cli" unittest [pythonbrad](https://github.com/pythonbrad) ([#1094](https://github.com/gluesql/gluesql/pull/1094))
- Add `core/data` module unit tests [pythonbrad](https://github.com/pythonbrad) ([#1092](https://github.com/gluesql/gluesql/pull/1092))

πŸ› Bug Fixes

- Fix docusaurus pages/index broken link [panarch](https://github.com/panarch) ([#1214](https://github.com/gluesql/gluesql/pull/1214))
- Fix docs/ Discord GlueSQL channel invite link address [panarch](https://github.com/panarch) ([#1213](https://github.com/gluesql/gluesql/pull/1213))
- Fix InvalidJsonString error message replacing payload to fileName [devgony](https://github.com/devgony) ([#1185](https://github.com/gluesql/gluesql/pull/1185))
- Fix TryFrom `Value::Str` to `u128` not to use `parse_uuid` [ChobobDev](https://github.com/ChobobDev) ([#1134](https://github.com/gluesql/gluesql/pull/1134))
- Fix column alias with identifer for `TableFactor::Derived` [ding-young](https://github.com/ding-young) ([#1119](https://github.com/gluesql/gluesql/pull/1119))
- Pass data even when `deleted_by` is not present [ever0de](https://github.com/ever0de) ([#1117](https://github.com/gluesql/gluesql/pull/1117))
- Fix MemoryStorage \& WebStorage primary key support [panarch](https://github.com/panarch) ([#1115](https://github.com/gluesql/gluesql/pull/1115))
- Fix `plan::validate` to handle `CTAS` and `ITAS` adding unit test [devgony](https://github.com/devgony) ([#1074](https://github.com/gluesql/gluesql/pull/1074))
- Fix test-suite tester functions to show (found, expected) shape [panarch](https://github.com/panarch) ([#1028](https://github.com/gluesql/gluesql/pull/1028))

πŸ‘ New Contributors
* arbfay made their first contribution in https://github.com/gluesql/gluesql/pull/971
* ShaddyDC made their first contribution in https://github.com/gluesql/gluesql/pull/1004
* yugeeklab made their first contribution in https://github.com/gluesql/gluesql/pull/1005
* jongwooo made their first contribution in https://github.com/gluesql/gluesql/pull/1006
* SaumyaBhushan made their first contribution in https://github.com/gluesql/gluesql/pull/1036
* LeoDog896 made their first contribution in https://github.com/gluesql/gluesql/pull/1108
* garypen made their first contribution in https://github.com/gluesql/gluesql/pull/1151
* LEE026 made their first contribution in https://github.com/gluesql/gluesql/pull/1186
* changi1122 made their first contribution in https://github.com/gluesql/gluesql/pull/1192
* heewoneha made their first contribution in https://github.com/gluesql/gluesql/pull/1187
* sooyeonyim-t made their first contribution in https://github.com/gluesql/gluesql/pull/1193
* Bangseungjae made their first contribution in https://github.com/gluesql/gluesql/pull/1190

**Full Changelog**: https://github.com/gluesql/gluesql/compare/v0.13.1...v0.14.0

0.13.1

🌟 CLI - Data migration support

Dump whole schemas and data by generating SQL using `--dump {PATH}` option

sh
$ gluesql --path ~/glue_data --dump ./dump.sql


sql
-- dump.sql
CREATE TABLE Item (id INT, name TEXT);
CREATE INDEX item_id ON Item (id);
..
INSERT INTO Item VALUES (1, 'Foo'), (2, 'Bar') ..
..


Import database

sh
$ gluesql --path ~/new_data --execute ./dump.sql


What's Changed
* Support the way to migrate whole databse with `--dump {PATH}` argument (+`to_ddl()`) by devgony in https://github.com/gluesql/gluesql/pull/977
* Replace double quote to single quote by devgony in https://github.com/gluesql/gluesql/pull/988
* Replace `TryFrom for AstLiteral` => `TryFrom for Expr`, add more test to dump by devgony in https://github.com/gluesql/gluesql/pull/990
* Bump cli, core, pkg/rust and test-suite versions to v0.13.1 by panarch in https://github.com/gluesql/gluesql/pull/991


**Full Changelog**: https://github.com/gluesql/gluesql/compare/v0.13.0...v0.13.1

0.13.0

🌊 Breaking Changes
🌟 AST Builder
AST Builder is now ready to be used!
GlueSQL AST builder provides iterator chaining experience to manipulate data which is similar to array chaining methods or DataFrame syntax.
For someone who is already familiar with SQL, then there would be almost no extra learning cost to use GlueSQL AST builder.
AST builder accepts various sets of params - not only the expression built by its own expr builder, but also it even accepts raw SQL text and prebuilt ASTs.

e.g.
rust
table("Item")
.select()
.join("Category")
.on(col("Category.id").eq("Item.category_id"))
.group_by("Item.category_id")
.having("SUM(Item.price) > 80")
.project("Category.name AS category")
.project("SUM(Item.price) AS sum_price")
.execute(glue)
.await;

| category | sum_price
|------------|-------------|
| Meat | 90 |
| Drink | 85 |

Usage code examples
[SELECT queries](https://github.com/gluesql/gluesql/blob/main/test-suite/src/ast_builder/select.rs)
[INSERT queries](https://github.com/gluesql/gluesql/blob/main/test-suite/src/ast_builder/insert.rs)
[UPDATE queries](https://github.com/gluesql/gluesql/blob/main/test-suite/src/ast_builder/update.rs)
[DELETE queries](https://github.com/gluesql/gluesql/blob/main/test-suite/src/ast_builder/delete.rs)

Related PRs (features)
- Implement hash join support to AST builder panarch (916)
- [AST-Builder] Impl Case ding-young (910)
- [AST] Support `ArrayIndex`Expr ding-young (880)
- Implement AST builder execute function panarch (879)
- [Ast Builder] Implement join expression in select statement seonghun-dev (803)
- [AST] Implement to\_sql func for OrderByExpr CEOJINSUNG (812)
- [AST Builder] Implement to\_date and let format function to format date data type ChobobDev (858)
- [AST Builder] Implement Lower function ChobobDev (853)
- Implement order by ast builder 24seconds (841)
- [AST builder] Implement To\_date and To\_timestamp function ChobobDev (838)
- [AST Builder] Implement format function ChobobDev (836)
- [AST builder] Implement Insert statement kim-seo-hyun (802)
- [AST Builder] Implement Alter table statement ding-young (813)
- [AST-Builder] Create Table Statement ding-young (784)
- [AST Builder] Implement EXISTS Expression CEOJINSUNG (790)
- [AST Builder] Implement update Expression seonghun-dev (720)
- [AST Builder] Implement Div, Mod Function seonghun-dev (760)

Related PRs (improvements)
- Add AST builder integration tests of SELECT, UPDATE, INSERT and DELET… panarch (955)
- Update AST builder cast function unit test zmrdltl (957)
- Expose AST builder unary\_op methods to public, panarch (956)
- Rename AST builder ExprNode::not to ExprNode::negate sa1 (953)
- Add missing select nodes to ExprNode::InList and QueryNode in AST builder panarch (934)
- Simplify ast\_builder/ QueryNode codes using decl macro panarch (932)
- Add from ProjectNode \& QueryNode for InListNode in AST builder, panarch (925)
- Update ast-builder function expr params to use `Into<..Node>` panarch (926)
- Update AST builder between \& hash\_executor to accept different param … panarch (923)
- Add ExprNode::subquery, panarch (922)
- Add AST builder join nodes to query node conversion support panarch (921)
- Add setting table\_alias support to AST builder table init function panarch (920)
- [AST Builder] Combine in\_list and in\_subquery into in\_list CEOJINSUNG (808)
- [AST-Builder] change error message in test functions ding-young (800)
- Reformat : change ast builder function format seonghun-dev (796)


πŸš€ Features

πŸ“š New metadata tables - `GLUE_TABLES`, `GLUE_TABLE_COLUMNS` and `GLUE_INDEXES`

gluesql> SELECT * FROM GLUE_TABLES;

| TABLE_NAME |
|------------|
| Bar |
| Foo |

gluesql> SELECT * FROM GLUE_TABLE_COLUMNS;

| TABLE_NAME | COLUMN_NAME | COLUMN_ID |
|------------|-------------|-----------|
| Bar | id | 1 |
| Bar | name | 2 |
| Bar | type | 3 |
| Foo | id | 1 |
| Foo | name | 2 |

gluesql> SELECT * FROM GLUE_INDEXES;

| TABLE_NAME | INDEX_NAME | ORDER | EXPRESSION | UNIQUENESS |
|------------|----------------|-------|------------|------------|
| Foo | PRIMARY | BOTH | id | TRUE |
| Foo | Foo_id_1 | BOTH | id + 1 | FALSE |
| Foo | Foo_name_concat | BOTH | name + "_" | FALSE |

- Add support `GLUE_INDEXES` reserved table which provides all index info devgony (935)
- Support Dictionary(Schema) view devgony (869)

🧭 ORDER BY enhancements
Support ORDER BY `ALIAS` clause like below
sql
SELECT column_name AS alias_name FROM Table ORDER BY alias_name DESC

- Currently, it throws `[error] value not found: alias_name`
Original `column_name` is still available at ORDER BY clause though SELECT clause uses `alias_name`
sql
SELECT column_name AS alias_name FROM Table ORDER BY column_name DESC

Support ORDER BY `COLUMN_INDEX`
sql
SELECT alpha, beta FROM Table ORDER BY 1 DESC

- `1` means the column_index which is first column `alpha`

Support `ORDER BY` clause in `VALUES list`
sql
gluesql> VALUES (1, 'a'), (2, 'b') ORDER BY column1 DESC;
column1 | column2
---------+---------
2 | b
1 | a


Related PRs
- Support ORDER BY `ALIAS` and `COLUMN_INDEX` devgony (805)
- Support `ORDER BY` clause in `VALUES list` devgony (730)

πŸ“‹ `ToSql` trait for AST which provides AST to SQL text conversion for easier debugging
e.g.
`ToSql::to_sql` from the below AST returns this simple SQL text.

* Generated SQL text
sql
CREATE TABLE Foo (id INT, num INT NULL, name TEXT);

* Input AST
rust
Statement::CreateTable {
if_not_exists: false,
name: "Foo".into(),
columns: vec![
ColumnDef {
name: "id".to_owned(),
data_type: DataType::Int,
options: vec![]
},
ColumnDef {
name: "num".to_owned(),
data_type: DataType::Int,
options: vec![ColumnOptionDef {
name: None,
option: ColumnOption::Null
}]
},
ColumnDef {
name: "name".to_owned(),
data_type: DataType::Text,
options: vec![]
}
],
source: None
}
.to_sql()


Related PRs
- Implement to\_sql func for SetExpr, Join CEOJINSUNG (898)
- [AST] Implement to\_sql func for Query, SetExpr, Select, SelectItem, TableWithJoins, IndexItem, TableFactor, TableAlias CEOJINSUNG (860)
- [AST] To\_sql for CREATE TABLE, ALTER TABLE ding-young (807)
- [AST] to\_sql for Function ding-young (931)
- [AST] to\_sql for STATEMENTS ding-young (824)
- [AST] Implement to\_sql for INSERT, UPDATE, DELETE ding-young (821)

🌳 New datatype and functions

New datatype - `UINT8`
- [Data] add data type u8 zmrdltl (828)

New functions - `ASCII`, `CHR`, `POSITION`, `TO_DATE`, `TO_TIMESTAMP` and `FORMAT`
- Implement ASCII, Chr functions seonghun-dev (881)
- Implement function `POSITION` zmrdltl (862)
- Implement str\_position function under enum Value zmrdltl (875)
- [Function] Implement `TO_TIME` function and let `FORMAT` get `TIME` data type ChobobDev (842)
- [Function] Implement `TO_DATE` and `TO_TIMESTAMP` function ChobobDev (833)
- [Function] Implement `FORMAT` function ChobobDev (818)

πŸ“ˆ CLI enhancements
Support `.edit {fileName|None}` in CLI devgony (871)
1. Open temporary editor with last SQL

$> cargo run
gluesql> .run
[error] Nothing in SQL history to run.
gluesql> SELECT 1, 'a', true

| 1 | 'a' | true |
|---|-----|------|
| 1 | a | TRUE |

gluesql> .edit

=> open Editor with last command on temporary file like /tmp/Glue_****.sql

sql
-- modify in editor
SELECT 1, 'a', true, 2, 'b'

If you want to fix editor type, run below command on OS
sh
(optional)
$> export EDITOR=vi


gluesql> .run

| 1 | 'a' | true | 2 | 'b' |
|---|-----|------|---|-----|
| 1 | a | TRUE | 2 | b |

2. Open editor with physical file

gluesql> .edit foo.sql

sql
-- modify in editor
SELECT 1 AS no, 'In physical file' AS name


gluesql> .execute foo.sql

| no | name |
|----|------------------|
| 1 | In physical file |

New CLI print options

gluesql> .set tabular OFF
gluesql> .set colsep ,
gluesql> .set colwrap '
gluesql> .set heading OFF
gluesql> VALUES (1, 'a', true), (2, 'b', false)


'1','a','true'
'2','b','false'

- Support CLI options devgony (820)

Change default print style to markdown
Set markdown as default print style like below
sql
gluesql> SELECT * FROM (VALUES (1, 'a', true), (2, 'b', false)) AS Sub;

| column1 | column2 | column3 |
|---------|---------|---------|
| 1 | a | TRUE |
| 2 | b | FALSE |
(pasted from gluesql directly)
- Replace crate::`comfy-table` with `tabled` devgony (830)

πŸ’‘ Improvements

Aggregation
- Support `Expr::Case` in aggregate module ever0de (945)
- Update aggregate functions to support `Expr` zmrdltl (749)

`sqlparser-rs` upgrades
- Upgrade sqlparser-rs to v0.25 panarch (907)
- Upgrade sqlparser-rs to v0.24, migrate Interval from Literal to Expr panarch (904)
- Upgrade sqlparser-rs to v0.22 panarch (819)
- Migrate sqlparser-rs from 0.18 to 0.19, panarch (817)

Tests
- [FIx] add omitted uint8 integration test ChobobDev (951)
- Rename showcolumns to show\_columns sa1 (936)
- Replace plan/join.rs unit tests to use AST builder! panarch (929)
- Update test-suite select macros to support raw string literals for labels panarch (896)
- [Test Suite] add null test in function position zmrdltl (901)
- Update test-suite Tester trait to use Glue struct panarch (872)
- Add cli/ print and command modules to code coverage tests panarch (866)
- [Test suite] Add insert integration test kim-seo-hyun (826)
- [Test Suite] unify order of test arguments zmrdltl (816)
- [Test Suite] Change the structure of macros used \& the order of arguments zmrdltl (804)
- Enhance the coverage of `operator.rs` ChobobDev (783)
- [Test Suite] rearrange `error test cases` to `correct file` zmrdltl (794)
- [Test Suite] move `top level test files` to `new tester folder` zmrdltl (792)

Other improvements
- Move Expr::Extract structure to Expr::Function::Extract zmrdltl (930)
- Feat : Apply macros in i16 data type ChobobDev (940)
- Bump `uuid` version to `1.2.1` ever0de (943)
- Provide unsupported warning for select distinct sa1 (942)
- Use decl macro to simplify codes in parser\_sql module sa1 (937)
- Expose Row to Payload::Select and add Row to core::prelude panarch (941)
- Add firefox headless browser test to github action panarch (939)
- Remove Option which wraps Row in FilterContext, panarch (933)
- Add a new method to Row which finds value by ident, panarch (928)
- Add /pkg/rust/data/ to .gitignore panarch (927)
- Move Expr::Cast structure to Expr::Function::Cast zmrdltl (913)
- Grouping `GlueSQL` projects into `pkg/*` per language ever0de (917)
- Implement macro that implements `TryBinaryOperator`, ever0de (915)
- Implement Key::to\_be\_bytes for Decimal variant panarch (906)
- Add Send + Sync trait bounds to gluesql::Error::Storage variant panarch (903)
- Enable str to string clippy options ever0de (900)
- Use variable instead of closure in core/ evaluate function module ever0de (892)
- Remove comment ever0de (891)
- Update coverage.yml to ignore root examples panarch (887)
- Update README.md; add `await` keyword. 24seconds (889)
- Add root workspace in members ever0de (885)
- Auto Implement `GStore`, `GStoreMut` traits ever0de (884)
- refactor: remove redundant TableFactor::Series.name devgony (878)
- Remove unused comments in core/ ast/mod.rs panarch (877)
- Remove Result from core/ table::get\_alias return type panarch (876)
- refactor: Replace `ObjectName` with `String` devgony (873)
- [Style]remove unnecessary bracket ChobobDev (863)
- Remove deprecated wee\_alloc dependency use in gluesql-js/ panarch (856)
- [Docs] update README zmrdltl (852)
- [Data] modify uint8 to parse sql 'INT(8) UNSIGNED' format to 'UINT8' zmrdltl (851)
- [Data] modify int128 to parse sql int(128) format to int128 zmrdltl (850)
- [Data] remove data type int64 zmrdltl (849)
- [Data] modify int32 to parse sql int(32) format to int32 zmrdltl (848)
- [Data] modify int16 to parse sql int(16) format to int16 zmrdltl (847)
- [Data] modify int8 to parse sql int(8) format to int8 zmrdltl (846)
- Improvement `validate_unique` function when only `PrimaryKey` exists ever0de (832)
- Simplify root doc comment code example panarch (831)
- Small improvement: add clear guide for web example module 24seconds (797)
- Impl `TryFrom<&Value> for usize` devgony (795)


πŸ› Bug Fixes

- Fix test-suite tester::test to properly print expected \& found labels panarch (949)
- fix: unmatced subquery should return Null (not error) devgony (948)
- Fix COUNT aggregate to return 0 not 1 if no rows found ever0de (946)
- Fix web/ payload data\_type json serialization, panarch (938)
- Set default-run to root workspace Cargo.toml panarch (888)
- Update core/ chrono dependency version to 0.4.22, specify patch version panarch (840)

New Contributors
* sa1 made their first contribution in https://github.com/gluesql/gluesql/pull/936

**Full Changelog**: https://github.com/gluesql/gluesql/compare/v0.12.0...v0.13.0

0.12

pub trait Store { .. }
pub trait StoreMut where Self: Sized { .. }
pub trait Index { .. }
pub trait IndexMut where Self: Sized { .. }

Related PRs
- Remove generic T from Store, StoreMut and Index traits, panarch (589)
- Replace SledStorage generic key T from IVec to data::Key panarch (588)
- Replace MemoryStorage Key to core::data::Key, panarch (577)


2. **`Store::fetch_data` is newly added, `Store` trait now requires three methods to implement**
rust
pub trait Store {
async fn fetch_schema(&self, table_name: &str) -> Result<Option<Schema>>;
async fn fetch_data(&self, table_name: &str, key: &Key) -> Result<Option<Row>>;
async fn scan_data(&self, table_name: &str) -> Result<RowIter>;
}

Related PR
- Implement primary key support, panarch (687)


3. **`StoreMut` trait method renamings - `insert_data -> append_data` and `update_data -> insert_data`**
rust
pub trait StoreMut where Self: Sized {
...
async fn append_data(..) -> ..;
async fn insert_data(..) -> ..;
}

Related PR
- Rename StoreMut insert\_data \& update\_data methods, panarch (774)


🌐 PRIMARY KEY support
GlueSQL now supports PRIMARY KEY!
sql
CREATE TABLE Allegro (
id INTEGER PRIMARY KEY,
name TEXT,
);

more info - [test-suite/primary_key](https://github.com/gluesql/gluesql/blob/main/test-suite/src/primary_key.rs)

- Implement primary key support, panarch (687)
- Update `Expr::CompoundIdentifier` to have more accurate data format devgony (770)
- Update SledStorage key.rs to use IVec::from\_iter, not IVec::from panarch (765)
- Update SledStorage scan\_(indexed)\_data key not to contain table prefix, panarch (762)
- Update sled-storage::update\_data not to return error on not-existing … panarch (717)

βš“ New queries support
Select query without table & support `SERIES(N)`
sql
SELECT 1;
SELECT N FROM SERIES(10);

more info - [test-suite/series](https://github.com/gluesql/gluesql/blob/main/test-suite/src/series.rs)
- Support `SELECT * FROM Series(N)` and `SELECT 1`(without table) devgony (733)

`VALUES` support
sql
VALUES (1, 'a'), (2, 'b');
VALUES (1, 'a'), (2, 'b') LIMIT 1;
VALUES (1, 'a'), (2, 'b') LIMIT 1 OFFSET 1;
SELECT * FROM (VALUES (1, 'a'), (2, 'b')) AS Derived;
SELECT * FROM (VALUES (1, 'a'), (2, 'b')) AS Derived(id, name);
CREATE TABLE TableFromValues AS VALUES (1, 'a', True, Null, Null), (2, 'b', False, 3, Null)

more info - [test-suite/values](https://github.com/gluesql/gluesql/blob/main/test-suite/src/values.rs)
- Support `Derived VALUES` devgony (731)
- Support CTAV(Create Table As Values) devgony (704)
- Enhance `Values List` to validate column type devgony (659)
- Support `VALUES List` in `select` module devgony (648)

Inline view
sql
SELECT * FROM (SELECT COUNT(*) FROM InnerTable) AS InlineView

more info - [test-suite/inline_view](https://github.com/gluesql/gluesql/blob/main/test-suite/src/inline_view.rs)
- Support Inline view (FROM clause subquery) devgony (523)

πŸ’’ New storage - `SharedMemoryStorage`
Non-persistent storage engine which works in multi-threaded environment
- Implement shared memory storage ever0de (500)

🌟 [Alpha Phase] AST Builder
Now, SQL is not the only language supported by GlueSQL!
AST Builder generates GlueSQL AST directly from Rust codes.

e.g.
rust
let actual = table("Bar")
.select()
.filter(col("id").is_null())
.group_by("id, (a + name)")
.build();
let expected = "
SELECT * FROM Bar
WHERE id IS NULL
GROUP BY id, (a + name)
";

rust
let actual = table("Bar")
.select()
.group_by("city")
.project("city, COUNT(name) as num")
.build();
let expected = "
SELECT
city, COUNT(name) as num
FROM Bar
GROUP BY city
";

rust
let actual = table("Person")
.delete()
.filter(col("name").is_null())
.build();
let expected = "DELETE FROM Person WHERE name IS NULL";


more info - [core/ AST Builder](https://github.com/gluesql/gluesql/tree/main/core/src/ast_builder)

Related PRs
- Add in\_subquery test case using QueryNode CEOJINSUNG (781)
- Add QueryNode enum and test\_query function CEOJINSUNG (777)
- feat:[756] implement Ltrim and Rtrim function ChobobDev (763)
- [AST Builder] Implement substr Funciton seonghun-dev (758)
- [AST Builder] Implement Exp Funciton seonghun-dev (753)
- [AST Builder] Implement Lpad, Rpad Funciton seonghun-dev (752)
- Implement cast function in AST builder kim-seo-hyun (759)
- [AST Builder] Implement Concat Funciton seonghun-dev (750)
- [AST Builder] Implement radians, degrees Funciton seonghun-dev (755)
- [AST Builder] Implement Repeat Funciton seonghun-dev (742)
- [AST Builder] Implement GenerateUuid Funciton seonghun-dev (740)
- feat:[732] Implement `Gcd` and `Lcm` function to `ast_builder` ChobobDev (734)
- feat:[728] Implement `Log`function to `ast_builder` ChobobDev (729)
- feat:[725] Implement `Power` and `Sqrt` function to `ast_builder` ChobobDev (726)
- [AST Builder] Update FunctionNode structure zmrdltl (723)
- [AST Builder] Implement InSubquery and QueryNode CEOJINSUNG (721)
- [AST Builder] Implement Sign function kim-seo-hyun (711)
- [AST Builder] Implement Transaction Statements ding-young (709)
- [AST Builder] Implement AST builder InList function CEOJINSUNG (697)
- [AST Builder] Implement Index Expr seonghun-dev (673)
- [AST Builder] Implement drop\_table Expr seonghun-dev (695)
- implement now function in ast builder kim-seo-hyun (692)
- [AST Builder] Implement show\_columns Expr seonghun-dev (689)
- Implement AST-builder between expression function CEOJINSUNG (672)
- feat(ast\_build): implement binary operations (modulo, like, ilike, not\_like, not\_ilike) bugoverdose (686)
- refactor(ast\_build): reorder binary\_op functions and tests bugoverdose (681)
- Implement `ln` in ast\_builder gimwonbae (680)
- Implement unary\_op (+, -, NOT, !) in ast\_builder ding-young (669)
- Implement AST-builder extract functions CEOJINSUNG (666)
- Implement round function in ast\_builder ding-young (657)
- [AST Builder] Implement Agggregate function `COUNT` zmrdltl (656)
- Add more expression support to project, panarch (655)
- Implement ast\_builder binary::gte\&lte\&or woojinnn (654)
- Enhance SelectNode::filter woojinnn (653)
- Implement AST-builder log2, log10 function CEOJINSUNG (650)
- implement ceil function jaeyoung0909 (645)
- feat(ast\_builder): Add Agggregate functions zmrdltl (635)
- Implement add reverse func in ast\_builder seonghun-dev (637)
- implement ast\_builder/expr/function/{Left, Right} woojinnn (626)
- Implements trigonometric functions in ast\_builder nyeong (627)
- feat(ast\_build): implement upper function ChobobDev (621)
- feat(ast\_build): implement ifnull function bugoverdose (620)
- Add floor func in ast\_builder yujong-lee (616)
- Implement query builder base (AST builder) panarch (613)

πŸš€ Features

CLI updates
- Support `.spool FilePath` command in CLI devgony (748)
- Support `.columns TABLE` command in CLI devgony (736)

New data types
- Add INT(16) data type yujong-lee (632)
- Add data type i32 bearney74 (608)
- Add BYTEA data type support panarch (586)
- Add i128 (int128) data type bearney74 (563)

New aggregate function - `STDEV` & `VARIANCE`
- Add `STDEV` aggregate funtion zmrdltl (684)
- Support `VARIANCE` aggregate function \& update aggregate test zmrdltl (598)
- [Data] Add function `sqrt` for enum `Value` zmrdltl (675)

New function - `IFNULL`
- Implement IFNull function bearney74 (569)

New statement - `SHOW INDEXES FROM {table}`
- Add Description column to "show index from table" output bearney74 (600)
- Show indexes from table... (resolves issue 520) bearney74 (551)

`ToSql`
- Implement `ToSql` trait which displays AST as SQL text format bearney74 (554)


πŸ’‘ Improvements
GitHub Action related
- Update rust.yml GitHub Action to handle sled\_transaction\_timeout\_\* te… panarch (772)
- Remove clippy warning in mac os 24seconds (715)
- Run github action job parallel 24seconds (699)
- Update coverage action to use grcov \& Coveralls panarch (647)
- Simplify github rust action - Run tests \& Run examples, panarch (594)

Test Suite refactoring
- [Test Suite] Merge use crates into one zmrdltl (788)
- [Test Suite] Refactor `basic` zmrdltl (785)
- [Test Suite] delete unneccesary keyword `vec!`, `iter()` zmrdltl (775)
- [Test Suite] Refactor `arithmetic` zmrdltl (773)
- [Test Suite] Refactor `aggregate` zmrdltl (771)

rust-toolchain & sqlparser-rs migration
- chore:[700] rust version update ChobobDev (724)
- upgrade to Sqlparser 0.18 bearney74 (612)
- upgrade to rust 1.61 bearney74 (564)
- Update rusttoolchain version to 1.60 and sqlparser-rs to 0.17 bearney74 (557)

Other improvements
- Add Update integration test seonghun-dev (738)
- Replace bool::then to bool::then\_some panarch (727)
- import only where you use `Duration` ever0de (722)
- Remove unnecessary `Box` ever0de (716)
- Add DROP TABLE multi object test case in integration test seonghun-dev (706)
- Mark flaky test using target\_os cfg 24seconds (702)
- Update aggregate structure zmrdltl (698)
- Convert `TryInto` traits into `TryFrom` nyeong (682)
- Add SharedMemoryStorage to the src documentation comment kim-seo-hyun (664)
- Add missing test case in `test-suite` workspace ever0de (649)
- Update data types in README.md arsenkhy (644)
- Remove unnecessary `Result` ever0de (622)
- Support `Deserialize` for `Payload` ever0de (607)
- Migrate cli/ clap-rs version to v3.2.2 panarch (606)
- Ambiguous column selection should be detected while joining MRGRAVITY817 (583)
- Fix primitive numeric types cast not to panic bearney74 (573)
- Specify importing modules explicitly in data/value/into.rs panarch (587)
- Use const `Dialect` in parse\_query ever0de (584)
- Fix PartialEq between f64 and other numeric types bearney74 (585)
- Update ast::DataType enum to use SCREAMING\_SNAKE\_CASE bearney74 (575)
- Use checked\_x functions for binary op between i8, i64 and decimal data types not to panic on overflow bearney74 (571)
- Replace the `to_string` macro with the `serialize_all` macro ever0de (565)
- Fix the link in `gluesql-js/README.md` Webpack example MRGRAVITY817 (559)
- Unify GroupKey, HashKey(join) and UniqueKey into a single data::Key s… panarch (553)
- Clean up gluesql-js/ build scripts, panarch (552)

πŸ› Bug Fixes

- Fix `CAST` into i32 or i64 from numeric literals bearney74 (611)
- Fix SledStorage export \& import multiple times bug, panarch (605)
- Fix gluesql-js build and tests panarch (591)
- Fix core translate with metadata feature only panarch (590)
- Fix `sled_multi_threaded` example code with threads of `INSERT` and `SELECT`, ever0de (580)
- Fix rust clippy gh action to check optional features panarch (578)
- Fix modulo binary op to handle zero divisor correctly bearney74 (576)
- Fix divide by zero error in data::Value bearney74 (572)
- Handle `DROP INDEX` invalid params ever0de (566)
- Fix Glue::execute to run multiple sql query string ming535 (562)

πŸ‘ New Contributors
* ming535 made their first contribution in https://github.com/gluesql/gluesql/pull/562
* yujong-lee made their first contribution in https://github.com/gluesql/gluesql/pull/616
* bugoverdose made their first contribution in https://github.com/gluesql/gluesql/pull/620
* woojinnn made their first contribution in https://github.com/gluesql/gluesql/pull/626
* ChobobDev made their first contribution in https://github.com/gluesql/gluesql/pull/621
* nyeong made their first contribution in https://github.com/gluesql/gluesql/pull/627
* seonghun-dev made their first contribution in https://github.com/gluesql/gluesql/pull/637
* arsenkhy made their first contribution in https://github.com/gluesql/gluesql/pull/644
* jaeyoung0909 made their first contribution in https://github.com/gluesql/gluesql/pull/645
* CEOJINSUNG made their first contribution in https://github.com/gluesql/gluesql/pull/650
* ding-young made their first contribution in https://github.com/gluesql/gluesql/pull/657
* kim-seo-hyun made their first contribution in https://github.com/gluesql/gluesql/pull/664
* gimwonbae made their first contribution in https://github.com/gluesql/gluesql/pull/680

**Full Changelog**: https://github.com/gluesql/gluesql/compare/v0.11.0...v0.12

0.12.0

🌊 Breaking Changes
⚑ Store trait changes
1. **Store traits no longer require generic `T`**
rust

0.11

pub trait Store<T: Debug> { .. }
pub trait StoreMut<T: Debug> where Self: Sized { .. }
pub trait Index<T: Debug> { .. }
pub trait IndexMut<T: Debug> where Self: Sized { .. }

Page 1 of 4

Β© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.