gwenn
87d81cd46b
Check sqlite3_reset result
...
https://sqlite.org/c3ref/reset.html
> Therefore, it is important that applications check the return code from sqlite3_reset(S) even if no prior call to sqlite3_step(S) indicated a problem.
2023-11-25 10:13:55 +01:00
gwenn
e2e47de863
Fix some clipy warnings
2023-09-03 10:54:36 +02:00
gwenn
dd05c992c2
Merge pull request #1267 from gwenn/clippy
...
[breaking change] Update edition from 2018 to 2021
2023-06-17 07:44:02 +02:00
Johnny Graettinger
7c1d5a1863
Add Statement.readonly() accessor
...
Remove cfg(extra_check) from RawStatement::readonly()
2023-03-23 18:55:19 +00:00
gwenn
ba07f41aac
Merge remote-tracking branch 'origin/master' into clippy
2023-03-12 15:49:58 +01:00
gwenn
7278e5fa91
Merge pull request #1250 from gwenn/deprecated
...
Remove deprecated API
2023-03-12 15:42:58 +01:00
gwenn
5f851fb90f
Add Statement::clear_bindings
2022-12-11 10:26:13 +01:00
gwenn
312bf41e90
Merge remote-tracking branch 'origin/master' into deprecated
2022-12-11 09:56:22 +01:00
gwenn
3aa9addaa3
[breaking change] Update edition from 2018 to 2021
...
And fix clippy warnings
2022-12-09 20:19:04 +01:00
gwenn
2e07650a02
Use ?NNN format instead of ?
...
https://sqlite.org/lang_expr.html#parameters
> But because it is easy to miscount the question marks, the use of this parameter format is discouraged. Programmers are encouraged to use one of the symbolic formats below or the ?NNN format above instead.
2022-11-27 09:38:06 +01:00
gwenn
784ef95bb6
Intoduce one_column for tests
2022-11-11 16:20:39 +01:00
gwenn
d79d4a175b
Remove deprecated API
2022-11-11 14:45:22 +01:00
gwenn
7dab08c4b2
Fix clippy warnings
2022-10-02 11:34:58 +02:00
gwenn
6766d6a6cd
Remove old_sqlite
feature
...
And associated bindgen_3.6.8.rs
2022-08-30 13:05:47 -07:00
gwenn
6e740d0611
Change default minimal SQLite API version
...
From 3.6.8 to 3.14.0.
Use `old_sqlite` feature to keep 3.6.8 (or 3.7.16) as the minimal version.
Use `modern_sqlite` for SQLite API > 3.14.0.
Also remove old 3.6.23 and 3.7.7 bindings.
2022-08-30 13:05:47 -07:00
heavenboy8
569b19c160
update code to fit the last rust version requirements
2022-08-17 08:28:12 +02:00
gwenn
d5110ced91
Fix clippy warnings
2022-07-31 07:00:37 +02:00
gwenn
618e9a1274
Clean code
...
Typos, deprecated code usages, ...
2022-05-29 13:33:51 +02:00
gwenn
8370970b0b
Keep track of SQL input
2022-04-21 15:14:08 +02:00
gwenn
cfcbb56fce
Merge remote-tracking branch 'origin/master' into error_offset
...
# Conflicts:
# src/statement.rs
2022-04-20 07:27:05 +02:00
Thom Chiovoloni
46def6d67e
Improve the docs for opening the connection a bit
2022-04-03 22:08:50 -07:00
Thom Chiovoloni
899784379b
Expose sqlite3_changes
(or sqlite3_changes64
if available)
2022-04-03 08:13:27 -07:00
gwenn
5e2c103a0c
Add some missing wrappers ( #1139 )
...
* Add some missing wrappers:
sqlite3_value_subtype
sqlite3_result_subtype
sqlite3_changes64
sqlite3_db_readonly
sqlite3_txn_state
sqlite3_stmt_isexplain
sqlite3_vtab_config
sqlite3_index_info.idxFlags
sqlite3_index_info.colUsed
sqlite3_index_info.idxStr
sqlite3_vtab_collation
* Mark series VTab as innocuous and csv as direct only
2022-03-17 19:58:02 +01:00
gwenn
69a40526d5
Introduce SqlInputError with offset
2022-03-13 17:31:07 +01:00
Thom Chiovoloni
2ec0b2e8fe
Implement Params
for tuples of ToSql up to size 16, and touch up docs
2022-03-10 13:07:06 -08:00
gwenn
65668a46e4
Add constants introduced by SQLite 3.38.0
...
SQLITE_STMTSTATUS_FILTER_MISS
SQLITE_STMTSTATUS_FILTER_HIT
SQLITE_INDEX_CONSTRAINT_LIMIT
SQLITE_INDEX_CONSTRAINT_OFFSET
2022-02-26 09:55:17 +01:00
gwenn
43591154b2
clippy:ptr_as_ptr
2022-01-05 19:50:25 +01:00
gwenn
30f8c8c502
Fix callbacks lifetime
2021-12-01 04:28:09 -08:00
gwenn
ce90b519bb
Fix clippy warnings
2021-10-01 20:09:48 +02:00
Toby Murray
8a88ba647c
'restricts' -> 'restrictions'
2021-09-23 06:49:58 -07:00
gwenn
dcaa67a617
Merge pull request #973 from gwenn/doc_cfg
...
Use #[doc(cfg)]
2021-06-30 18:07:54 +02:00
gwenn
5730b2f952
Fix clippy warnings
2021-06-25 18:57:25 -07:00
gwenn
0312937d6a
Use #[doc(cfg)]
...
Fix #835
2021-06-13 09:17:35 +02:00
gwenn
cd40cc330b
Rustfmt ( #956 )
2021-05-07 19:39:53 +02:00
Dirk Stolle
c33d6bfad3
fix several typos
2021-05-02 23:03:10 -07:00
Nick Hynes
b8b1138fcf
Add Statement::parameter_name
2021-04-26 01:16:10 -07:00
gwenn
c4b398f468
Doctest column name reference ( #918 )
...
* Doctest column name reference
* Document rusqlite assumption on column name reference
And move doctest as a test.
* Document when columns metadata should be extracted.
* Rustfmt doc (wrap_comments)
2021-04-03 11:03:50 +02:00
gwenn
e1eed94bef
Fix clippy warnings
...
Allow `unnecessary_wraps` for `check_update` and `check_no_tail`.
Remove `check_readonly` (`sqlite3-parser` may help).
2021-02-28 13:19:58 +01:00
Thom Chiovoloni
19b0772f3f
Make it clear bind_in is not public, and inline functions passing large arrays by value to avoid too much copying
2021-01-31 16:18:48 -08:00
gwenn
afcdc2b43a
Use most concise syntax for params
2021-01-19 21:16:08 +01:00
gwenn
6fae5d6641
Add/fix rustdoc links
2020-11-22 09:34:03 +01:00
kud1ing
7beba0c6eb
Document that optional()
requires import of rusqlite::OptionalExtension
...
Document that `optional()` requires import of `rusqlite::OptionalExtension`.
2020-11-20 18:09:47 -08:00
gwenn
0649df96ea
Fix non-autolinks warnings
2020-11-07 12:32:41 +01:00
gwenn
da94f8eba6
Make tests return Result
2020-11-05 22:14:00 +01:00
Thom Chiovoloni
65c38bf813
Add #[inline]
and #[cold]
in far more places
2020-11-04 07:59:23 -08:00
Thom Chiovoloni
22121772a2
Deprecate NO_PARAMS in favor of passing an empty array
2020-11-03 19:09:19 -08:00
Thom Chiovoloni
2461ebf62f
Update documentation
2020-11-03 19:09:19 -08:00
Thom Chiovoloni
032aea73b8
Overhaul query API, removing the need for the _named
variants of all functions, and rusqlite::NO_PARAMS
2020-11-03 19:09:19 -08:00
Tim
83c038107d
Fix order of parameters in InvalidParameterCount message
...
This prints a message like `Error: Wrong number of parameters passed to query. Got 7, needed 8`, but the numbers were the wrong way around - i.e. it should have printed `Got 8, needed 7` in this case.
2020-07-01 08:38:50 -07:00
gwenn
dd886578d2
Implement our own sqlite3_exec
...
Should fix issue related to unlock notify: #767
Caveat: many CString allocated.
2020-06-26 19:35:14 +02:00