sqlschm
hasql-th
sqlschm | hasql-th | |
---|---|---|
2 | 4 | |
5 | 110 | |
- | - | |
2.4 | 5.2 | |
about 1 year ago | 5 months ago | |
Python | Haskell | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
sqlschm
-
Writing a Python SQL engine from scratch
> The main reason why I ended up building a SQL engine was...just for entertainment. It's been fun learning about all the things
I also wrote an SQL parser [1] for SQLite schema. This was mainly for fun, but also to support the specificities of SQLite schema. I was not happy with the result of other parsers (including sqlglot).
[1] https://github.com/coast-team/sqlschm
-
Open Source SQL Parsers
SQL is a mess. It is difficult to find a parser that fulfills your needs.
A month ago, I needed a parser to parse SQLite schemas. SQLite has some edge case and I needed a lossless parsing to detect these edge cases.
I finally wrote my own parser [1] to fullfill my needs and to have some fun. This is for a POC project.
[1] https://github.com/coast-team/sqlschm
hasql-th
-
How to use PostgreSQL with Haskell: hasql
Hasql is an ecosystem of libraries. To keep it simple, let’s limit ourselves to core hasql, hasql-transaction, and hasql-th. We’re using hasql 1.6.3.2 published in 2023.
-
Parsing SQL
unexpected '&'
https://github.com/nikita-volkov/hasql-th#error-example-1
-
Open Source SQL Parsers
There is also a Haskell port of the original PostgreSQL parser, implemented using megaparsec, which makes it highly flexible and hackable: https://github.com/nikita-volkov/hasql-th#implementation
-
Haskell doesn't make sense without pure functions
I'd consider hasql-th a good example in what concerns databases. Otherwise, I just use aeson together with deriving-aeson and lens-aeson.
What are some alternatives?
duckdb - DuckDB is an in-process SQL OLAP Database Management System
Neks - A dead simple networked key/value store
pgsqlite - Load sqlite databases into Postgres databases
tokyocabinet-haskell - This repository will get archived soon. Please visit https://git.singpolyma.net/tokyocabinet-haskell
tree-sitter-sql - SQL syntax highlighting for tree-sitter
hasql - The fastest PostgreSQL libpq-based driver for Haskell
lezer-snowsql
wai-middleware-cache-redis - Redis backend for wai-middleware-cache
ampersand - Build database applications faster than anyone else, and keep your data pollution free as a bonus.
hasql-notifications - Use PostgreSQL LISTEN/NOTIFY with your Hasql Types
hasql-transaction - A composable abstraction over retriable transactions for Hasql
hasql-cursor-query - A declarative abstraction over PostgreSQL Cursor