profile picture

1 pages tagged with "crystal"

Setting SQLite3 PRAGMA's automatically with crystal-sqlite3

January 14, 2023 - 641 words - 4 mins
For a project in Crystal using SQLite3 (crystal-sqlite3), I wanted to automate setting PRAGMAs on the database connection without having to leverage on DB#setup_connection and hardcoding values in my code. So, instead of doing this: require "sqlite3" "sqlite3:file.db" do… read more