πŸ““ SQLish: again

πŸ˜‡ pub: HXPM Public Issues  |   |  Print Markdown

In the beginning we had sqlish.go which was truly a horror and failed to implement anything useful of the sql standard.

Next we had sqlglot which was fantastic but, dear goodness it was slow.

$ SQLITE=false python scripts/sql.py "GROUP select type from __all__ group by type limit 1"
Created HASH in 1.811981201171875e-05


Executed query in 0.1616196632385254



wow! that’s… terrible!

Let’s replace it with sqlite in-memory:

$ SQLITE=true python scripts/sql.py "GROUP select type from __all__ group by type limit 1"

Created SQLITE3 DB in 0.006751537322998047

Executed query in 2.7418136596679688e-05


oh. yeah. that’s more like it. It takes far longer to create the database, but, it’s far, far, far faster to query which is worth a lot.


Metadata
Metadata
Key Value
ID PNMR-voc47HE2
URN urn:penemure:8ce5a610-c44a-4012-8557-be8738ec7136
Backend πŸ˜‡ pub: HXPM Public Issues
Ancestors
πŸ“… Created
πŸ“… Updated
Links

Children

Queryable fields

View in API
title<a href="/penemure/note/8ce5a610-c44a-4012-8557-be8738ec7136.html"><span class="title">πŸ““ SQLish: again</span></a>
parentsurn:penemure:71596cb9-e3f4-44b4-9b21-974fff7b5201
version2
created_unix1738337622.5951755
updated_unix1739191975.8052194
namespaceNone
typenote
id8ce5a610-c44a-4012-8557-be8738ec7136
urnurn:penemure:8ce5a610-c44a-4012-8557-be8738ec7136
url/penemure/note/8ce5a610-c44a-4012-8557-be8738ec7136.html
backendpub
created2025-01-31 15:33:42.595176+00:00
updated2025-02-10 12:52:55.805219+00:00
systemFalse
blurbIn the beginning we had [`sqlish.go`](https://github.com/hexylena/project-management/blob/2d1d57074513ce4f81d0cc714c209b
title_plainπŸ““ SQLish: again
title_txtSQLish: again
final_ancestor_titlesPenemure Development Blog
parent_first_titlePenemure Development Blog
ancestorsurn:penemure:71596cb9-e3f4-44b4-9b21-974fff7b5201