summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/dialects/mysql/oursql.py
Commit message (Collapse)AuthorAgeFilesLines
* Remove deprecated dialects and driversFederico Caselli2021-10-311-273/+0
| | | | | Fixes: #7258 Change-Id: I3577f665eca04f2632b69bcb090f0a4ec9271db9
* Replace all http:// links to https://Federico Caselli2021-07-041-2/+2
| | | | | | Also replace http://pypi.python.org/pypi with https://pypi.org/project Change-Id: I84b5005c39969a82140706472989f2a30b0c7685
* Default caching to opt-out for 3rd party dialectsMike Bayer2021-04-011-0/+1
| | | | | | | | | | | | | | | | | | | Added a new flag to the :class:`_engine.Dialect` class called :attr:`_engine.Dialect.supports_statement_cache`. This flag now needs to be present directly on a dialect class in order for SQLAlchemy's :ref:`query cache <sql_caching>` to take effect for that dialect. The rationale is based on discovered issues such as :ticket:`6173` revealing that dialects which hardcode literal values from the compiled statement, often the numerical parameters used for LIMIT / OFFSET, will not be compatible with caching until these dialects are revised to use the parameters present in the statement only. For third party dialects where this flag is not applied, the SQL logging will show the message "dialect does not support caching", indicating the dialect should seek to apply this flag once they have verified that no per-statement literal values are being rendered within the compilation phase. Fixes: #6184 Change-Id: I6fd5b5d94200458d4cb0e14f2f556dbc25e27e22
* happy new yearMike Bayer2021-01-041-1/+1
| | | | Change-Id: Ic5bb19ca8be3cb47c95a0d3315d84cb484bac47c
* Deprecate unsupported dialects and dbapiFederico Caselli2020-04-291-0/+10
| | | | | | | | | | | | | | | | | - Deprecate dialects firebird and sybase. - Deprecate DBAPI - mxODBC for mssql - oursql for mysql - pygresql and py-postgresql for postgresql - Removed adodbapi DBAPI for mssql Fixes: #5189 Change-Id: Id9025f4f4de7e97d65aacd0eb4b0c21beb9a67b5
* Deprecate plain string in execute and introduce `exec_driver_sql`Federico Caselli2020-03-211-1/+1
| | | | | | | | | | | | | | | Execution of literal sql string is deprecated in the :meth:`.Connection.execute` and a warning is raised when used stating that it will be coerced to :func:`.text` in a future release. To execute a raw sql string the new connection method :meth:`.Connection.exec_driver_sql` was added, that will retain the previous behavior, passing the string to the DBAPI driver unchanged. Usage of scalar or tuple positional parameters in :meth:`.Connection.execute` is also deprecated. Fixes: #4848 Fixes: #5178 Change-Id: I2830181054327996d594f7f0d59c157d477c3aa9
* happy new yearMike Bayer2020-01-011-1/+1
| | | | Change-Id: I08440dc25e40ea1ccea1778f6ee9e28a00808235
* Source base cleanupsMike Bayer2020-01-011-3/+3
| | | | | | | | | | | | | | | in trying to apply 2020 copyright to files, the pre-commit hooks complain about random file issues. - remove old corrections.py utility, this had something to do with repairing refs in the sphinx docs - run pre commit hooks on all files - formatting adjustments to work around code formatting collisions (long import lines that zimports can't rewrite correctly) Change-Id: I260744866f69e902eb93665c7c728ee94d3371a2
* Remove threadlocal engine strategy, engine strategies pool threadlocalMike Bayer2019-07-151-1/+1
| | | | | | | | | | | | The "threadlocal" execution strategy, deprecated in 1.3, has been removed for 1.4, as well as the concept of "engine strategies" and the ``Engine.contextual_connect`` method. The "strategy='mock'" keyword argument is still accepted for now with a deprecation warning; use :func:`.create_mock_engine` instead for this use case. Fixes: #4632 Change-Id: I8a351f9fa1f7dfa2a56eec1cd2d1a4b9d65765a2 (cherry picked from commit b368c49b44c5716d93c7428ab22b6761c6ca7cf5)
* Note DBAPIs and dialects that we don't supportMike Bayer2019-07-051-0/+6
| | | | | | | | | | | | | | Since we have strong CI for the DBAPIs and dialects that are actively supported, this indicates that those DBAPIs that aren't in CI are continuing to fall behind in support, to the point where we can not address issues that may arise. As such, the Sybase and Firebird dialects overall are moving into an explicit "not supported" zone where we would like to eventually remove them. Additionally, a pass is made through legacy MySQL and PostgreSQL DBAPI dialects as well as those which we aren't able to include in CI to note that these DBAPIs aren't actively supported by the project. Change-Id: I61f1515b97b741b7534b54e434e3e47065df7b5d
* Add deprecation warnings to all deprecated APIsMike Bayer2019-01-231-1/+1
| | | | | | | | | | | | | | | A large change throughout the library has ensured that all objects, parameters, and behaviors which have been noted as deprecated or legacy now emit ``DeprecationWarning`` warnings when invoked. As the Python 3 interpreter now defaults to displaying deprecation warnings, as well as that modern test suites based on tools like tox and pytest tend to display deprecation warnings, this change should make it easier to note what API features are obsolete. See the notes added to the changelog and migration notes for further details. Fixes: #4393 Change-Id: If0ea11a1fc24f9a8029352eeadfc49a7a54c0a1b
* happy new yearMike Bayer2019-01-111-1/+1
| | | | Change-Id: I6a71f4924d046cf306961c58dffccf21e9c03911
* Post black reformattingMike Bayer2019-01-061-3/+5
| | | | | | | | | | | | | Applied on top of a pure run of black -l 79 in I7eda77fed3d8e73df84b3651fd6cfcfe858d4dc9, this set of changes resolves all remaining flake8 conditions for those codes we have enabled in setup.cfg. Included are resolutions for all remaining flake8 issues including shadowed builtins, long lines, import order, unused imports, duplicate imports, and docstring issues. Change-Id: I4f72d3ba1380dd601610ff80b8fb06a2aff8b0fe
* Run black -l 79 against all source filesMike Bayer2019-01-061-51/+62
| | | | | | | | | | | | | | This is a straight reformat run using black as is, with no edits applied at all. The black run will format code consistently, however in some cases that are prevalent in SQLAlchemy code it produces too-long lines. The too-long lines will be resolved in the following commit that will resolve all remaining flake8 issues including shadowed builtins, long lines, import order, unused imports, duplicate imports, and docstring issues. Change-Id: I7eda77fed3d8e73df84b3651fd6cfcfe858d4dc9
* Get MySQL version info from @@versionMike Bayer2018-03-031-11/+0
| | | | | | | | | | | | | MySQL dialects now query the server version using ``SELECT @@version`` explicitly to the server to ensure we are getting the correct version information back. Proxy servers like MaxScale interfere with the value that is passed to the DBAPI's connection.server_version value so this is no longer reliable. Change-Id: Iafd39be8c9bf1982d58b34cc997ae1016ad6c48c Fixes: #4205 (cherry picked from commit 9ba77e8d3b682bff89fdab5e80271a96a52fe8c8) (cherry picked from commit 5c1ebbc3706c810f936d9e252ee5d16800e561ea)
* happy new yearMike Bayer2018-01-121-1/+1
| | | | Change-Id: I3ef36bfd0cb0ba62b3123c8cf92370a43156cf8f
* Support python3.6Mike Bayer2017-01-131-1/+1
| | | | | | | | | | | Corrects some warnings and adds tox config. Adds DeprecationWarning to the error category. Large sweep for string literals w/ backslashes as this is common in docstrings Co-authored-by: Andrii Soldatenko Fixes: #3886 Change-Id: Ia7c838dfbbe70b262622ed0803d581edc736e085 Pull-request: https://github.com/zzzeek/sqlalchemy/pull/337
* update for 2017 copyrightMike Bayer2017-01-041-1/+1
| | | | Change-Id: I4e8c2aa8fe817bb2af8707410fa0201f938781de
* - happy new yearMike Bayer2016-01-291-1/+1
|
* - more updates to the unicode mess to frame this inMike Bayer2015-03-221-22/+2
| | | | as up-to-date recommendations as possible
* some doc defensesMike Bayer2015-03-211-0/+3
|
* - reorganize MySQL docs re: unicode, other cleanup and updatesMike Bayer2015-03-201-0/+5
|
* - copyright 2015Mike Bayer2015-03-101-1/+1
|
* - apply pep8 formatting to sqlalchemy/sql, sqlalchemy/util, sqlalchemy/dialects,Brian Jarrett2014-07-201-9/+13
| | | | sqlalchemy/orm, sqlalchemy/event, sqlalchemy/testing
* - break up the <authors> copyright comment as part of a passMike Bayer2014-07-091-1/+2
| | | | to get all flake8 passing
* - happy new yearMike Bayer2014-01-051-1/+1
|
* plugging awayMike Bayer2013-04-271-11/+9
|
* - the raw 2to3 runMike Bayer2013-04-271-8/+9
| | | | - went through examples/ and cleaned out excess list() calls
* happy new year (see #2645)Diana Clarke2013-01-011-1/+1
|
* kill me now, pep8 pass, so closeDiana Clarke2012-11-201-36/+40
|
* just a pep8 passDiana Clarke2012-11-201-2/+0
|
* juts a 'expected 2 blank lines' pep8 passDiana Clarke2012-11-191-0/+1
|
* - rework the sphinx customizations into distinct modulesMike Bayer2012-10-191-14/+6
| | | | | | | - build a new Sphinx extension that allows dialect info to be entered as directives which is then rendered consistently throughout all dialect/dbapi sections - break out the "empty_strings" requirement for oracle test
* - move out maxdbMike Bayer2012-10-181-0/+3
| | | | | | - begin consolidating docs for dialects to be more self contained - add a separate section for "external" dialects - not sure how we're going to go with this yet.
* - [feature] Added "raise_on_warnings" flag to OurSQLMike Bayer2012-10-101-0/+1
| | | | dialect. [ticket:2523]
* more import cleanupsMike Bayer2012-08-071-6/+2
|
* -whitespace bonanza, contdMike Bayer2012-07-281-5/+5
|
* happy new yearMike Bayer2012-01-041-1/+1
|
* marathon doc updating session including a rewrite of unicode paragraphsMike Bayer2011-12-041-2/+2
|
* - Fixed OurSQL dialect to use ansi-neutralMike Bayer2011-07-241-6/+7
| | | | | quote symbol "'" for XA commands instead of '"'. [ticket:2186]. Also in 0.6.9.
* - assume in py3k that description encoding is None unless the dialect reallyMike Bayer2011-04-081-2/+0
| | | | | overrides it - psycopg2 + 3k supports unicode statements...
* - oursql dialect accepts the same "ssl" arguments inMike Bayer2011-02-101-0/+10
| | | | create_engine() as that of MySQLdb. [ticket:2047]
* - add connection and cursor to is_disconnect(). We aren't using it yet,Mike Bayer2011-02-091-1/+1
| | | | | | | | | | | | | | | but we'd like to. Most DBAPIs don't give us anything we can do with it. Some research was done on psycopg2 and it still seems like they give us no adequate method (tried connection.closed, cursor.closed, connection.status). mxodbc claims their .closed attribute will work (but I am skeptical). - remove beahvior in pool that auto-invalidated a connection when the cursor failed to create. That's not the pool's job. we need the conn for the error logic. Can't get any tests to fail, curious why that behavior was there, guess we'll find out (or not). - add support for psycopg2 version detection. even though we have no use for it yet... - adjust one of the reconnect tests to work with oracle's horrendously slow connect speed
* - whitespace removal bonanzaMike Bayer2011-01-021-13/+13
|
* - clean up copyright, update for 2011, stamp every file withMike Bayer2011-01-021-0/+6
| | | | | a consistent tag - AUTHORS file
* - _extract_error_code now expects the raw DBAPI error in all casesMike Bayer2010-07-131-4/+1
| | | | | for all four MySQL dialects. has_table() passes in the "orig" from the SQLAlchemy exception. continuing of [ticket:1848]
* documentation updatesMike Bayer2010-03-281-0/+11
|
* removed all dialect table_names() methods and standardizedMike Bayer2010-03-191-2/+2
| | | | on get_table_names(). [ticket:1739]
* - moved most Decimal bind/result handling into types.py, out of sqlite, ↵Mike Bayer2010-03-181-10/+4
| | | | | | | mysql dialects. - added an explicit test for [ticket:1216] - some questions remain about MSSQL - would like to simplify/remove bind handling for numerics
* Changed OurSQL to use supports_unicode_binds and supports_unicode_statements.Michael Trier2010-03-161-2/+0
|