chrislu
d60c542ecc
feat: Replace pg_query_go with lightweight SQL parser (no CGO required)
- Remove github.com/pganalyze/pg_query_go/v6 dependency to avoid CGO requirement
- Implement lightweight SQL parser for basic SELECT, SHOW, and DDL statements
- Fix operator precedence in WHERE clause parsing (handle AND/OR before comparisons)
- Support INTEGER, FLOAT, and STRING literals in WHERE conditions
- All SQL engine tests passing with new parser
- PostgreSQL integration tests can now build without CGO
The lightweight parser handles the essential SQL features needed for the
SeaweedFS query engine while maintaining compatibility and avoiding CGO
dependencies that caused Docker build issues.
2 months ago
chrislu
4d9de40c5c
fmt
2 months ago
chrislu
42661ac110
fix tests
2 months ago
chrislu
991247facf
fix tests
2 months ago
chrislu
e3e369c264
change to pg_query_go
2 months ago
chrislu
ba4a8b91d5
fmt
2 months ago
chrislu
59d6806146
fix empty spaces and coercion
2 months ago
chrislu
3fa7670557
fix todo
2 months ago
chrislu
687c5d6bfd
fix tests
2 months ago
chrislu
e14a316aeb
use schema instead of inferred result types
2 months ago
chrislu
a7eb178cec
Update engine.go
2 months ago
chrislu
60066a6a4c
read broker, logs, and parquet files
2 months ago
chrislu
d29f54e0be
de-support alter table and drop table
2 months ago
chrislu
8e15fdf2c7
remove sample data
2 months ago
chrislu
f776a49322
avoid sample data
2 months ago
chrislu
ed7102df6e
column name can be on left or right in where conditions
2 months ago
chrislu
e901abffd3
address comments
2 months ago
chrislu
586a795b02
return fast on error
2 months ago
chrislu
c9e093194d
setup integration test for postgres
2 months ago
chrislu
6fb88a8edb
buffer start stored as 8 bytes
2 months ago
chrislu
61bacd23b0
parquet file can query messages in broker memory, if log files do not exist
2 months ago
chrislu
618cb89885
the parquet file should also remember the first buffer_start attribute from the sources
2 months ago
chrislu
db75742e37
explain with broker buffer
2 months ago
chrislu
de866bfd09
dedup with buffer start index
2 months ago
chrislu
e3a56d7c30
filter out already flushed messages
2 months ago
chrislu
467034c8c7
process buffer from brokers
2 months ago
chrislu
7ca3b59c44
save source buffer index start for log files
2 months ago
chrislu
f5ed25f755
fix decoding data
2 months ago
chrislu
99bfe95e51
detailed logs during explain. Fix bugs on reading live logs.
2 months ago
chrislu
c7a0b89067
fix after refactoring
2 months ago
chrislu
e385f0ce7d
refactor
2 months ago
chrislu
61ad3c39ac
add tests
2 months ago
chrislu
4214d765cf
use mock for testing
2 months ago
chrislu
a3f6a5da27
skip
2 months ago
chrislu
dfd0897e49
improve tests
2 months ago
chrislu
7d88a81482
add tests
2 months ago
chrislu
eaa7136c92
explain the execution plan
2 months ago
chrislu
93a09f5da4
explain
2 months ago
chrislu
55cad6dc4a
combine parquet results with live logs
2 months ago
chrislu
e3798c2ec9
sql
2 months ago
chrislu
55dfb97fc8
parquet file generation remember the sources also
2 months ago
chrislu
2fa8991a52
scan all files
2 months ago
chrislu
c7598d89f1
remove emoji
2 months ago
chrislu
c73ceac79f
use parquet statistics for optimization
2 months ago
chrislu
471ba271dc
fix reading system fields
2 months ago
chrislu
8498240460
fmt
2 months ago
chrislu
8645f3a264
column name case insensitive, better auto column names
2 months ago
chrislu
32e73811f2
support aggregation functions
2 months ago
chrislu
cf9ad26608
scan topic messages
2 months ago
chrislu
ac8e6c8c82
actual column types
2 months ago