mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-15 10:51:08 +02:00
* Ptahc from Joost van der Sluis
- moved IsCursorOpen from TSQLQuery to tbufdataset - moved SetFieldData from TSQLQuery to TBufDataset - very first start for support of cached updates
This commit is contained in:
parent
eb356809e8
commit
085470531e
@ -130,7 +130,6 @@ type
|
|||||||
TSQLQuery = class (Tbufdataset)
|
TSQLQuery = class (Tbufdataset)
|
||||||
private
|
private
|
||||||
FCursor : TSQLHandle;
|
FCursor : TSQLHandle;
|
||||||
FOpen : Boolean;
|
|
||||||
FSQL : TStrings;
|
FSQL : TStrings;
|
||||||
FIsEOF : boolean;
|
FIsEOF : boolean;
|
||||||
FLoadingFieldDefs : boolean;
|
FLoadingFieldDefs : boolean;
|
||||||
@ -154,8 +153,7 @@ type
|
|||||||
procedure InternalInitFieldDefs; override;
|
procedure InternalInitFieldDefs; override;
|
||||||
procedure InternalOpen; override;
|
procedure InternalOpen; override;
|
||||||
procedure InternalPost; override;
|
procedure InternalPost; override;
|
||||||
function IsCursorOpen: Boolean; override;
|
function GetCanModify: Boolean; override;
|
||||||
procedure SetFieldData(Field: TField; Buffer: Pointer); override;
|
|
||||||
Function GetSQLStatementType(SQL : String) : TStatementType; virtual;
|
Function GetSQLStatementType(SQL : String) : TStatementType; virtual;
|
||||||
public
|
public
|
||||||
procedure ExecSQL; virtual;
|
procedure ExecSQL; virtual;
|
||||||
@ -415,7 +413,6 @@ begin
|
|||||||
DestroyFields;
|
DestroyFields;
|
||||||
FIsEOF := False;
|
FIsEOF := False;
|
||||||
// FRecordSize := 0;
|
// FRecordSize := 0;
|
||||||
FOpen:=False;
|
|
||||||
inherited internalclose;
|
inherited internalclose;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -451,7 +448,6 @@ begin
|
|||||||
if Fcursor.StatementType in [stSelect] then
|
if Fcursor.StatementType in [stSelect] then
|
||||||
begin
|
begin
|
||||||
Execute;
|
Execute;
|
||||||
FOpen:=True;
|
|
||||||
InternalInitFieldDefs;
|
InternalInitFieldDefs;
|
||||||
if DefaultFields then
|
if DefaultFields then
|
||||||
CreateFields;
|
CreateFields;
|
||||||
@ -470,15 +466,6 @@ begin
|
|||||||
// not implemented - sql dataset
|
// not implemented - sql dataset
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TSQLQuery.IsCursorOpen: Boolean;
|
|
||||||
begin
|
|
||||||
Result := FOpen;
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure TSQLQuery.SetFieldData(Field: TField; Buffer: Pointer);
|
|
||||||
begin
|
|
||||||
end;
|
|
||||||
|
|
||||||
// public part
|
// public part
|
||||||
|
|
||||||
procedure TSQLQuery.ExecSQL;
|
procedure TSQLQuery.ExecSQL;
|
||||||
@ -554,11 +541,23 @@ begin
|
|||||||
Exit(t);
|
Exit(t);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Function TSQLQuery.GetCanModify: Boolean;
|
||||||
|
|
||||||
|
begin
|
||||||
|
Result:= False;
|
||||||
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.8 2004-12-04 22:43:38 michael
|
Revision 1.9 2004-12-13 19:22:16 michael
|
||||||
|
* Ptahc from Joost van der Sluis
|
||||||
|
- moved IsCursorOpen from TSQLQuery to tbufdataset
|
||||||
|
- moved SetFieldData from TSQLQuery to TBufDataset
|
||||||
|
- very first start for support of cached updates
|
||||||
|
|
||||||
|
Revision 1.8 2004/12/04 22:43:38 michael
|
||||||
* Patch from Joost van der Sluis
|
* Patch from Joost van der Sluis
|
||||||
- replaced checkactive in commit and rollback for 'if active'
|
- replaced checkactive in commit and rollback for 'if active'
|
||||||
- fixed a warning
|
- fixed a warning
|
||||||
|
Loading…
Reference in New Issue
Block a user