arnobrinkman
962b5e21a3
fixed a typo and changed some comments
2003-05-04 22:02:42 +00:00
alexpeshkoff
8a6430c352
Fixed server crash in EXECUTE STATEMENT combined with exceptions handling block
2003-05-02 15:20:17 +00:00
arnobrinkman
a819ccb060
bugfix: stored procedure with input parameters and aggregate tracking/validating methods failed
2003-04-17 20:58:36 +00:00
arnobrinkman
975638783a
bugfix: Parameters from stored procedures in a sub-select where not remaped to the good context in a aggregate query.
...
example:
SELECT
(SELECT sp.x FROM SP_TEST(T1.ID) sp)
FROM
Table1 T1
GROUP BY
T1.ID
2003-04-16 22:49:41 +00:00
aafemt
b3436b5cd7
STATUS -> ISC_STATUS
2003-04-10 06:32:58 +00:00
brodsom
42ef1314ec
DSQL warning fixes.
2003-04-08 00:31:20 +00:00
dimitr
be5247dc1c
1. Cleanup
...
2. ROWS_AFFECTED is renamed to ROW_COUNT
(see SQL2002 specification)
3. CONNECTION_ID/TRANSACTION_ID are renamed to CURRENT_CONNECTION/CURRENT_TRANSACTION
(see SQL2002 recommendations for context functions)
4. Solved most of the shift/reduce conflicts and all reduce/reduce conflicts in the grammar
5. Fixed ambiguity in ORDER BY clause, when both the value and the clause itself could contain COLLATE word
(now explicit collation sequence of the value is used in the ordering logic)
6. Some of newly introduced tokens are made non-reserved
7. Added code to enable ORDER/GROUP BY ordinal when asterisk is used in the select list
(not sure which version it should go, so it's commented out so far)
2003-04-06 11:20:24 +00:00
brodsom
2c329ec811
- Spli macro to avoid not used warnings
...
- Minor code formatting
2003-04-03 09:29:10 +00:00
arnobrinkman
f83a6084ed
bugfix:
...
1) bug with sub-selects inside COALESCE function.
2) bug with parameter ordering.
2003-03-31 19:11:55 +00:00
arnobrinkman
b099026cdc
corrected mistake in previous commit.
2003-03-10 23:30:53 +00:00
arnobrinkman
f1ca8aed80
bugfix: A bug left with using a aggregate sub-query inside a IN clause.
2003-03-10 21:38:22 +00:00
alexpeshkoff
878b0b6091
Fixed EXECUTE STATEMENT to support INTO clause
2003-03-01 19:19:23 +00:00
arnobrinkman
f890eca4ea
bugfix: DISTINCT with sub-selects (context already in use (BLR error)). Distinct items are now correctly parsed and not just copied from the select-list.
2003-02-23 01:36:22 +00:00
hippoman
1cb0c17ace
* Formated comments to make Doxygen Happy..
2003-02-15 03:01:51 +00:00
hippoman
ad14320d0e
* formated dsql.h comments to make Doxygen happy..
...
* changed DSQL_debug values as follow..
/*! \var unsigned DSQL_debug
\brief Debug level
0 No output
1 Display output tree in PASS1_statment
2 Display input tree in PASS1_statment
4 Display ddl BLR
8 Display BLR
16 Display PASS1_rse input tree
32 Display SQL input string
64 Display BLR in dsql/prepare
> 256 Display yacc parser output level = DSQL_level>>8
*/
2003-02-15 02:05:10 +00:00
tamlin
bc383ff498
A bit const correctness added and some reinterpret_casts removed.
...
Changed DSQL's str to actually hold char.
2003-02-12 19:28:13 +00:00
arnobrinkman
bd7a1b6bed
bugfix: wrong context was used with FieldX IN (sub-select) predicate.
...
Caused by me by an other bugfix SF BUG # [ 213859 ]
2003-01-30 22:14:02 +00:00
arnobrinkman
9b5c62d89c
bugfix: It wasn't possible to use non-aggregate related-fields from a aggregate query inside an sub-query.
...
Example (this failed) :
SELECT
Count(T1.F1),
SUM((SELECT T2.F2 FROM Table2 T2 WHERE T2.F1 = T1.F1))
FROM
Table1 T1
2003-01-30 13:30:15 +00:00
skidder
3622fc966f
Fix intermittent bug in aggregate reference tracking
2003-01-17 12:47:19 +00:00
dimitr
55ed1b6444
1. Reworked internal info stuff once more.
...
2. Added DSQL support for parametrized events.
3. Fixed bug with cursors in triggers.
4. Added support for runtime trigger action checks (INSERTING/UPDATING/DELETING).
5. Fixed bug with concatenation and trashed RDB$FIELD_LENGTH.
2003-01-15 12:00:33 +00:00
arnobrinkman
3dcc0600c8
bugfix: SF BUG # [ 213859 ] Subquery connected with 'IN' clause
2003-01-12 20:27:00 +00:00
arnobrinkman
411c18bbf2
bugfix on my latest commits
2003-01-12 16:29:59 +00:00
arnobrinkman
1b552b007e
Introduce backwards compatibilty within aggregates.
...
Deepest field inside aggregate determine where an aggregate-context should belong too.
2003-01-11 02:49:13 +00:00
skidder
2975b16cce
Allow arbitrary expressions in ORDER-BY clause
2003-01-09 16:50:24 +00:00
dimitr
9dc68b4a7b
Fixed bug with BREAK and partially implemented labels and LEAVE statement.
2002-12-18 15:01:50 +00:00
dimitr
6e51db6e6e
1. Implemented ORDER BY clause in subqueries.
...
2. Disallowed FIRST/SKIP for views.
3. Allowed zero as valid argument for FIRST.
2002-12-03 18:04:36 +00:00
hippoman
9a8f0768b9
Changed struct fld and FLD to local module names
2002-11-30 17:45:02 +00:00
arnobrinkman
97caf1f635
bugfix: allow use of other outer-references in a aggregated sub-select
2002-11-25 20:29:39 +00:00
skidder
2b995ac2ab
Make SQLDA parameter mapping consistent with order and number of parameters in source SQL string
2002-11-24 15:22:03 +00:00
arnobrinkman
2ea3a3664a
no message
2002-11-24 13:03:51 +00:00
skidder
f13636d29c
Fixed nulls first/last and collation handling in "order by" clause of unions
2002-11-22 15:27:59 +00:00
hippoman
7387e6fb70
changed nod,tra,req,trg,rel,ctx,prc struct names to local module names
2002-11-20 23:18:16 +00:00
dimitr
776c54bdac
Renamed MSG to DSQL_MSG.
2002-11-19 12:35:28 +00:00
hippoman
62cf7d7a88
change TRA,REQ,TRG,REL,CTX or PRC, to module local names.
2002-11-17 00:04:19 +00:00
hippoman
c75a6d3019
* Changed NOD struct name to DSQL_NOD.
2002-11-11 19:08:37 +00:00
dimitr
7aaa9dc9ee
Let's report real statement, not it's internal meaning.
2002-10-31 12:22:05 +00:00
dimitr
1b2fc90266
Disallowed Nickolay's SAVEPOINT feature for SPs/triggers.
2002-10-31 12:01:53 +00:00
skidder
8e6622a20e
Merging changes from skidder branch - explicit locks, savepoints, build system changes
2002-10-29 20:20:44 +00:00
dimitr
5c8530579d
Re-allowed plans in triggers.
2002-10-25 08:29:12 +00:00
arnobrinkman
38a4597423
AB: "cosmetic changes"
2002-10-19 00:56:25 +00:00
arnobrinkman
ed61fc2a36
AB: bug fixed with sub-select and group by clause and cosmetic changes
2002-10-19 00:32:23 +00:00
arnobrinkman
8b7c1e763e
AB: Fixed bug with alias and GROUP BY clause
2002-10-04 17:53:35 +00:00
arnobrinkman
5d6efbeae8
AB: Fix error-message bug with aggregate only in sub-select
2002-10-01 00:34:29 +00:00
arnobrinkman
dd6b72d89e
AB: Adding better error-handeling and support for subqueries with group_by clause
2002-09-28 23:52:36 +00:00
dimitr
536d8c0552
1. Reworked internal_info implementation in both DSQL and JRD.
...
New helper class created to serve it properly.
2. Added exception re-raise semantics.
Syntax: EXCEPTION;
If there was handled exception, re-initiate it, otherwise evaluate to no-op.
3. Implemented run-time exception messages.
Syntax: EXCEPTION <exception_name> [<value>];
If <value> is specified, evaluate it and use instead of RDB$EXCEPTION_MESSAGE.
4. Added new SQLCODE and GDSCODE system variables.
Available in procedures/triggers only.
If there wasn't any exception raised, return zero (success), otherwise return an error code.
5. Implemented ROWS_AFFECTED system variable.
Available in procedures/triggers only.
Count rows affected by the last INSERT/UPDATE/DELETE statement.
For any other statement, result is always zero.
2002-09-28 14:04:35 +00:00
skidder
6d64014e57
Changed engine to store source file name/line number information for EVERY allocation when DEBUG_GDS_ALLOC is defined. All allocation should be done using FB_NEW or FB_NEW_RPT macros instead of keyword new since now
2002-09-25 17:12:16 +00:00
skidder
f8006cb881
added nulls first/last syntax support
2002-09-10 18:28:23 +00:00
dimitr
b36015e6e9
- allowed user-defined index names for PK/FK/UK constraints
...
- fixed ugly hardcoded name checks for primary/foreign keys
- implemented RECREATE VIEW statement
2002-09-01 15:49:03 +00:00
dimitr
b45eb004a2
Implemented CREATE OR ALTER statement for procedures/triggers/views.
2002-08-27 07:48:34 +00:00
arnobrinkman
d757d31ed4
Added code in pass1_simple_case for handeling parameters in case_operand together with when_operands.
...
The method used to get the derciber for parameters is taken from MAKE_desc_from_list in make.cpp
Example : SELECT CASE FieldA WHEN :param1 THEN 1 WHEN 2 THEN 2 ELSE NULL END FROM TableA
Note : At least one "know describer" must be in the list else no describer could be guested (logic but...) !
2002-08-26 19:40:59 +00:00