summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/dialects/mssql/base.py
Commit message (Collapse)AuthorAgeFilesLines
* Fix MSSQL dialects visit_drop_index to use the correct DDLdonkopotamus2013-12-051-5/+3
|
* - Fixed bug in default compiler plus those of postgresql, mysql, andMike Bayer2013-10-121-1/+1
| | | | | | | | mssql to ensure that any literal SQL expression values are rendered directly as literals, instead of as bound parameters, within a CREATE INDEX statement. [ticket:2742] - don't need expression_as_ddl(); literal_binds and include_table take care of this functionality.
* - A rework to the way that "quoted" identifiers are handled, in thatMike Bayer2013-08-271-2/+2
| | | | | | | | | | | | | | | | instead of relying upon various ``quote=True`` flags being passed around, these flags are converted into rich string objects with quoting information included at the point at which they are passed to common schema constructs like :class:`.Table`, :class:`.Column`, etc. This solves the issue of various methods that don't correctly honor the "quote" flag such as :meth:`.Engine.has_table` and related methods. The :class:`.quoted_name` object is a string subclass that can also be used explicitly if needed; the object will hold onto the quoting preferences passed and will also bypass the "name normalization" performed by dialects that standardize on uppercase symbols, such as Oracle, Firebird and DB2. The upshot is that the "uppercase" backends can now work with force-quoted names, such as lowercase-quoted names and new reserved words. [ticket:2812]
* - we dont actually need this unicode cast, on py3k + linux it seems theMike Bayer2013-07-091-7/+1
| | | | | has_table issues are OK. On OSX forget it. - still some issues with PY3k + pyodbc + decimal values it doesn't expect, not sure
* - some tweaks to try to help out mssql+pyodbc support a bit, py3k is reallyMike Bayer2013-06-031-0/+1
| | | | not happening too well (I need to stick with linux + freetds 0.91, I know)
* merge defaultMike Bayer2013-05-151-0/+6
|\
| * Regression from this ticket caused the unsupported keywordMike Bayer2013-05-151-0/+6
| | | | | | | | | | | | "true" to render, added logic to convert this to 1/0 for SQL server. [ticket:2682]
* | plugging awayMike Bayer2013-04-271-3/+3
| |
* | work through dialectsMike Bayer2013-04-271-4/+4
| |
* | - the raw 2to3 runMike Bayer2013-04-271-10/+10
|/ | | | - went through examples/ and cleaned out excess list() calls
* - replace mssql_ordering with generalized #695 solutionMike Bayer2013-01-201-10/+52
| | | | - documentation for mssql index options plus changelog and fixes
* Merged in dharland/sqlalchemy (pull request #35)Mike Bayer2013-01-201-0/+37
|\ | | | | | | Add extra mssql dialect options to Index
| * Add mssql_include option for mssql dialectDerek Harland2013-01-141-0/+10
| |
| * Add mssql_ordering option for mssql dialectDerek Harland2013-01-141-3/+10
| |
| * Add mssql_clustered option for mssql dialectDerek Harland2013-01-141-0/+20
| |
* | :class:`.Index` now supports arbitrary SQL expressions and/orMike Bayer2013-01-161-3/+2
|/ | | | | | | | functions, in addition to straight columns. Common modifiers include using ``somecolumn.desc()`` for a descending index and ``func.lower(somecolumn)`` for a case-insensitive index, depending on the capabilities of the target backend. [ticket:695]
* - changelog for pullreq 32Mike Bayer2013-01-121-124/+10
| | | | | | | | | | | - Fixed a regression whereby the "collation" parameter of the character types CHAR, NCHAR, etc. stopped working, as "collation" is now supported by the base string types. The TEXT, NCHAR, CHAR, VARCHAR types within the MSSQL dialect are now synonyms for the base types. - move out the type rendering tests into DB-agnostic tests and remove some of the old "create" statements. tests here are still very disorganized.
* Merged in dharland/sqlalchemy (pull request #32: Allow the MSSQL dialect to ↵Mike Bayer2013-01-121-12/+11
|\ | | | | | | support identity columns that are not part of the primary key)
| * MSSQL Dialect should set sequence columns to be non nullDerek Harland2012-12-041-1/+2
| |
| * Allow the MSSQL dialect to support identity columns that are not part of the ↵Derek Harland2012-12-041-11/+9
| | | | | | | | primary key
* | happy new year (see #2645)Diana Clarke2013-01-011-1/+1
|/
* kill me now, pep8 pass, so closeDiana Clarke2012-11-201-40/+36
|
* just a pep8 passDiana Clarke2012-11-201-2/+1
|
* juts a 'expected 2 blank lines' pep8 passDiana Clarke2012-11-191-0/+27
|
* Fixed bug whereby using "key" with ColumnMike Bayer2012-11-131-2/+1
| | | | | | | | in conjunction with "schema" for the owning Table would fail to locate result rows due to the MSSQL dialect's "schema rendering" logic's failure to take .key into account. Also in 0.7.10. [ticket:2607]
* Support for reflection of the "name" of primary keyMike Bayer2012-11-101-2/+5
| | | | constraints added, courtesy Dave Moore. mssql [ticket:2600]
* - rework the sphinx customizations into distinct modulesMike Bayer2012-10-191-1/+3
| | | | | | | - 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-4/+0
| | | | | | - 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.
* mssql: - [bug] Fixed bug where reflection of primary key constraintMike Bayer2012-09-301-0/+1
| | | | | | | would double up columns if the same constraint/table existed in multiple schemas. - force returns_rows to False for inserts where we know rows shouldnt be returned; allows post_exec() to use the cursor without issue
* - [bug] Fixed compiler bug whereby using a correlatedMike Bayer2012-09-301-4/+4
| | | | | | | subquery within an ORDER BY would fail to render correctly if the stament also used LIMIT/OFFSET, due to mis-rendering within the ROW_NUMBER() OVER clause. Fix courtesy sayap [ticket:2538]
* - fixes for mxODBC, some pyodbcMike Bayer2012-09-021-4/+1
| | | | | | - enhancements to test suite including ability to set up a testing engine for a whole test class, fixes to how noseplugin sets up/tears down per-class context
* - get all tests within -w engine + pyodbc:mssql on windows to passMike Bayer2012-09-011-5/+4
|
* - [bug] Fixed cextension bug whereby theMike Bayer2012-08-221-7/+7
| | | | | | | | | | | | | | | | | | | "ambiguous column error" would fail to function properly if the given index were a Column object and not a string. Note there are still some column-targeting issues here which are fixed in 0.8. [ticket:2553] - find more cases where column targeting is being inaccurate, add more information to result_map to better differentiate "ambiguous" results from "present" or "not present". In particular, result_map is sensitive to dupes, even though no error is raised; the conflicting columns are added to the "obj" member of the tuple so that the two are both directly accessible in the result proxy - handwringing over the damn "name fallback" thing in results. can't really make it perfect yet - fix up oracle returning clause. not sure why its guarding against labels, remove that for now and see what the bot says.
* - [feature] To complement [ticket:2547], typesMike Bayer2012-08-171-20/+11
| | | | | | | | | | | | | | | | can now provide "bind expressions" and "column expressions" which allow compile-time injection of SQL expressions into statements on a per-column or per-bind level. This is to suit the use case of a type which needs to augment bind- and result- behavior at the SQL level, as opposed to in the Python level. Allows for schemes like transparent encryption/ decryption, usage of Postgis functions, etc. [ticket:1534] - update postgis example fully. - still need to repair the result map propagation here to be transparent for cases like "labeled column".
* - fix concat() operator, testsMike Bayer2012-08-141-4/+4
| | | | | | | | - [feature] Custom unary operators can now be used by combining operators.custom_op() with UnaryExpression(). - clean up the operator dispatch system and make it more consistent. This does change the compiler contract for custom ops.
* - [bug] Fixed compiler bug whereby a givenMike Bayer2012-08-121-4/+5
| | | | | | select() would be modified if it had an "offset" attribute, causing the construct to not compile correctly a second time. [ticket:2545]
* - [feature] SQL Server dialect can be givenMike Bayer2012-08-071-71/+86
| | | | | | | | | | | database-qualified schema names, i.e. "schema='mydatabase.dbo'"; reflection operations will detect this, split the schema among the "." to get the owner separately, and emit a "USE mydatabase" statement before reflecting targets within the "dbo" owner; the existing database returned from DB_NAME() is then restored.
* - more import cleanup for MSSQLMike Bayer2012-08-071-11/+11
|
* - another import fixMike Bayer2012-08-071-1/+1
|
* - fixesMike Bayer2012-08-071-6/+7
|
* trailing whitespace bonanzaMike Bayer2012-07-281-64/+64
|
* - a big renaming of all the _Underscore classes to haveMike Bayer2012-07-171-4/+4
| | | | | | plain names. The old names are still defined for backwards compatibility. - _BindParamClause renamed to BindParameter
* - [feature] Added "MATCH" clause to ForeignKey,Mike Bayer2012-06-211-2/+2
| | | | | | | | | | | | | | ForeignKeyConstraint, courtesy Ryan Kelly. [ticket:2502] - [feature] Added support for DELETE and UPDATE from an alias of a table, which would assumedly be related to itself elsewhere in the query, courtesy Ryan Kelly. [ticket:2507] - [feature] Added support for the Postgresql ONLY keyword, which can appear corresponding to a table in a SELECT, UPDATE, or DELETE statement. The phrase is established using with_hint(). Courtesy Ryan Kelly [ticket:2506]
* - [feature] Inspector.get_primary_keys() isMike Bayer2012-04-241-2/+2
|\ | | | | | | | | | | | | | | deprecated; use Inspector.get_pk_constraint(). Courtesy Diana Clarke. [ticket:2422] - restored default get_primary_keys()/get_pk_constraint() wrapper to help maintain compatibility with third party dialects created against 0.6 or 0.7
| * deprecate inspector.get_primary_keys() in favor of inspector.get_pk_constraint()Diana Clarke2012-04-021-2/+2
| | | | | | | | - see #2422
* | - [feature] The behavior of column targetingMike Bayer2012-04-241-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | in result sets is now case sensitive by default. SQLAlchemy for many years would run a case-insensitive conversion on these values, probably to alleviate early case sensitivity issues with dialects like Oracle and Firebird. These issues have been more cleanly solved in more modern versions so the performance hit of calling lower() on identifiers is removed. The case insensitive comparisons can be re-enabled by setting "case_insensitive=False" on create_engine(). [ticket:2423]
* | - [bug] removed legacy behavior wherebyMike Bayer2012-04-241-48/+1
| | | | | | | | | | | | | | | | | | | | a column comparison to a scalar SELECT via == would coerce to an IN with the SQL server dialect. This is implicit behavior which fails in other scenarios so is removed. Code which relies on this needs to be modified to use column.in_(select) explicitly. [ticket:2277]
* | - [bug] UPDATE..FROM syntax with SQL ServerMike Bayer2012-04-181-0/+16
| | | | | | | | | | | | | | | | | | | | requires that the updated table be present in the FROM clause when an alias of that table is also present in the FROM clause. The updated table is now always present in the FROM, when FROM is present in the first place. Courtesy sayap. [ticket:2468]
* | - [bug] Repaired the use_scope_identityMike Bayer2012-04-051-10/+15
|/ | | | | | | | | | create_engine() flag when using the pyodbc dialect. Previously this flag would be ignored if set to False. When set to False, you'll get "SELECT @@identity" after each INSERT to get at the last inserted ID, for those tables which have "implicit_returning" set to False.
* typoes in lib/sqlalchemy/dialectsDiana Clarke2012-03-171-2/+2
|