8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-27 04:43:02 +01:00
Commit Graph

219 Commits

Author SHA1 Message Date
alexpeshkoff
4bdc2a3e19 Replaced macro FB_ALIGN with function fbAlign, minor related cleanup 2014-07-24 06:41:38 +00:00
skidder
7c743fc291 Fix build warnings 2014-07-17 18:48:46 +00:00
alexpeshkoff
6a2016235a Fixed CORE-4435: After calling release() for attachment to database (instead detach) in embedded mode attachment remains active forever (and some cleanup re. reference counters) 2014-06-10 07:13:34 +00:00
alexpeshkoff
ee7088a6c9 Use GlobalPtr for static variable doing memory allocation 2014-06-06 10:41:25 +00:00
alexpeshkoff
be0f72fa6e Fixed assertion reported by Pavel Zotov privately, took typical measures to avoid such behavior in the future 2014-05-20 08:05:16 +00:00
dimitr
ae8f5bbc5a Misc. 2014-04-13 10:58:15 +00:00
alexpeshkoff
20e846369e Implemented CORE-3370: Resolve additional aspects of multiple security databases from services and cross-database requests POV (mapping names) 2014-04-04 15:57:18 +00:00
robocop
66af445e2e Misc. 2014-03-22 20:51:24 +00:00
asfernandes
19abcf94fd Cleanup InternalMessageBuffer. 2014-03-09 01:55:42 +00:00
robocop
ae8f6d6b8f Misc. 2014-03-03 04:37:29 +00:00
alexpeshkoff
18d66a33b4 Cleanup - avoid unneeded generate's argument in SortedArray and Hash 2013-09-24 08:46:10 +00:00
dimitr
01b81b1edb Code simplification and some corrections. 2013-08-19 18:50:28 +00:00
dimitr
551e2416c6 Add interface support for scrollable DSQL cursors. Implementation will follow later. 2013-04-13 07:11:58 +00:00
asfernandes
0d299d455a Remove FbMessage struct from the API.
This struct lost its main value (group various blr-related properties in a single parameter).
And since openCursor/fetch already split the message/buffer, it does not make sense anymore to have it.
2013-02-26 03:42:19 +00:00
alexpeshkoff
fc12495d0e Modified IStatement interface in our API:
1. Never allocate empty statement - always use att->prepare() to create statement interface
2. Separated IStatement into 2 parts - statement itself and resultset.
3. Added stmt->openCursor() (and att->openCursor() for unprepared statements) to create IResultSet.
4. Always use IMessageMetadata (former IParametersMetadata) to pass message fromat info from client,
   therefore avoiding need in BLR generation in client applications.
2013-02-17 12:08:53 +00:00
dimitr
1d4ff45d6b Slightly optimized fetches for internal EXECUTE STATEMENT. 2013-01-25 13:01:19 +00:00
asfernandes
970677e8de Get rid of dsql_str and fix metadata strings. 2012-12-25 17:34:50 +00:00
alexpeshkoff
c7454a49a5 Work in progress (committed due to SF upgrade). Checked only on SS.
1. Frontported fix for CORE-3935 and CORE-3993.
2. Added debugging support for mutexes and rwlocks in Vulcan style.
Unfortunately after last 'svn up' build asserts in JrdStatement:71.
2012-12-14 17:59:02 +00:00
hvlad
b1e465c84a Make BPB correctly 2012-11-27 11:16:21 +00:00
alexpeshkoff
4ca6e669fe 1. Fixed CORE-3786: Firebird 2.5.1 Hangs on MacOSX 10.7 (Lion) on DB create after reboot.
2. Cleanup: avoid functional style in stuff exception.
2012-11-01 11:40:18 +00:00
alexpeshkoff
2a01e4bcf9 Implemented CORE-3861: Make it possible to encrypt database
Also some cleanups, the most important are:                                                                                                                   
- meaningful ctor on Jrd::Lock, helping to avoid code dup                                                                                                     
- avoid unneeded h-file dependencies, making boot build engine dependent
2012-05-31 16:53:42 +00:00
asfernandes
07747144f7 Unify DSQL/JRD sub-nodes. 2012-05-03 16:43:29 +00:00
hvlad
a935f95d5a Fixed bug CORE-3799 : with caller privileges option don't work with autonomous transaction option 2012-03-29 13:30:17 +00:00
alexpeshkoff
4e795f4047 Include platform definitions file common.h in firebird.h. Use OS-specific ThreadId instead artificial FB_THREAD_ID, avoiding unneeded casts in the code. This should fix BSD and MAC ports. 2012-03-01 08:55:43 +00:00
robocop
0b5ee78cb7 Make more members of blb private. 2012-02-15 07:13:41 +00:00
robocop
5d2a0118c0 I don't see the point in creating temporary strings in these cases. 2012-02-15 03:43:06 +00:00
robocop
eed418a89e Make blb resemble more a class: private data members, convert some functions into methods, add methods with code that was in other files, etc. 2012-02-15 03:34:21 +00:00
robocop
186c817caa Playing with fire: converting some static functions into member functions. I tried to check every change I did. 2012-02-07 03:17:52 +00:00
asfernandes
27bb1f8bc1 1) Removed READ/WRITE BLOB sql commands. 2) Refactored request operations to fix server crashes. 2012-02-03 19:01:36 +00:00
robocop
21cd78a0fd Cleanup: unused functions, parameters & variables. 2012-01-24 03:37:43 +00:00
asfernandes
5ae632cf0b Feature CORE-1288 - Sub Procedures.
They're very simple for now. No access to parent variables nor to call neighbour procedures.

