lacak
ef00cefa0a
fcl-db: cleanup (remove unused parts of code)
...
git-svn-id: trunk@31146 -
2015-06-23 10:27:36 +00:00
lacak
5e8d1078a7
fcl-db: sqlite: bind boolean parameters according to SQLite expectation:
...
"Boolean values are stored as integers 0 (false) and 1 (true)."
Until now True was stored as -1 instead of 1. (Reading is correct as "True" is "<>0").
This is potentialy breaking change, DO NOT BACKPORT IT!
git-svn-id: trunk@31086 -
2015-06-17 12:24:58 +00:00
lacak
8214e72841
fcl-db: memds: implemented basic blob support. Blobs are allocated in memory only. Saving to stream/file is not supported yet. Bug #26476
...
git-svn-id: trunk@31027 -
2015-06-12 07:28:50 +00:00
lacak
b641ffa0e0
fcl-db: base: declare procedure DatabaseErrorFmt with parameter Args as Const Args: array of const. Fixes memleak in 2.6 and also makes procedure signature Delphi compatible.
...
git-svn-id: trunk@31024 -
2015-06-11 11:53:44 +00:00
michael
526f91b28f
* Patch from bug #28125 by Silvio Clecio
...
git-svn-id: trunk@31021 -
2015-06-10 21:29:09 +00:00
lacak
9f4333d20a
fcl-db: tests: Add sqlite3ds connector to db test suite. Patch from Luiz Americo. Bug #28200
...
git-svn-id: trunk@30935 -
2015-05-29 10:21:22 +00:00
blikblum
a27cee5cfb
* Make GetRecNo return 0 on empty and closed datasets
...
git-svn-id: trunk@30929 -
2015-05-28 14:53:56 +00:00
blikblum
e8175ed0cf
* Revert undesired changes introduced in last commit
...
git-svn-id: trunk@30928 -
2015-05-28 14:29:35 +00:00
blikblum
2fff34b7b7
* Check for nil in BookmarkValid
...
git-svn-id: trunk@30927 -
2015-05-28 13:17:03 +00:00
blikblum
f1db1db8b9
* Move cursor forward instead of backward when deleting
...
git-svn-id: trunk@30926 -
2015-05-28 12:22:40 +00:00
lacak
242d750ef5
fcl-db: sqldb: ExecuteDirect should call StartImplicitTransaction, when Transaction.Options contains stoUseImplicit (else it leads later to AV due to nil Transaction.Handle)
...
git-svn-id: trunk@30920 -
2015-05-27 05:06:01 +00:00
Jonas Maebe
89418d23e5
* regenerated Makefiles with Linux/AArch64 support
...
git-svn-id: trunk@30891 -
2015-05-20 20:15:10 +00:00
blikblum
8e9b246042
* Properly set detail sql when master key is null. Issue #11423
...
git-svn-id: trunk@30888 -
2015-05-20 02:15:43 +00:00
blikblum
6542cfe0ad
* Don't fetch all records in detail dataset when master dataset is empty
...
git-svn-id: trunk@30887 -
2015-05-20 01:56:35 +00:00
lacak
5b3b1c7dea
fcl-db: sqlite: implement CreateDB/DropDB methods + InitializeSqlite/ReleaseSqlite
...
git-svn-id: trunk@30885 -
2015-05-19 11:29:52 +00:00
lacak
126f94ba41
fcl-db: sqlite: implement CreateDB/DropDB methods
...
git-svn-id: trunk@30884 -
2015-05-19 11:16:39 +00:00
lacak
ab93b0bbe6
fcl-db: sdfdataset: attempt to fix "misaligned data access" error on WinCE / ARM platform. Bug #17871
...
git-svn-id: trunk@30883 -
2015-05-19 08:26:32 +00:00
lacak
8215c485f2
fcl-db: sdfdataset: improved handling of space padded values according to RFC4180:"Spaces are considered part of a field and should not be ignored".
...
Now fields in internal record buffer are always null terminated (also for TFixedFormatDataset) + tests
git-svn-id: trunk@30882 -
2015-05-19 07:29:27 +00:00
lacak
5c9d5cf896
fcl-db: base: TBlobField.GetAsString returns uninitialized Result for blob Size=0. Bug #28113
...
git-svn-id: trunk@30881 -
2015-05-18 06:39:32 +00:00
lacak
d5570fb4c4
fcl-db: base: fix TBlobField.SetBlobType. Bug #28103
...
git-svn-id: trunk@30880 -
2015-05-18 06:04:13 +00:00
marco
f8fda7ed65
* typo fix, patch by Silvio Cl'ecio mantis #28107
...
git-svn-id: trunk@30869 -
2015-05-16 16:43:04 +00:00
lacak
b60bbf26e1
fcl-db: tests: add tests for TFixedFormatDataset
...
git-svn-id: trunk@30845 -
2015-05-14 08:47:28 +00:00
blikblum
49a52457dd
* Fix access violation in Delete when state = dsEdit
...
git-svn-id: trunk@30839 -
2015-05-09 19:59:56 +00:00
lacak
b83ff7dd27
fcl-db: oracle: fix transaction parameters handling (only one of OCI_TRANS_READONLY, OCI_TRANS_READWRITE, OCI_TRANS_SERIALIZABLE should be used). Bug #28043
...
git-svn-id: trunk@30815 -
2015-05-07 05:44:22 +00:00
lacak
31c1581b9f
fcl-db: oracle: fix transaction parameters handling (only one of OCI_TRANS_READONLY, OCI_TRANS_READWRITE, OCI_TRANS_SERIALIZABLE should be used). Bug #28043
...
git-svn-id: trunk@30814 -
2015-05-07 05:38:12 +00:00
lacak
d0b365c99a
fcl-db: sqldb: fix trailing quote char
...
git-svn-id: trunk@30807 -
2015-05-06 07:13:04 +00:00
lacak
692398e195
fcl-db: interbase: better detection if stored procedure is selectable i.e. returns resultset (or output parameters)
...
git-svn-id: trunk@30804 -
2015-05-05 08:57:59 +00:00
lacak
8b41206ffd
fcl-db: sqldb:
...
- if there is already opened FUpdateQry, which is used for refreshing field values, we must first close it and later open again to get new values.
- if there is automatically generated UpdateSQL, then we must always call ConstructUpdateSQL to correctly get ReturningClause
(probably there is better way how to handle SQL statements with returning clause)
git-svn-id: trunk@30798 -
2015-05-04 12:43:16 +00:00
lacak
35f6cbfbae
fcl-db: tests: improve test for RefreshOnUpdate using returning clause.
...
When more than one record is updated then only fields in first record are correctly refreshed. Related to rev.30796 (which closes one bug, but opens other)
git-svn-id: trunk@30797 -
2015-05-04 12:01:26 +00:00
lacak
5017d1e6eb
fcl-db: sqldb:
...
- if there is explicitly supplied RefreshSQL do not try generate returning clause.
- if there is explicitly supplied InsertSQL, UpdateSQL set ReturningClause to False as it can lead to "can not open non-select statement"
git-svn-id: trunk@30796 -
2015-05-04 08:37:44 +00:00
lacak
93802cf5ee
fcl-db: tests: Follow rev.30691 (Renamed sqoPreferRefresh to sqoRefreshUsingSelect) Bug #28017
...
git-svn-id: trunk@30795 -
2015-05-04 08:15:39 +00:00
blikblum
9e0b281bf1
* Did not reset FCurrentItem in GetRecord when called with gmPrior. Fixes calling Resync with rmExact
...
git-svn-id: trunk@30771 -
2015-05-03 01:37:34 +00:00
blikblum
7468b0b7f7
Use sqlite3_prepare_v2 instead of sqlite3_prepare. Fixes a bug when creating two tables and trying to call TableExists
...
git-svn-id: trunk@30741 -
2015-04-28 02:11:23 +00:00
blikblum
379c20808f
Fix return of CreateTable use SQLITE_DONE instead of SQLITE_OK
...
git-svn-id: trunk@30740 -
2015-04-28 01:59:55 +00:00
lacak
d5c1d511b8
fcl-db: memds: for dsOldValue, dsNewValue dataset states return ActiveBuffer
...
git-svn-id: trunk@30737 -
2015-04-27 11:00:51 +00:00
lacak
8839850650
fcl-db: sdfdataset: add support for dsBlockRead state
...
git-svn-id: trunk@30736 -
2015-04-27 10:28:45 +00:00
lacak
c3e542c7ef
fcl-db: base: allow TField.Clear also for calculated (and lookup) fields. Bug #25174
...
git-svn-id: trunk@30703 -
2015-04-22 12:40:10 +00:00
lacak
1b9e1eb1d8
fcl-db: base: increase default Precision for TBCDField and TFmtBCDField from 15 to 18. 15 was probably copy-paste from TFloatField. TBCDField uses currency data type as native storage type, so use MaxBCDPrecision = 18 is appropriate.
...
(Note: Delphi sets default Precision,Size for TBCDField:0,4 and for TFMTBCDField:0,8)
git-svn-id: trunk@30702 -
2015-04-22 11:41:52 +00:00
michael
78dda3e217
* Renamed sqoPreferRefresh to sqoRefreshUsingSelect
...
git-svn-id: trunk@30691 -
2015-04-21 11:11:55 +00:00
lacak
2eb2791ce9
fcl-db: base: TBCDField.GetDefaultWidth should return Precision+1 (Delphi compatible) insted of only Precision (+1 is for sign and/or decimal separator).
...
Note: TBCDField in constructor sets FPrecision=15, which is IMHO copied from TFloatField. In case of TBCDField it should be probably 18 - MaxBCDPrecision
git-svn-id: trunk@30684 -
2015-04-20 12:52:07 +00:00
michael
1211149a29
* Call Translate for blobfields as well (bug ID 25083)
...
git-svn-id: trunk@30640 -
2015-04-18 06:36:00 +00:00
michael
3e100245e0
* Globally take into account forcedclose when committing/rollbacking, so all operations succeed
...
git-svn-id: trunk@30627 -
2015-04-17 19:26:36 +00:00
lacak
98c059f3ec
fcl-db: base: set storage specifiers - default 0 - for TFieldDef.Precision and TFieldDef.Size.
...
(TFieldDef.Precision is initialised to -1 which differs from Delphi where it is 0)
git-svn-id: trunk@30610 -
2015-04-16 11:37:28 +00:00
michael
10633da13b
* Reverted revision 30575 (forgor -depth=immediate
...
git-svn-id: trunk@30576 -
2015-04-13 19:44:51 +00:00
michael
2cab4a9a73
* Reverted revision 30557
...
git-svn-id: trunk@30575 -
2015-04-13 19:43:43 +00:00
michael
1c067b755c
* Fix memory leak reported by Graeme Geldenhuys
...
git-svn-id: trunk@30571 -
2015-04-13 10:21:46 +00:00
michael
0d1fc7fa97
* Add some context messages to tests
...
git-svn-id: trunk@30570 -
2015-04-13 08:29:36 +00:00
lacak
57965a2194
fcl-db: sdfdataset: cosmetic
...
git-svn-id: trunk@30569 -
2015-04-13 08:28:29 +00:00
lacak
c8740c6e3f
fcl-db: sdfdataset: improve tests
...
git-svn-id: trunk@30568 -
2015-04-13 08:15:59 +00:00
lacak
1a5126081f
fcl-db: sdfdataset: simplify tests, add comments
...
git-svn-id: trunk@30567 -
2015-04-13 08:05:47 +00:00