summaryrefslogtreecommitdiff
path: root/odb/relational
AgeCommit message (Collapse)AuthorFilesLines
2011-11-08Tighten Oracle SQL type parsing logicConstantin Michael1-56/+68
2011-11-08Pass LOB capacity using bind::capacity member instead of deriving at run-timeConstantin Michael1-4/+13
2011-11-08Add support for Oracle INTERVAL temporal typesConstantin Michael6-112/+295
2011-11-01Implement support for optimistic concurrencyBoris Kolpackov8-74/+471
New pragmas: optimistic, version. New test: optimistic. New database function: reload().
2011-11-01Rework statement interfaces wrt param/result passingBoris Kolpackov1-17/+31
2011-11-01Rename local variable to improve readabilityConstantin Michael1-3/+3
2011-11-01Use lob_auto_descriptor pointer as LOB image typeConstantin Michael1-2/+1
2011-11-01Generate an image inline function that will return its change_callback memberConstantin Michael2-4/+22
libodb-oracle references the change_callback member of an image even when code is generated without query support. In order to avoid invalid references, the change_callback member is accessed via a getter method that is always generated.
2011-11-01Format generated code nicelyConstantin Michael1-1/+2
2011-11-01Do not generate image version or change_callback members for abstract objectsConstantin Michael3-4/+5
2011-11-01Implement query image change callback machineryConstantin Michael4-0/+35
2011-10-28Implement returning of auto id using RETURNING clause in PostgreSQLBoris Kolpackov1-0/+12
Before we used a separate SELECT lastval() query which was both inefficient and error-prone in cases where INSERT may cause triggers to override the last value.
2011-10-27Add support for persistent classes without object idsBoris Kolpackov6-254/+326
New pragma id (object). New test: common/no-id.
2011-10-27Use default behaviour for Oracle default_boolConstantin Michael1-9/+0
2011-10-26Do not use TRUE and FALSE boolean literals in OracleConstantin Michael1-1/+1
2011-10-26Output DEFAULT clause before NULL specification when generating schemaConstantin Michael1-3/+4
Oracle requires that the DEFAULT clause appear before any column contraints are specified when creating a table.
2011-10-26Disable result caching in OracleConstantin Michael1-0/+14
2011-10-24Generate database schema from database model instead of C++ modelBoris Kolpackov25-1227/+2065
We now first create the so-called database model from C++ model and then use that to generate the database schema. The new approach also adds more general support for primary/foreign keys, including multi- column keys. Finally, for MySQL we now generate out-of-line foreign key definitions. Because MySQL does not support deferred constraints checking, deferred foreign keys are written commented out, for documentation.
2011-10-21Use base implementation instead of duplicating codeBoris Kolpackov1-10/+8
2011-10-21Add support for const data membersBoris Kolpackov22-177/+419
Const data members are automatically treated as readonly. New test: const-member.
2011-10-21Add support for readonly membersBoris Kolpackov7-162/+398
New pragma: readonly. New test: readonly.
2011-10-21Split 'in' binding into insert/update pair; rename 'out' to selectBoris Kolpackov8-215/+535
Also add the initial infrastructure for the readonly members support. Right now the split insert/update bindings allows us to avoid sending object id in UPDATE statements. It will also allows us to support readonly members.
2011-10-21Generate auto_id constant even if id is in baseBoris Kolpackov1-0/+3
2011-10-21Add schema_file implementation to support schema file header and footer hooksConstantin Michael3-0/+49
2011-10-21Refactor persist statement hookConstantin Michael2-41/+22
2011-10-21Correct auto_id flag generationConstantin Michael1-1/+1
2011-10-21Implement Oracle identifier truncation to 30 charactersConstantin Michael2-0/+15
2011-10-21Rename relational::context::use_as to relational::context::need_alias_asConstantin Michael7-14/+14
2011-10-21Aesthetic changes and small bug fixesConstantin Michael2-4/+5
2011-10-21Add persist_stmt hook to handle generation of persist statement SQLConstantin Michael2-9/+57
ODB requires that Oracle persist statements include a RETURNING clause so that a generated auto_id column value may be returned.
2011-10-21Disable auto_id initialization hook for OracleConstantin Michael1-2/+1
This is not necessary and is more complex than originally thought due to the possibility of auto_id columns having a char* image type.
2011-10-21Update code generation to support use of SQLT_NUM OCI type instead of SQLT_VNUConstantin Michael2-3/+4
2011-10-21Correct generation of Oracle sequences and triggers for auto increment columnsConstantin Michael1-4/+12
2011-10-21Disable generation of inline foreign key constraintsConstantin Michael1-0/+5
2011-10-21Specify all VARCHAR2 and NVARCHAR2 columns as nullableConstantin Michael1-0/+13
Oracle interprets empty VARCHAR2 and NVARCHAR2 strings as NULL. As an empty string is always valid within the C++ context, VARCHAR2 and NVARCHAR2 columns are always specified as nullable.
2011-10-21Cascade constraints when dropping Oracle tablesConstantin Michael1-1/+1
2011-10-21Minimize Oracle schema_emitter implementationConstantin Michael2-15/+5
2011-10-21Use cached auto_id flag to determine presence of auto increment columnConstantin Michael2-22/+7
2011-10-21Add a context flag indicating whether AS SQL keyword should be used for aliasesConstantin Michael6-0/+10
2011-10-21Do not allocate a buffer for LOB images as connections now maintain oneConstantin Michael2-10/+6
2011-10-21Generate object traits auto id flag for all databasesConstantin Michael2-17/+3
2011-10-21Generate Oracle code using updated bind callback and context membersConstantin Michael2-7/+6
2011-10-21Initialize position context to zero prior to Oracle LOB set_image callConstantin Michael1-1/+2
2011-10-21Aesthetic changes and syntax correctionsConstantin Michael1-2/+4
2011-10-21Correct Oracle SQL type parser implementationConstantin Michael1-12/+14
2011-10-21Utilize the RAW buffer typeConstantin Michael1-1/+1
2011-10-21Generate select_statement::stream_result in Oracle sourceConstantin Michael1-0/+6
2011-10-21Add init_value_extra hook to relational source generationConstantin Michael1-5/+16
2011-10-21Specialize schema_emitter for OracleConstantin Michael1-0/+47
SQLPlus scripts are required to indicate PL/SQL block terminations with a trail '/'.
2011-10-21Allow per database specialization of schema_emitterConstantin Michael2-34/+36