michael
b9eb560dde
* Some cosmetic changes, added SQLConnection/SQLTransaction to avoid typecasts everywhere
...
git-svn-id: trunk@26767 -
2014-02-14 12:58:00 +00:00
lacak
9c2ffc30ee
fcl-db:
...
- introduce ESQLDatabaseError (with fields: ErrorCode and SQLState) as direct descendant of EDatabaseError and an ancestor for all SQLConnection specific exceptions (like EPQDatabaseError, EIBDatabaseError, EODBCException, etc.)
- add overriden method PSGetUpdateException to create EUpdateException with ErrorCode taken from this new ESQLDatabaseException
- adapted some connections to use this new TSQLDatabaseError
Bug #23798
git-svn-id: trunk@26765 -
2014-02-14 11:43:54 +00:00
michael
1abce09e3c
* Made GetStatementInfo public (bug ID 24113)
...
git-svn-id: trunk@26725 -
2014-02-08 11:58:36 +00:00
reiniero
9db59ea8e7
* fcl-db: cosmetic: replace Dutch variable name with English
...
git-svn-id: trunk@26419 -
2014-01-11 01:35:58 +00:00
lacak
b6005af745
fcl-db: sqldb: add support for backtick "`" as identifier delimiter.
...
git-svn-id: trunk@26152 -
2013-11-28 13:23:46 +00:00
reiniero
494d79bd7e
* fcl-db: TSQLScript: support explicit COMMIT/COMMIT WORK and COMMIT RETAIN script commands (with UseCommit) to use commit, respectively commit retaining.
...
git-svn-id: trunk@26120 -
2013-11-23 17:32:36 +00:00
reiniero
caa86aaab9
* fcl-db: tsqlscript: do not parse : as parameters; fixes creating Firebird stored procedures with select bla into :bla
...
cosmetic: comments
git-svn-id: trunk@26112 -
2013-11-20 07:38:25 +00:00
lacak
f02dd9fde9
fcl-db: sqldb: formatting + add default information schema query for SchemaType=stProcedures (for those TSQLConnection descendants, which does not implement own schema query use sql standard)
...
git-svn-id: trunk@26087 -
2013-11-14 11:55:42 +00:00
michael
48250dcafd
* implementation of sqSupportEmptyDatabaseName from Laco, used in PostGres and MSSQL
...
git-svn-id: trunk@25584 -
2013-09-27 11:42:15 +00:00
michael
10eb918bed
* Register/Unregister SQL Statements less often
...
git-svn-id: trunk@25540 -
2013-09-23 18:11:34 +00:00
michael
ae4810edd6
* Restore old behaviour for caNone for Action
...
git-svn-id: trunk@25252 -
2013-08-12 12:56:16 +00:00
michael
b1c111b423
* Mark transaction as closed in caNone case of EndTranscation
...
git-svn-id: trunk@25251 -
2013-08-12 12:44:03 +00:00
lacak
59b2c38530
fcl-db: sqldb: formatting
...
git-svn-id: trunk@25166 -
2013-07-24 11:02:02 +00:00
lacak
bc7fd7afa8
fcl-db: sqldb: - Move private method "GetStatementInfo" to protected and make it virtual to allow TSQLConnection descendants override it
...
- Rename new property "CheckParams" to "ParamCheck" to align with other components such as Zeos, IBObjects, IBX, ADODB, ElevateDB, SQLMemTable and many others.
git-svn-id: trunk@25165 -
2013-07-24 10:40:08 +00:00
lacak
8602706228
fcl-db: sqldb:
...
- do not allocate cursor when opening bufdataset from file
- when closing TSQLQuery do not deallocate cursor while can be prepared (fixes "[SETUP] unable to close due to unfinalised statements" bug for SQLite)
- when unpreparing statement take into account that there are also SQLConnections which does not support [un]preparation of statements ... bur for those we must still call UnRegisterStatement (fixes multiple "[TEARDOWN] Access violation" in tests)
git-svn-id: trunk@25063 -
2013-07-08 10:40:27 +00:00
michael
087b6b4a39
* Fixed Master/Detail relation in SQLDB and fixed memory leak
...
git-svn-id: trunk@25055 -
2013-07-07 18:14:11 +00:00
lacak
ee2fee4259
fcl-db: sqldb:
...
- handle quoted table names when retrieving server index informations for quoted TableName
- reset updated flag of ServerIndexDefs when SQL.Text changes
- new tests unit for sqlDB
- tested for FB, MSSQL, MySQL, PostgreSQL, Sqlite, odbc_MSSQL, odbc_PostgreSQL, odbc_Firebird, odbc_MySQL
git-svn-id: trunk@24880 -
2013-06-12 11:01:59 +00:00
lacak
b7d5ed4bd7
fcl-db: sqldb: Some SQLConnections does not support statement [un]preparation, so let them do cleanup f.e. cancel pending queries and/or free resultset when dataset is closed.
...
git-svn-id: trunk@24803 -
2013-06-04 10:11:38 +00:00
lacak
299938e784
fcl-db: sqldb: FSelectable must be set to true by default, to work for TSQLConnections which does not provide information about statement (if there will be resultset) at preparation stage.
...
git-svn-id: trunk@24795 -
2013-06-03 06:29:51 +00:00
michael
ff1c478ba4
* Fix some memory leaks (not all: see AppendDeleteCancelUpd)
...
git-svn-id: trunk@24768 -
2013-06-02 13:13:42 +00:00
michael
03dd596485
* Refactor TSQLQuery to use TSQLStatement
...
git-svn-id: trunk@24742 -
2013-06-01 18:23:41 +00:00
michael
678fb02f11
* Fix cursor mem leak
...
git-svn-id: trunk@24732 -
2013-06-01 17:07:52 +00:00
michael
f58b3aa25a
* Implemented CheckParams for TSQLStatement, TSQLQuery. It disables check for parameter names
...
git-svn-id: trunk@24705 -
2013-06-01 12:29:18 +00:00
michael
abe86dea9f
* TSQLStatement.RowsAffected
...
git-svn-id: trunk@24703 -
2013-06-01 10:56:24 +00:00
michael
5042e1060f
* Activated Action for TSQLTransaction
...
git-svn-id: trunk@24702 -
2013-06-01 10:55:30 +00:00
michael
4466342d82
* First implementation of TSQLStatement
...
git-svn-id: trunk@24694 -
2013-06-01 10:02:11 +00:00
lacak
19132fc98d
fcl-db: sqldb: implemented TSQLConnection.GetSchemaNames
...
Added stSchemata to TSchemaType (Delphi has strange stUserNames instead)
At TSQLConnection level stSchemata defaults to 'select * from INFORMATION_SCHEMA.SCHEMATA', which can be overriden in descendants.
git-svn-id: trunk@23921 -
2013-03-18 09:58:50 +00:00
michael
7fbf05dd18
* Make statementtype public in TSQLQuery
...
git-svn-id: trunk@23498 -
2013-01-22 20:36:05 +00:00
michael
f566201a8d
* Notification should be protected
...
git-svn-id: trunk@23455 -
2013-01-20 11:25:28 +00:00
lacak
7e2627f047
fcl-db: formatting (char case)
...
git-svn-id: trunk@23139 -
2012-12-14 07:00:39 +00:00
lacak
66a6b15efe
fcl-db: switch from usage of [stSelect, stExecProcedure] to FSelectable to determine if there is result set.
...
(see also previous commit)
git-svn-id: trunk@23137 -
2012-12-13 11:26:45 +00:00
lacak
6a9c3a6061
fcl-db: introduce FSelectable as new TSQLCursor class field. Update sql connectors to set it after Preparation or Execution of sql statement to signal if there will be or is result set. This change is neutral. In next commit I will use FSelectable to determine if allow Open or raise SErrNoSelectStatement.
...
(motivation is that there are many various statements, that are not stSelect nor stExecProcedure, which also return result set)
git-svn-id: trunk@23136 -
2012-12-13 11:16:25 +00:00
michael
5f053be31d
* Switched to using ansistring, because dynlibs use ansistrings
...
git-svn-id: trunk@22949 -
2012-11-07 23:08:31 +00:00
ludob
35f1339404
sqldb: Modified ftAutoinc behavior slightly to match Delphi behavior and allow updating of ftAutoInc fields for those db backends that support it. Added support for odbc ReadOnly fields. Patch from Lacak2 Mantis #22531
...
git-svn-id: trunk@22935 -
2012-11-05 15:23:15 +00:00
lacak
d338b2c63b
* adds new virtual method GetConnectionInfo into TSQLConnection
...
(allows retrieval of various connection related informations like type and version of DBMS, name and version of client library)
* implements this method for MySQL, PostgreSQL, SQLite, ODBC
Patch by DB-Core team
git-svn-id: trunk@22886 -
2012-10-31 09:13:32 +00:00
ludob
91a468307a
Fix for table names converted to uppercase Mantis 0022766 Patch by Lacak2
...
git-svn-id: trunk@22572 -
2012-10-07 15:06:59 +00:00
michael
53c03717d5
* SQL DB loader implemented
...
git-svn-id: trunk@22163 -
2012-08-21 19:41:51 +00:00
marco
c4ec774c4c
* Fixes Sql parsing problems with spaces lacking between keyword and expression
...
(like where(id=0) ) Mantis #21965 , patch by Ludo, updated by Lacak2.
git-svn-id: trunk@21742 -
2012-06-30 17:53:42 +00:00
joost
67ab61dcc8
* Moved .ReadOnly property from TSQLQuery to TBufDataset
...
git-svn-id: trunk@21254 -
2012-05-08 12:21:50 +00:00
marco
abaf2eaf12
* sqlDB update SQLParser to parse DML statements WITH common table expressions
...
Patch by Lacak2, Mantis #21851
git-svn-id: trunk@21010 -
2012-04-24 08:45:16 +00:00
joost
3568f8a3fe
* Also recognize parameters wich starts with lowercase old
...
git-svn-id: trunk@20939 -
2012-04-20 13:38:58 +00:00
marco
86ec9c367c
* Patch from Lacak2 for #16842 . Fix parsing of FROM (mysql show..from)
...
git-svn-id: trunk@20919 -
2012-04-18 13:31:35 +00:00
marco
f979c2e67f
* Add millisecs to datetime parameters, Mantis #20616 . Patch by Lacak2.
...
git-svn-id: trunk@20405 -
2012-02-22 21:01:11 +00:00
marco
7a7d8e27cd
* set transaction of proxy via field instead of setter since that
...
triggers a cascade of actions. Mantis #20694
git-svn-id: trunk@19657 -
2011-11-19 13:02:31 +00:00
marco
5955d90a40
* pass fieldnamequotechars to proxy, mantis #20507
...
git-svn-id: trunk@19507 -
2011-10-18 15:58:16 +00:00
marco
cb832a5656
* Preserve existing param values when changing sql text.
...
Patch by Lacak2, Mantis #19456
git-svn-id: trunk@19384 -
2011-10-05 11:41:36 +00:00
marco
0f79033143
* synchronized properties between sqlconnector and sqlconnection.
...
Charset and role now passed on. Mantis #20398 .
git-svn-id: trunk@19361 -
2011-10-04 11:09:34 +00:00
marco
aa9df955ee
* Improve support for returnvalues of calling statements.
...
git-svn-id: trunk@19303 -
2011-09-30 15:41:38 +00:00
marco
448e3db450
* fixes Mantis #14730 dealing with oldvalue=null
...
git-svn-id: trunk@19267 -
2011-09-28 16:27:32 +00:00
marco
1556751109
* also quote ftguid fields. Mantis 20219.
...
git-svn-id: trunk@19060 -
2011-09-14 07:48:24 +00:00