Opened 8 years ago

Closed 8 years ago

#27062 closed New feature (fixed)

Add support for for_update for MSSQL

Reported by: denisenkom Owned by: nobody
Component: Database layer (models, ORM) Version: 1.10
Severity: Normal Keywords: mssql for_update database orm
Cc: denisenkom@… Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Currently SQL generator adds FOR UPDATE clause at the end of the query but MSSQL requires it to be after FROM clause. SQL generator should be updated to allow for MSSQL syntax.

Patch: https://github.com/django/django/pull/5667

Change History (5)

comment:1 by denisenkom, 8 years ago

Because of this there is no way to add MSSQL support without monkey patching entire as_sql method, see: https://github.com/denisenkom/django-sqlserver/blob/master/sqlserver/compiler.py#L24

comment:2 by Tim Graham, 8 years ago

Patch needs improvement: set
Triage Stage: UnreviewedAccepted

Branch needs a rebase.

comment:3 by Tim Graham, 8 years ago

Patch needs improvement: unset

comment:4 by Tim Graham, 8 years ago

Triage Stage: AcceptedReady for checkin

comment:5 by Tim Graham <timograham@…>, 8 years ago

Resolution: fixed
Status: newclosed

In bae64dd0:

Fixed #27062 -- Eased implementing select_for_update() on MSSQL.

Note: See TracTickets for help on using tickets.
Back to Top