TParadoxDataset: Add property PrimaryKeyFieldCount.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7101 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2019-08-08 12:22:07 +00:00
parent 0436c5f2ce
commit 7bf92d7867

View File

@ -170,6 +170,7 @@ type
FParser: TBufDatasetParser;
function GetEncrypted: Boolean;
function GetInputEncoding: String; inline;
function GetPrimaryKeyFieldCount: Integer;
function GetTargetEncoding: String; inline;
function GetVersion: String;
function IsStoredTargetEncoding: Boolean;
@ -216,6 +217,7 @@ type
function GetFieldData(Field: TField; Buffer: Pointer): Boolean; override;
procedure SetFieldData({%H-}Field: TField; {%H-}Buffer: Pointer); override;
property Encrypted: Boolean read GetEncrypted;
property PrimaryKeyFieldCount: Integer read GetPrimaryKeyFieldCount;
published
property TableName: TFileName read FFileName write SetFileName;
property TableLevel: String read GetVersion;
@ -484,6 +486,14 @@ begin
Result := FInputEncoding;
end;
function TParadoxDataset.GetPrimaryKeyFieldCount: Integer;
begin
if FHeader <> nil then
Result := FHeader^.primaryKeyFields
else
Result := 0;
end;
function TParadoxDataset.GetRecNo: Integer;
begin
Result := -1;