Tests at http://firebird.cvs.sourceforge.net/viewvc/firebird/fbtcs/GTCS/tests/FB_SQL_SUBPROC_1.output.
2011-10-02 22:11:41 +00:00
asfernandes
f14ec26183 Misc. 2011-06-04 02:18:55 +00:00
alexpeshkoff
4c02901734 Fixed segfault in execute statement, reported by Dmitry privately 2011-06-03 15:29:01 +00:00
asfernandes
2fd18f68c9 Lets try to avoid global functions using name with mixed new (functionName) and old SUBSYS_name name style. 2011-05-11 17:42:44 +00:00
hvlad
479a7f600d Renamed currentProvider to EngineProvider to better reflect its nature and corrected its declaration (with Alex permission ;). Removed unneeded cast. 2011-05-11 14:45:56 +00:00
asfernandes
d0c2265105 Misc. 2011-05-10 01:12:14 +00:00
hvlad
fef1f49c94 Shared page cache implementation 2011-05-09 10:15:19 +00:00
asfernandes
69dc52ba48 Integrate IAttachment and ITransaction in the external engines API. 2011-05-07 19:52:44 +00:00
asfernandes
9754526943 Misc; reinterpret to static casts; correction in YRequest version. 2011-04-26 01:00:33 +00:00
alexpeshkoff
256cb1e853 1. Use reference counted stable in global pool objects instead PublicHandle's validation.
2. Avoid massive segfaults when closing heavily loaded server.                                                                                 
3. Restored logic in YValve required for correct shutdown.                                                                                    
4. Do not change externally visible request body when preparing it.
2011-04-25 17:47:56 +00:00
asfernandes
c63493ffba Added metadata support to IStatement. 2011-04-14 01:03:43 +00:00
alexpeshkoff
437d841cfa Rolled back my commit using IBlrMessage interface. Replaced with single plain structure FbMessage. 2011-04-13 12:41:40 +00:00
alexpeshkoff
9a4689d3e9 Use interface IBlrMessage instead passing C++ class pointer to API interface's functions 2011-04-08 16:43:05 +00:00
alexpeshkoff
5c88e478f6 Use better names for a number of objects according to Vlad's suggestion 2011-04-07 17:16:00 +00:00
robocop
82403a5621 Misc, style, etc. 2011-04-02 04:45:26 +00:00
asfernandes
166c41c5b1 Move transactRequest, createBlob, openBlob, getSlice, putSlice and ddl from ITransaction to IAttachment.
It's better to have one standard than two, and "ddl" was broken from API POV.
So make the IAttachment always the caller, explicit or implicit (via IStatement or IRequest), and pass the ITransaction as parameter.
2011-03-21 21:56:47 +00:00
asfernandes
c863db6e6d Removed commented out Sqlda support and rename methods removing the word 'messsage'. 2011-03-20 19:15:55 +00:00
asfernandes
34fd6866bc Remove unused message types. 2011-03-20 19:15:13 +00:00
asfernandes
2ce201f4ae Use MessageBuffer in executeMessage and fetchMessage. 2011-03-20 19:14:03 +00:00
alexpeshkoff
f6914b8db0 Added timer-related interfaces. Added helper method to wait for plugin to be released on shutdown. Misc stability changes in PluginManager. 2011-03-16 11:04:04 +00:00
alexpeshkoff
f89ac854ef Getting ready to use 32 (not 31) page and transaction numbers 2011-01-21 17:55:04 +00:00
alexpeshkoff
d6fcde387b New plugin manager. Use it for all types of plugins. 2011-01-14 17:31:40 +00:00
asfernandes
c9ec26c0c3 Feature CORE-726 - Boolean data type 2010-12-18 02:17:06 +00:00
asfernandes
9c42d4e5af Finish the statements refactor in the engine. Get rid of jrd_nod. 2010-12-04 22:15:03 +00:00
asfernandes
8af7ec0211 Refactored the support for blr_handler, blr_loop, blr_exec_sql, blr_exec_into, blr_exec_stmt,
blr_start_savepoint, blr_end_savepoint, blr_store, blr_store2, blr_erase, blr_modify,
blr_modify2, blr_exec_proc, blr_exec_proc2, blr_exec_pid, blr_dcl_cursor, blr_cursor_stmt,
blr_set_generator, blr_receive, blr_stall, blr_select, blr_block, blr_error_handler,
blr_label, blr_leave, blr_continue and the source info node.
2010-11-29 02:17:04 +00:00
asfernandes
594e390d42 Fixed segfault after EXECUTE STATEMENT with invalid SQL 2010-11-28 14:56:35 +00:00
asfernandes
a3064848d6 Make ExprNodes and RecordSourceNodes reference others directly instead of via jrd_nod.
Store ValueExprNodes instead of jrd_nod in the metadata cache.
Make RecordSourceNode child of ExprNode as they share most operations.
Get rid of the JRD visitors in favor of direct calls.
Convert assignments statement lists created inside expressions to separate source and targets ValuesExprNodes.
2010-11-21 03:47:29 +00:00
asfernandes
3eb252ec5f Refactored DSQL nodes: nod_derived_field, nod_map, nod_dbkey and nod_rec_version.
Refactored JRD nodes: blr_field (JRD side only), blr_dbkey, blr_record_version and blr_stmt_expr.
2010-11-14 17:25:48 +00:00
dimitr
bc3a797d4a If we swallow the exception, let's zap it inside the status vector as well. This fixes the assertion in the debug build. 2010-11-08 07:23:32 +00:00
alexpeshkoff
0ab6c4abf7 Avoid throwing C++ exceptions from authentication plugins 2010-10-28 08:02:42 +00:00
alexpeshkoff
e05c1a825f Moved some more .h-files to common from jrd as Vlad suggested 2010-10-13 10:39:52 +00:00
asfernandes
91384eb587 Misc 2010-10-12 17:40:27 +00:00
alexpeshkoff
83d6a2f88c Restored a lot of changes, rolled back by me unintentionally 2010-10-12 11:36:51 +00:00
alexpeshkoff
2dc25a44bb OSRI and new posix build 2010-10-12 08:02:57 +00:00
robocop
98a2c6822d Warnings. 2010-09-24 09:53:51 +00:00
asfernandes
dadc0f560c Const correction for EVL, EXE and they subsystems. Adjustments to CMP and OPT. 2010-08-09 15:48:51 +00:00
hvlad
087a7f7cda Fixed bug CORE-3100 : Wait mode and lock timeout of external transaction of EXECUTE STATEMENT not matched to corresponding parameters of local transaction 2010-08-07 21:18:23 +00:00
asfernandes
361727d549 Misc 2010-08-07 02:38:12 +00:00
hvlad
1ca9c0a020 Fixed bug CORE-3089 : Attempt of execute statement on external datasource failed when datasource is interbase 4.1 2010-08-06 15:16:13 +00:00
hvlad
f4718dfe80 Fixed unregistered bug in EXECUTE STATEMENT : make internal cache of prepared statements work properly. 2010-07-12 08:09:46 +00:00
robocop
9f687c39c4 Misc. 2010-04-29 05:13:03 +00:00
asfernandes
4763533669 Refactor jrd_req into JrdStatement (shared part) and jrd_req (execution of a statement).
Fixed some bugs found in the way.
2010-04-18 22:19:11 +00:00
hvlad
fcbd9482f0 Fixed bug CORE-2907 : Exception handling with EXECUTE STATEMENT 2010-03-18 11:51:21 +00:00
hvlad
fd04d5f776 Fixed bug CORE-2920 : Incorrect execution of volatile SQL statements inside EXECUTE STATEMENT 2010-03-12 15:39:06 +00:00
robocop
446097fe8e Be explicit, change "qualifier" to "package" in QualifiedName (needed anyway if/when schemas are added). 2010-01-27 04:32:27 +00:00
alexpeshkoff
443f261abf Introduce isc_dpb_version2 - format is WideTagged. 2009-12-30 15:24:16 +00:00
asfernandes
82ccb81d3b Unify even more procedure and function handling. While at it, fix a wrong access to req_procedure when validating function. 2009-12-30 01:40:39 +00:00
asfernandes
d8c99a9be2 1) Make procedures and functions member of the same hierarchy (Routine class)
2) Some completion for external functions
2009-12-27 22:05:22 +00:00
asfernandes
d3ac9ac6cc More refactoring: name changes, accessors, consts, removed not good references (statement referencing scratch and metadata indirectly) 2009-12-23 00:57:08 +00:00
asfernandes
8968888820 Getters and setters for DsqlCompiledStatement and consts 2009-12-22 15:36:10 +00:00
dimitr
debe65bcfb Support for PSQL functions (other JRD changes). Still work in progress. 2009-12-21 17:43:01 +00:00
asfernandes
50542e3f00 Make dsql_req::statement constant 2009-12-21 14:56:12 +00:00
asfernandes
74972f5913 Consts 2009-12-20 23:41:48 +00:00
asfernandes
488eb40fe0 Refactor DSQL, continuing the work I started in 2.5:
- Renamed CompiledStatement to DsqlCompilerScratch and removed inheritance to dsql_req.
- Introduced DsqlCompilerStatement, moving things from dsql_req - not completelly shareable yet.
- Make dsql_req reference a DsqlCompilerStatement. DsqlCompilerScratch may be discarded in the future.
- Replaced AlterCharSetNode usage by PreparedStatement for the default collation in database creation.
- Changed METD API.
2009-12-20 21:01:10 +00:00
asfernandes
3f5aded4e3 Misc 2009-11-28 01:44:42 +00:00
robocop
d8a012014b Comments. 2009-11-27 08:34:34 +00:00
robocop
405d008606 Comments. 2009-11-25 09:34:43 +00:00
asfernandes
f2cd6b7ec2 Misc 2009-11-12 01:38:48 +00:00
robocop
94f1a728d6 Misc. 2009-11-06 05:58:57 +00:00
asfernandes
87e274b76a Misc 2009-11-06 01:21:14 +00:00
hvlad
bc9ad95c82 Fixed bug CORE-2731 : Recursive EXECUTE STATEMENT works wrong 2009-11-05 22:42:46 +00:00
robocop
55d60892ca Warnings. 2009-11-05 08:29:33 +00:00
hvlad
e079a00e67 Sorry, it was nedeed 2009-11-04 15:01:34 +00:00
hvlad
c6c7e64ed2 Remove uneeded Jrd:: 2009-11-04 14:52:32 +00:00
hvlad
b18ffff50c Fixed bug CORE-2729 : Current connection may be used by EXECUTE STATEMENT instead of creation of new attachment 2009-11-04 14:49:15 +00:00
asfernandes
ed0e0daeb3 - External Engines implementation.
- Plugins API.

