summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/databases/mysql.py
Commit message (Collapse)AuthorAgeFilesLines
...
* Merged lower case caching, fetching from r2955Jason Kirtland2007-07-201-20/+50
| | | | | Be sure to close rows fetched in reflection (if not autoclosed) Fixed bind test, needed transactional storage engine for mysql
* Better quoting of identifiers when manipulating schemasJason Kirtland2007-07-191-9/+18
| | | | Merged from r2981
* Minor cleanups.Jason Kirtland2007-07-171-6/+6
|
* Be specfic when detecting "no table" exceptions.Jason Kirtland2007-07-171-4/+5
|
* - Added basic schema reflection coverage to main testsJason Kirtland2007-07-171-4/+14
| | | | | - Fix stupid mysql typo (#662) - Merged mysql osx/multibyte has_table from 0.4 (r2943)
* Refinement for r2890, column names should remain unicode.Jason Kirtland2007-07-131-0/+3
|
* - Keep reflected strings in the connection encoding, not unicode. For now.Jason Kirtland2007-07-121-10/+7
|
* - Patch up MySQL reflection issues with old server versions, alpha drivers,Jason Kirtland2007-07-121-59/+98
| | | | quoting, and connection encoding.
* some errors of droppedm mysql connections weren't being caught by the ↵Ants Aasma2007-06-271-1/+1
| | | | disconnect detecting logic, fixes #625
* fix #624, modulo operator escaping on mysql and postgresAnts Aasma2007-06-261-0/+6
| | | | someone should test this with oracle, firebird and sql server also
* - result.last_inserted_ids() should return a list that is identicallyMike Bayer2007-06-171-2/+3
| | | | | | sized to the primary key constraint of the table. values that were "passively" created and not available via cursor.lastrowid will be None. - sqlite: string PK column inserts dont get overwritten with OID [ticket:603]
* - MySQL TEXT-derived types weren't respecting convert_unicode, fixes #601Jason Kirtland2007-06-131-1/+2
| | | | - unicode type test now exercises Unicode() and Unicode(len)
* - Rearrange placement of 'fields' (mysql 4.1 reserved word) so that itJason Kirtland2007-06-051-3/+5
| | | | won't accidentally get lost
* - added 'fields' to reserved words [ticket:590]Mike Bayer2007-06-051-1/+1
|
* - Emit BOOL rather than BOOLEAN for MySQL booleans in DDL, for old versionsJason Kirtland2007-05-311-20/+28
| | | | | | | | | | | | of MySQL (#583) - MySQL columns (such as times) with colons in their default values couldn't be roundtripped, fixed (also in Postgres, but not fixed here.) - BINARY/VARBINARY columns aren't really binary at all on ancient versions of MySQL. The type.Binary(123) passthrough now always makes BLOBs. Removed the short-lived MSBaseBinary. - Added mysql.get_version_info, given a connectable returns a tuple of server version info. - Backed off on the reflection tests for older versions of MySQL, for now.
* - Micro-documentation for why we set FOUND_ROWS flag (supports_sane_rowcount)Jason Kirtland2007-05-251-0/+2
|
* - Coerce 'local_infile' mysql connect argument into an intJason Kirtland2007-05-251-2/+3
|
* - Nearly all MySQL column types are now supported for declaration andJason Kirtland2007-05-251-49/+593
| | | | | | | | | | | | reflection. Added NCHAR, NVARCHAR, VARBINARY, TINYBLOB, LONGBLOB, YEAR - The sqltypes.Binary passthrough now builds a VARBINARY rather than a BINARY if given a length - Refactored the inheritance of some types with respect to sqltypes, and especially the binary types - Lots and lots of docs - MySQL unit tests now starting to adapt to known problems with alpha/beta drivers - A couple mysql unit test fix-ups and expansions
* - Expanded on the MySQL ENUM 'strict' documentation a little bit.Jason Kirtland2007-05-021-1/+4
| | | | - Oops, clean up after enum unitttest.
* - MySQL ENUM types can now optionally ensure that values are within theJason Kirtland2007-05-021-5/+56
| | | | | | | | enum's allowed range on insert and update, with strict=True - Added new 'dialect' category of unit tests, and migrated MySQL-specific dialect tests there. - Noted the max identifier length in the MySQL dialect (the max alias length, actually)
* - allow MySQL column-level CHARACTER SET and COLLATE, plus shortcuts likeJason Kirtland2007-05-011-72/+162
| | | | | | | ASCII, UNICODE, and BINARY. support NATIONAL. - added MySQL-specific reserved words - added tests for MySQL numeric and string column DDL generation - various minor cleanups, also tweak regex to not break emacs syntax hilighting
* - mysql uses "DESCRIBE [<schemaname>].<tablename>", catching exceptionsMike Bayer2007-04-291-5/+18
| | | | | | if table doesnt exist, in order to determine if a table exists. this supports unicode table names as well as schema names. tested with MySQL5 but should work with 4.1 series as well. (#557)
* fixed casing of SET clauseMike Bayer2007-04-261-1/+1
|
* - support for SSL arguments given as inline within URL query string,Mike Bayer2007-04-221-3/+13
| | | | prefixed with "ssl_", courtesy terjeros@gmail.com.
* - Promoted mysql's dburl query string helper to util + fixedJason Kirtland2007-04-191-10/+8
| | | | | | - Coercing sqlite connect args provided in query string to their expected type (e.g. 'timeout' as float, fixes #544) - Coerce mysql's client_flag to int too
* - the dialects within sqlalchemy.databases become a setuptoolsMike Bayer2007-04-171-3/+5
| | | | | | entry points. loading the built-in database dialects works the same as always, but if none found will fall back to trying pkg_resources to load an external module [ticket:521]
* - got unicode schemas to work with postgresMike Bayer2007-04-151-8/+14
| | | | | - unicode schema with mysql slightly improved, still cant do has_table - got reflection of unicode schemas working with sqlite, pg, mysql
* for #516, moved the "disconnect check" step out of pool and back into ↵Mike Bayer2007-04-031-5/+2
| | | | | | base.py. dialects have is_disconnect() method now. simpler design which also puts control of the ultimate "execute" call back into the hands of the dialects.
* - merged the patch from #516 + fixesMike Bayer2007-04-021-14/+11
| | | | | | | | - improves the framework for auto-invalidation of connections that have lost their underlying database - the error catching/invalidate step is totally moved to the connection pool. - added better condition checking for do_rollback() and do_commit() including SQLError excepetion wrapping
* - merged the "execcontext" branch, refactors engine/dialect codepathsMike Bayer2007-04-021-29/+21
| | | | | | | | | | | | | | | | | | | | - much more functionality moved into ExecutionContext, which impacted the API used by dialects to some degree - ResultProxy and subclasses now designed sanely - merged patch for #522, Unicode subclasses String directly, MSNVarchar implements for MS-SQL, removed MSUnicode. - String moves its "VARCHAR"/"TEXT" switchy thing into "get_search_list()" function, which VARCHAR and CHAR can override to not return TEXT in any case (didnt do the latter yet) - implements server side cursors for postgres, unit tests, #514 - includes overhaul of dbapi import strategy #480, all dbapi importing happens in dialect method "dbapi()", is only called inside of create_engine() for default and threadlocal strategies. Dialect subclasses have a datamember "dbapi" referencing the loaded module which may be None. - added "mock" engine strategy, doesnt require DBAPI module and gives you a "Connecition" which just sends all executes to a callable. can be used to create string output of create_all()/drop_all().
* - added explicit MSTimeStamp type which takes effect when usingMike Bayer2007-03-221-1/+7
| | | | types.TIMESTAMP.
* - added db modules to genned docstringsMike Bayer2007-03-181-7/+2
| | | | | | | - had to tweak out latest MS-SQL module change. cant do ImportErrors right now until module importing is moved to the connection phase across all dialects. - took out "his" from url docstrings - postgres doesnt do an import *
* - added a catchall **kwargs to MSString, to help reflection ofMike Bayer2007-03-161-1/+1
| | | | obscure types (like "varchar() binary" in MS 4.0)
* migrated (most) docstrings to pep-257 format, docstring generator using ↵Mike Bayer2007-02-251-16/+40
| | | | | | straight <pre> + trim() func for now. applies most of [ticket:214], compliemnts of Lele Gaifax
* - added "schema" argument to all has_table() calls, only supported so far by PGMike Bayer2007-02-041-1/+1
| | | | - added basic unit test for PG reflection of tables in an alternate schema
* - more quoting fixes for [ticket:450]...quoting more aggressive (but still ↵Mike Bayer2007-02-041-2/+4
| | | | | | | | skips already-quoted literals) - got mysql to have "format" as default paramstyle even if mysql module not available, allows unit tests to pass in non-mysql system for [ticket:457]. all the dialects should be changed to pass in their usual paramstyle.
* - fix to reflection on older DB's that might return array() type forMike Bayer2007-01-251-1/+6
| | | | "show variables like" statements
* - mysql table create options work on a generic passthru now, i.e. Table(..., ↵Mike Bayer2007-01-201-5/+6
| | | | | | | mysql_engine='InnoDB', mysql_collate="latin1_german2_ci", mysql_auto_increment="5", mysql_<somearg>...), helps [ticket:418]
* - mysql is inconsistent with what kinds of quotes it uses in foreign keys ↵Mike Bayer2007-01-121-3/+3
| | | | | | during a SHOW CREATE TABLE, reflection updated to accomodate for all three styles [ticket:420]
* copyright updateMike Bayer2007-01-051-1/+1
|
* fixed the raise for mysql to re-raise the errorrel_0_3_3Mike Bayer2006-12-151-2/+2
|
* fix to the fix for [ticket:396] plus a unit testMike Bayer2006-12-151-3/+5
|
* - patch that makes MySQL rowcount work correctly! [ticket:396]Mike Bayer2006-12-131-1/+7
|
* - MySQL bool type fix: [ticket:307]Mike Bayer2006-12-091-0/+1
|
* - support for None as precision/length in numeric types for postgres, ↵Mike Bayer2006-12-091-1/+4
| | | | | | sqlite, mysql - postgres reflection fixes: [ticket:349] [ticket:382]
* - MySQL detects errors 2006 (server has gone away) and 2014Mike Bayer2006-12-081-0/+16
| | | | (commands out of sync) and invalidates the connection on which it occured.
* reflect from table.fullname for schema supportMike Bayer2006-11-131-2/+2
|
* - MySQL catches exception on "describe" and reports as NoSuchTableErrorMike Bayer2006-10-241-1/+4
|
* - ForeignKey(Constraint) supports "use_alter=True", to create/drop a foreign keyMike Bayer2006-10-151-0/+3
| | | | 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-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.