summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/ansisql.py
Commit message (Collapse)AuthorAgeFilesLines
...
* reorganizing classnames a bit, flagging "private" classes in the sql package,Mike Bayer2006-10-171-4/+4
| | | | | getting the generated docs to look a little nicer. fixes to extensions, sqlsoup etc. to be compatible with recent API tweaks
* - ForeignKey(Constraint) supports "use_alter=True", to create/drop a foreign keyMike Bayer2006-10-151-11/+47
| | | | via ALTER. this allows circular foreign key relationships to be set up.
* - a fair amount of cleanup to the schema package, removal of ambiguousMike Bayer2006-10-141-25/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | methods, methods that are no longer needed. slightly more constrained useage, greater emphasis on explicitness. - table_iterator signature fixup, includes fix for [ticket:288] - the "primary_key" attribute of Table and other selectables becomes a setlike ColumnCollection object; is no longer ordered or numerically indexed. a comparison clause between two pks that are derived from the same underlying tables (i.e. such as two Alias objects) can be generated via table1.primary_key==table2.primary_key - append_item() methods removed from Table and Column; preferably construct Table/Column/related objects inline, but if needed use append_column(), append_foreign_key(), append_constraint(), etc. - table.create() no longer returns the Table object, instead has no return value. the usual case is that tables are created via metadata, which is preferable since it will handle table dependencies. - added UniqueConstraint (goes at Table level), CheckConstraint (goes at Table or Column level) fixes [ticket:217] - index=False/unique=True on Column now creates a UniqueConstraint, index=True/unique=False creates a plain Index, index=True/unique=True on Column creates a unique Index. 'index' and 'unique' keyword arguments to column are now boolean only; for explcit names and groupings of indexes or unique constraints, use the UniqueConstraint/Index constructs explicitly. - relationship of Metadata/Table/SchemaGenerator/Dropper has been improved so that the schemavisitor receives the metadata object for greater control over groupings of creates/drops. - added "use_alter" argument to ForeignKey, ForeignKeyConstraint, but it doesnt do anything yet. will utilize new generator/dropper behavior to implement.
* some cleanup submitted by Lele GalifaxMike Bayer2006-10-131-1/+1
|
* - Function objects know what to do in a FROM clause now. theirMike Bayer2006-10-031-0/+2
| | | | | | | | behavior should be the same, except now you can also do things like select(['*'], from_obj=[func.my_function()]) to get multiple columns from the result, or even use sql.column() constructs to name the return columns [ticket:172]. generally only postgres understands the syntax (and possibly oracle).
* decruftifyMike Bayer2006-09-281-3/+3
|
* - changed "for_update" parameter to accept False/True/"nowait"Mike Bayer2006-09-101-6/+8
| | | | | | | | | | and "read", the latter two of which are interpreted only by Oracle and Mysql [ticket:292] - added "lockmode" argument to base Query select/get functions, including "with_lockmode" function to get a Query copy that has a default locking mode. Will translate "read"/"update" arguments into a for_update argument on the select side. [ticket:292]
* further fixes to case sensitive logicMike Bayer2006-09-041-4/+5
|
* simplification to quoting to just cache strings per-dialect, added quoting ↵Mike Bayer2006-09-041-74/+52
| | | | | | for alias and label names fixes [ticket:294]
* since casing is figured out quasi-automatically when creating table/column/etc,Mike Bayer2006-08-311-0/+3
| | | | removed casing checks within pg reflection
* quoting more or less working with oracleMike Bayer2006-08-311-1/+4
|
* some tweaks to oracle casing...Mike Bayer2006-08-311-2/+2
|
* - added case_sensitive argument to MetaData, Table, Column, determinesMike Bayer2006-08-311-6/+24
| | | | | | | | | | | | itself automatically based on if a parent schemaitem has a non-None setting for the flag, or if not, then whether the identifier name is all lower case or not. when set to True, quoting is applied to identifiers with mixed or uppercase identifiers. quoting is also applied automatically in all cases to identifiers that are known to be reserved words or contain other non-standard characters. various database dialects can override all of this behavior, but currently they are all using the default behavior. tested with postgres, mysql, sqlite. needs more testing with firebird, oracle, ms-sql. part of the ongoing work with [ticket:155]
* [ticket:266] constraint name in PrimaryKeyConstraintMike Bayer2006-08-261-3/+5
|
* added limit/offset to union queriesMike Bayer2006-08-261-3/+6
|
* working on sequence quoting support....Mike Bayer2006-08-211-2/+17
|
* refactoring of ANSIIdentifierPreparer to be one instance per-dialect, ↵Mike Bayer2006-08-211-46/+25
| | | | simplified caching
* - postgres reflection moved to use pg_schema tables, can be overriddenMike Bayer2006-08-211-16/+49
| | | | | | | | with use_information_schema=True argument to create_engine [ticket:60], [ticket:71] - added natural_case argument to Table, Column, semi-experimental flag for use with table reflection to help with quoting rules [ticket:155]
* [ticket:280] statement execution supports using the same BindParamMike Bayer2006-08-181-24/+5
| | | | | object more than once in an expression; simplified handling of positional parameters. nice job by Bill Noon figuring out the basic idea.
* added "requires_quotes" step, subclasses of ANSIIdentifierPreparer can overrideMike Bayer2006-08-161-3/+7
|
* refactored ANSIIdentifierPreparer to be visitor based; minimizes escaping ↵Mike Bayer2006-08-121-28/+54
| | | | | | operations and isinstance()/duck-typing calls
* turned off default case-folding rules as they wreak havoc with the current ↵Mike Bayer2006-08-121-5/+5
| | | | | | | unittests, temporary isintance() checks in ASNIIdentifierPreparer which will be replaced with visit_ methodology
* quoting facilities set up so that database-specific quoting can beMike Bayer2006-08-121-19/+90
| | | | | | | turned on for individual table, schema, and column identifiers when used in all queries/creates/drops. Enabled via "quote=True" in Table or Column, as well as "quote_schema=True" in Table. Thanks to Aaron Spike for his excellent efforts. [ticket:155]
* added "nowait" flag to Select() [ticket:270]Mike Bayer2006-08-111-0/+3
|
* _selectable interface; allows sqlsoup to pass its classes to Join and have ↵Jonathan Ellis2006-07-211-19/+22
| | | | the underlying Table pulled out
* added 'checkfirst' argument to table.create()/table.drop()Mike Bayer2006-07-191-0/+14
| | | | some 0.2.6 prep
* fixed table name in REFERENCES clause to include schema if applicableMike Bayer2006-07-181-1/+1
|
* overhaul to schema, addition of ForeignKeyConstraint/Mike Bayer2006-07-141-8/+26
| | | | | | | | PrimaryKeyConstraint objects (also UniqueConstraint not completed yet). table creation and reflection modified to be more oriented towards these new table-level objects. reflection for sqlite/postgres/mysql supports composite foreign keys; oracle/mssql/firebird not converted yet.
* single space for MySQL appeasementMike Bayer2006-06-191-1/+4
|
* cast converted into its own ClauseElement so that it can have an explicit ↵rel_0_2_3Mike Bayer2006-06-171-1/+7
| | | | | | | | | | | compilation function in ANSICompiler MySQLCompiler then skips most CAST calls since it only seems to support the standard syntax for Date types; other types now a TODO for MySQL then, polymorphic_union() function now CASTs null()s to the type corresponding to the columns in the UNION, since postgres doesnt like mixing NULL with integer types (long road for that .....)
* fixed bug where Column with redefined "key" property wasnt gettingMike Bayer2006-06-141-1/+1
| | | | type conversion happening in the ResultProxy [ticket:207]
* HashSet is gone, uses set() for most sets in py2.4 or sets.Set.Mike Bayer2006-06-051-2/+2
| | | | ordered set functionality supplied by a subclass of sets.Set
* merged 0.2 branch into trunk; 0.1 now in sqlalchemy/branches/rel_0_1Mike Bayer2006-05-251-47/+53
|
* rick morrison's CASE statement + unit testMike Bayer2006-05-151-1/+7
|
* fixed HAVING/ORDER BY order, 0.1.7 prepMike Bayer2006-05-051-4/+4
|
* fix for [ticket:169], moves the creation of "default" parameters more accuratelyMike Bayer2006-04-281-16/+21
| | | | where theyre supposed to be
* localtime/localtimestamp dont seem to need the underscore for ↵Mike Bayer2006-04-261-2/+2
| | | | postgres/mysql, making that default
* moves the binding of a TypeEngine object from "schema/statement creation" ↵Mike Bayer2006-04-061-1/+4
| | | | time into "compilation" time
* made order_by/group_by construction a little more simplisitcMike Bayer2006-04-031-6/+13
| | | | | fix to mapper extension CompoundSelect can export all columns now, not sure if theres any advantage there
* added for_update flag to Select/CompoundSelectMike Bayer2006-03-311-0/+3
|
* removed all "tablename + '_' + columname" code and replaced with ↵Mike Bayer2006-03-251-1/+4
| | | | | | | | column._label, to take advantage of column labeling rules bind param compilation,when it unique-ifys the name of bind params, maintains the length of the bind parameter name instead of appending to it
* got clause elements inside INSERTs going...Mike Bayer2006-03-191-7/+15
|
* got oracle parenthesized rules for funcs back, fixed copy_container on functionMike Bayer2006-03-181-1/+4
|
* expanded and integrated qvx's patch for dotted function namesMike Bayer2006-03-161-2/+2
|
* added scalar subqueries within the column clause of another selectMike Bayer2006-03-131-1/+5
|
* refactor to Compiled.get_params() to return new ClauseParameters object, a ↵Mike Bayer2006-03-131-15/+7
| | | | | | | | | | | more intelligent bind parameter dictionary that does type conversions late and preserves the unconverted value; used to fix mappers not comparing correct value in post-fetch [ticket:110] removed pre_exec assertion from oracle/firebird regarding "check for sequence/primary key value" fix to Unicode type to check for null, fixes [ticket:109] create_engine() now uses genericized parameters; host/hostname, db/dbname/database, password/passwd, etc. for all engine connections fix to select([func(column)]) so that it creates a FROM clause to the column's table, fixes [ticket:111] doc updates for column defaults, indexes, connection pooling, engine params unit tests for the above bugfixes
* patch on index create syntax to fix [ticket:90] so schema name gets includedMike Bayer2006-03-061-1/+1
|
* added new 'polymorphic' example. still trying to understand it :) .Mike Bayer2006-03-061-2/+5
| | | | | fixes to relation to enable it to locate "direction" more consistently with inheritance relationships more tweaks to parenthesizing subqueries, unions, etc.
* more tweak to compoundselect parenthesizing/subquery flagMike Bayer2006-03-061-2/+2
|
* got column onupdate workingMike Bayer2006-03-051-7/+55
| | | | improvement to Function so that they can more easily be called standalone without having to throw them into a select().