Ver código fonte

* Merging revisions 45202 from trunk:
------------------------------------------------------------------------
r45202 | michael | 2020-05-01 14:16:47 +0200 (Fri, 01 May 2020) | 1 line

* Always initialize autoincvalue in createdataset
------------------------------------------------------------------------

git-svn-id: branches/fixes_3_2@45203 -

michael 5 anos atrás
pai
commit
0c3f0c5682
1 arquivos alterados com 2 adições e 1 exclusões
  1. 2 1
      packages/fcl-db/src/base/bufdataset.pas

+ 2 - 1
packages/fcl-db/src/base/bufdataset.pas

@@ -3542,8 +3542,9 @@ begin
       end
     else
       raise Exception.Create(SErrNoFieldsDefined);
-    FAutoIncValue:=1;
     end;
+  if FAutoIncValue<0 then  
+    FAutoIncValue:=1;
   // When a FileName is set, do not read from this file; we want empty dataset
   AStoreFileName:=FFileName;
   FFileName := '';