233 Commits

Author SHA1 Message Date
Scott Fries 7e5e6d11bf #124 Adding support for invalidating cache objects (#125)
Co-authored-by: Scott Fries <Scott@ScottFries.com>
2026-03-11 01:02:00 +08:00
Marco Craveiro 5768fb9aa2 Add parameterized execute for postgres (#122)
Support variadic execute with $1, $2, ... placeholders for safe parameter
binding. This allows calling PostgreSQL functions without defining custom
types.

Example:
  conn->execute("SELECT my_func($1, $2)", arg1, arg2);

Supported types: string, numeric, bool, optional, nullptr/nullopt for NULL.
2026-02-08 08:57:01 +08:00
Marco Craveiro a414397705 Use environment variables for postgres and MySQL test credentials (#121) 2026-02-07 08:36:57 +08:00
Marco Craveiro 2b877f24d8 Add PostgreSQL notice processor support (#120)
Allow users to capture RAISE NOTICE messages by providing a callback
via Credentials. The handler is stored in PostgresV2Connection with
stable lifetime management using shared_ptr.

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-03 17:28:27 +08:00
Dr. Patrick Urbanke (劉自成) a866fe476d Added proper documentation for sqlgen::insert_or_replace; resolves #116 (#117) 2026-01-24 17:20:14 +01:00
Dr. Patrick Urbanke (劉自成) 0db1670c01 Documented support for multiple primary keys; resolves #107 (#115) 2026-01-01 12:51:58 +01:00
Dr. Patrick Urbanke (劉自成) 587cff4201 Bump sqlgen version to 0.6.0 (#114) v0.6.0 2026-01-01 12:38:24 +01:00
Dr. Patrick Urbanke (劉自成) a558c7bb23 Use unique cursor names in postgres (#113) 2025-12-31 00:56:19 +01:00
Dr. Patrick Urbanke (劉自成) 9d0f0a29ab Use monadic error handling in postgres (#112) 2025-12-31 00:56:04 +01:00
Dr. Patrick Urbanke (劉自成) c8f4ad8d84 Better support for nullable values in UPDATE...SET, resolves #108 (#111) 2025-12-26 12:51:23 +01:00
Marco Craveiro 0ea4d461d4 Implement listen / notify support for Postgres (#104) (#105) 2025-12-18 00:12:07 +01:00
Dr. Patrick Urbanke (劉自成) ba39bb2730 Replace enable_if with concepts (#106) 2025-12-08 00:13:11 +01:00
Dr. Patrick Urbanke (劉自成) 758bb1d87e Expand the is_connection concept to iterators (#103) 2025-12-06 23:20:11 +01:00
Marco Craveiro 657a9fd4ee Implement offset support (#102)
As per discussions in [1].

[1] https://github.com/getml/sqlgen/issues/100
2025-12-03 22:55:59 +01:00
Dr. Patrick Urbanke (劉自成) cd42a4e4cf Make sure that iterators work with sessions; fixes #99 (#101) 2025-11-29 19:33:09 +01:00
Dr. Patrick Urbanke (劉自成) 8b658d6137 Bump sqlgen version to 0.5.0 (#98) v0.5.0 2025-11-25 20:09:04 +01:00
Dr. Patrick Urbanke (劉自成) e85f262f6d Minor code beautifications for DuckDB (#94) 2025-11-25 20:08:05 +01:00
Dr. Patrick Urbanke (劉自成) b2e4cba591 Fix select_from usage in unite.md example (#97) 2025-11-23 23:57:15 +01:00
Dr. Patrick Urbanke (劉自成) 287ac58bf6 Added support for UNION and UNION ALL (#96) 2025-11-23 23:55:42 +01:00
Dr. Patrick Urbanke (劉自成) 7e4fa42bd9 Use RAII principles for postgres (#93) 2025-11-21 20:38:56 +01:00
Dr. Patrick Urbanke (劉自成) 8568a83362 Added support for DuckDB (#90) 2025-11-20 21:20:12 +01:00
Marco Craveiro e07be25a5d Fix memory management for postgres in edge cases (#89) 2025-11-14 12:34:22 +01:00
Dr. Patrick Urbanke (劉自成) 5131953c35 Generate .lib files when building shared on Windows; Bumped to version 0.4.0 (#86) v0.4.0 2025-11-03 01:02:00 +01:00
Dr. Patrick Urbanke (劉自成) 86884f388a Use reflect-cpp 0.22.0 (#85) 2025-11-02 00:46:55 +01:00
Dr. Patrick Urbanke (劉自成) c4305f6a17 Added checks to make sure that the headers are self-contained (#84) 2025-11-01 19:47:19 +01:00
Dr. Patrick Urbanke (劉自成) 86ee6e2bcc Added a caching strategy (#83) 2025-11-01 14:30:58 +01:00
Dr. Patrick Urbanke (劉自成) 4cc3e871c3 Explicitly set alias; fixes #80 (#82) 2025-10-30 21:49:03 +01:00
Dr. Patrick Urbanke (劉自成) e4cf6c802b Use sqlite_prepare_v3; resolved #77; fixes #78 (#81) 2025-10-27 23:17:23 +01:00
Dr. Patrick Urbanke (劉自成) e6b468af9b Added tests for schemata (#76) 2025-10-24 08:14:34 +02:00
Dr. Patrick Urbanke (劉自成) 91e993ffdd Make sure we can use boolean values in conditions; fixes #74 (#75) 2025-10-23 23:30:58 +02:00
Marco Craveiro 15108fba46 Handle schemas in SQL generation; resolves #70 (#71)
Add schema handling in SQL generation for tables.
2025-10-23 19:30:40 +02:00
Dr. Patrick Urbanke (劉自成) 816ca6adec Fixed issue with boolean data; resolves #69 (#72) 2025-10-22 23:15:47 +02:00
Dr. Patrick Urbanke (劉自成) 6c0af08321 Made sure that you can still insert after a failure; resolves #68 (#73) 2025-10-22 22:06:09 +02:00
Dr. Patrick Urbanke (劉自成) 3076ea2c8c Make sure that special value types can be added to conditions; resolves #63 (#67) 2025-10-19 21:38:09 +02:00
Dr. Patrick Urbanke (劉自成) 1bfc4e472b Make sure that adding tags to columns only compiles when the corresponding tables exist in the query; resolves #59 2025-10-19 18:48:17 +02:00
Dr. Patrick Urbanke (劉自成) 3736fcc29c Better implementation for value_t; fixes #64 (#65) 2025-10-14 23:11:08 +02:00
Dr. Patrick Urbanke (劉自成) 9c67ff24e4 Refactored the write and read function (#61) 2025-10-10 01:22:15 +02:00
Dr. Patrick Urbanke (劉自成) 3769f50501 Refactor iterators to make sure we can use them for DuckDB (#60) 2025-10-07 23:51:15 +02:00
Dr. Patrick Urbanke (劉自成) 4e98b9c0aa Removed CMakeUserPresets.json; Bumped version to 0.3.0 (#58) v0.3.0 2025-10-05 10:52:15 +03:00
Dr. Patrick Urbanke (劉自成) 4713e88fe7 Fix documentation related to views and SQLite (#57) 2025-10-03 23:15:53 +03:00
Dr. Patrick Urbanke (劉自成) ce302f54de Made sure that nullability rules are applied properly when joining tables (#56) 2025-10-03 22:54:46 +03:00
Dr. Patrick Urbanke (劉自成) 45c1a52177 Added support for IN and NOT IN; resolves #53 (#54) 2025-09-28 22:28:48 +03:00
Dr. Patrick Urbanke (劉自成) 8649e41861 Fixed typo in select_from (#51) 2025-09-21 12:00:48 +03:00
hosein 7a617b0828 Add enum support (#49) 2025-09-21 10:00:15 +03:00
Dr. Patrick Urbanke (劉自成) 26869c83f1 Added support for JSON fields (#48) 2025-09-13 08:29:26 +02:00
Demian Nave 8b6b6c5a59 Implement insert_or_replace (#45)
Co-authored-by: Dr. Patrick Urbanke <patrick@getml.com>
2025-09-07 11:14:02 +02:00
Dr. Patrick Urbanke (劉自成) 82e1c193d3 Minor improvements to dynamic types (#44) 2025-08-21 22:32:11 +02:00
hosein 5c8cf00625 Add a generic Dynamic type for db-specific columns (#43) 2025-08-21 20:08:32 +02:00
Dr. Patrick Urbanke (劉自成) b46c3fe03d Added support for CREATE TABLE AS and CREATE VIEW AS (thus adding support for views) (#40) 2025-08-10 14:37:22 +02:00
Dr. Patrick Urbanke (劉自成) f536efbde9 Added the ability to add subqueries in select_from (#39) 2025-08-09 00:36:53 +02:00