Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/build-distributions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ jobs:
fi
converted="$(echo "SELECT 1 AS total" | "${bin}/sqlquack" convert --no-config)"
echo "${converted}"
grep -qx 'SELECT CAST(1 AS DECIMAL(1,0)) AS "TOTAL"' <<< "${converted}"
grep -qx 'SELECT CAST(1 AS DECIMAL(1, 0)) AS "TOTAL"' <<< "${converted}"
# A file converted in a project folder, with no sqlquack.toml in it: the built-in policy.
mkdir readme-smoke && cd readme-smoke
printf "SELECT customer_id, SUM(total) AS revenue\nFROM orders\nGROUP BY customer_id\n" > query.sql
Expand All @@ -333,7 +333,7 @@ jobs:
"${bin}/sqlquack" check query.sql
converted="$("${bin}/sqlquack" convert query.sql)"
echo "${converted}"
grep -q 'CAST(sum("ORDERS"."TOTAL") AS DECIMAL(24,2)) AS "REVENUE"' <<< "${converted}"
grep -q 'CAST(sum("ORDERS"."TOTAL") AS DECIMAL(24, 2)) AS "REVENUE"' <<< "${converted}"
# run executes the conversion on the bundled DuckDB, over inline rows and over a CSV file.
"${bin}/sqlquack" run query.sql --fixture 'orders=[[1, 2.5], [1, 4]]' --expect '[[1, 6.5]]'
printf 'customer_id,total\n2,1.25\n' > orders.csv
Expand All @@ -343,7 +343,7 @@ jobs:
# The README's Python example.
"${python[@]}" -c 'import sqlquack
result = sqlquack.convert(sql="SELECT 1 AS total", options=sqlquack.ConvertOptions(no_config=True))
assert result.sql == "SELECT CAST(1 AS DECIMAL(1,0)) AS \"TOTAL\"", result.sql'
assert result.sql == "SELECT CAST(1 AS DECIMAL(1, 0)) AS \"TOTAL\"", result.sql'
- uses: actions/upload-artifact@v4
if: inputs.upload
with:
Expand Down
2 changes: 2 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions crates/sqlquack-blocks/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ extensions = ["bundled", "duckdb/parquet"]
duckdb = { workspace = true, optional = true }
serde_json.workspace = true
sqlquack-diagnostics.workspace = true
sqlquack-format.workspace = true
sqlquack-semantics = { workspace = true, features = ["snowflake"] }

[dev-dependencies]
Expand Down
259 changes: 0 additions & 259 deletions crates/sqlquack-blocks/src/layout/_helpers/breaks.rs

This file was deleted.

5 changes: 0 additions & 5 deletions crates/sqlquack-blocks/src/layout/_helpers/mod.rs

This file was deleted.

Loading
Loading