- Feature CORE-2700 - UDR (User Defined Routines) Engine - C++ API supporting functions, triggers and stored procedures.
- Feature CORE-2470 - Support for alternate format of strings literals.
- Feature CORE-2310 - DDL triggers.
- Feature CORE-2312 - PSQL Packages.
- Feature CORE-1209 - CONTINUE statement.
- Feature CORE-1180 - DDL syntax to change (not) nullable state of columns.
- Feature CORE-2090 - Support OVER () clause with current aggregate functions.

- Fixed CORE-2699 - Common table expression context could be used with parameters.

- Introduce ODS 12.0.

- Work in progress in type-safe parser.
- Refactor some DDL commands (procedures and triggers) from DYN to DdlNodes.
- Refactor virtual tables to use a class hierarchy instead of namespaces. This is basic thing, not based on the changes done in Vulcan. Window functions is based on this work.
- Refactor COMMENT ON and DROP FUNCTION from DYN to DdlNodes. COMMENT ON do not use GDML anymore, it uses DSQL with PreparedStatement class.
- Refactor EXECUTE BLOCK to StmtNodes.
- Refactor the IUDF to SysFunctions. That eliminates RDB$GET_CONTEXT and RDB$SET_CONTEXT from RDB$FUNCTIONS.
2009-10-21 00:42:38 +00:00
hvlad
9071ff2465 Use volatile for better thread-safety, noted by Adriano 2009-09-10 06:40:52 +00:00
asfernandes
3d4aec86e9 Misc 2009-09-10 01:31:49 +00:00
hvlad
738a3cd5d3 Fixed bug CORE-2600 : Server deadlocks while running a few remote EXECUTE STATEMENTs concurrently 2009-09-08 16:37:38 +00:00
robocop
98a5f2e6a4 Misc. 2009-09-03 11:17:46 +00:00