Oracle Sequences & Blob changes

Code samples and contributions from users for ZeosLib's DBOs of version 6.x

Moderators: gto, cipto_kh, EgonHugeist, mdaems

Post Reply
martinrame
Junior Boarder
Junior Boarder
Posts: 25
Joined: 24.10.2006, 18:29
Location: Córdoba, Argentina
Contact:

Oracle Sequences & Blob changes

Post by martinrame »

In the file ZdbcOracle.pas, the CreateSequence method isn't included.

To include it, just add that method to the TZOracleConnection class with this code:

TZOracleConnection = ...
...
public
function CreateSequence(const Sequence: string; BlockSize: Integer):
IZSequence; override;
...

and in the implementation section:


function TZOracleConnection.CreateSequence(const Sequence: string; BlockSize: Integer): IZSequence;
begin
Result := TZOracleSequence.Create(Self, Sequence, BlockSize);
end;

The second file to change is ZDbcOracleResultSet.pas, method procedure TZOracleResultSet.Open. This change correct a bug related to blob fields:

Replace the contents of SQLT_BLOB with:

procedure TZOracleResultSet.Open;
...
SQLT_BLOB:
begin
CurrentVar.ColType := stBinaryStream;
CurrentVar.TypeCode := CurrentVar.DataType;
end;
...
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

Hi Martinrame,

I hope you did test it well. There was an other post concerning CLOBs indicating a similar solution, so I changed both.

This changes has been committed to testing branch in revision 157.

If you use SVN, can you check this version?

If not, this patch will be open until somebody else confirms the effectiveness or until you can test after next release.

Mark
martinrame
Junior Boarder
Junior Boarder
Posts: 25
Joined: 24.10.2006, 18:29
Location: Córdoba, Argentina
Contact:

Post by martinrame »

The Blob related change is the same propossed by another user.

I joined the Blob and Sequences changes into this post because both affect the Oracle driver.

With respect to your testing concern, i did't made an exhaustive testing, just with a couple of scenarios. I'll get the revision 157 to look what happens.

Thanks for your promptly action.

Sincerely,
Leonardo M. Ramé
http://leonardorame.blogspot.com
martinrame
Junior Boarder
Junior Boarder
Posts: 25
Joined: 24.10.2006, 18:29
Location: Córdoba, Argentina
Contact:

Post by martinrame »

Can you tell me the url of the svn "testing" branch? I only can see the Trunk.
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

Almost same URL svn://www.firmos.at/zeos/branches/testing

If you only see trunk in TortoiseSVN Repo Browser : click on the + or - symbol of the project root.

See in tutorials forum for more details about different branches/releases ...

Mark
martinrame
Junior Boarder
Junior Boarder
Posts: 25
Joined: 24.10.2006, 18:29
Location: Córdoba, Argentina
Contact:

Post by martinrame »

Thanks, i was using svn://www.firmos.at/zeos/testing (without "branches").
Post Reply