mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-14 12:30:24 +02:00
* Call UpdateServiceIndexDefs before Execute, to avoid problems with databases which do not allow processing multiple recordsets at a time (MS SQL, bug #13241)
git-svn-id: trunk@13090 -
This commit is contained in:
parent
8babc4920c
commit
ce55400037
@ -1219,6 +1219,11 @@ begin
|
|||||||
begin
|
begin
|
||||||
if not ReadFromFile then
|
if not ReadFromFile then
|
||||||
begin
|
begin
|
||||||
|
// Call UpdateServerIndexDefs before Execute, to avoid problems with connections
|
||||||
|
// which do not allow processing multiple recordsets at a time. (Microsoft
|
||||||
|
// calls this MARS, see bug 13241)
|
||||||
|
if DefaultFields and FUpdateable and FusePrimaryKeyAsKey then
|
||||||
|
UpdateServerIndexDefs;
|
||||||
Execute;
|
Execute;
|
||||||
// InternalInitFieldDef is only called after a prepare. i.e. not twice if
|
// InternalInitFieldDef is only called after a prepare. i.e. not twice if
|
||||||
// a dataset is opened - closed - opened.
|
// a dataset is opened - closed - opened.
|
||||||
@ -1231,7 +1236,6 @@ begin
|
|||||||
begin
|
begin
|
||||||
if FusePrimaryKeyAsKey then
|
if FusePrimaryKeyAsKey then
|
||||||
begin
|
begin
|
||||||
UpdateServerIndexDefs;
|
|
||||||
for tel := 0 to ServerIndexDefs.count-1 do
|
for tel := 0 to ServerIndexDefs.count-1 do
|
||||||
begin
|
begin
|
||||||
if ixPrimary in ServerIndexDefs[tel].options then
|
if ixPrimary in ServerIndexDefs[tel].options then
|
||||||
|
Loading…
Reference in New Issue
Block a user