Crates.io | sqlfuzz |
lib.rs | sqlfuzz |
version | 0.3.0 |
source | src |
created_at | 2022-07-09 20:33:18.93262 |
updated_at | 2022-07-10 19:37:32.69507 |
description | Generate random (and sometimes valid!) queries from any local Parquet, CSV, JSON, or Avro data set. |
homepage | https://github.com/andygrove/sqlfuzz |
repository | https://github.com/andygrove/sqlfuzz |
max_upload_size | |
id | 622749 |
size | 92,523 |
Generate random (and sometimes valid!) SQL queries from any local datasets in Parquet, CSV, JSON, or Avro format.
cargo install sqlfuzz
sqlfuzz query \
--table ./testdata/test0.parquet ./testdata/test1.parquet \
--join-type inner left right full semi anti \
--count 5 \
--max-depth 5
SELECT __c320, __c321, __c322, __c323
FROM (
(SELECT test1.c0 AS __c320, test1.c1 AS __c321, test1.c2 AS __c322, test1.c3 AS __c323
FROM (test1))
INNER JOIN
(SELECT test1.c0 AS __c324, test1.c1 AS __c325, test1.c2 AS __c326, test1.c3 AS __c327
FROM (test1))
ON __c320 = __c327)
WHERE __c323 > __c320;
If you don't already have suitable data, you can generate random data files to run the query fuzzer against.
sqlfuzz data --path ./testdata --num-files 4 --row-count 20