79 |
|
FTransactionIntf: Firebird.ITransaction; |
80 |
|
FFirebird30ClientAPI: TFB30ClientAPI; |
81 |
|
FSDL: ISDL; |
82 |
+ |
procedure GenerateSDL; |
83 |
|
protected |
84 |
|
procedure AllocateBuffer; override; |
85 |
|
procedure InternalGetSlice; override; |
87 |
|
public |
88 |
|
constructor Create(aAttachment: TFB30Attachment; aTransaction: TFB30Transaction; aField: IArrayMetaData); overload; |
89 |
|
constructor Create(aAttachment: TFB30Attachment; aTransaction: TFB30Transaction; aField: IArrayMetaData; ArrayID: TISC_QUAD); overload; |
90 |
< |
end; |
90 |
> |
end; |
91 |
|
|
92 |
|
TSDLItem = class(TParamBlockItem,ISDLItem); |
93 |
|
|
195 |
|
|
196 |
|
{ TFB30Array } |
197 |
|
|
198 |
< |
procedure TFB30Array.AllocateBuffer; |
198 |
> |
procedure TFB30Array.GenerateSDL; |
199 |
|
|
200 |
|
procedure AddVarInteger(aValue: integer); |
201 |
|
begin |
211 |
|
var i: integer; |
212 |
|
SDLItem: ISDLItem; |
213 |
|
begin |
213 |
– |
inherited AllocateBuffer; |
214 |
– |
{Now set up the SDL} |
215 |
– |
|
214 |
|
FSDL := TSDLBlock.Create(FFirebird30ClientAPI); |
215 |
|
with GetArrayDesc^ do |
216 |
|
{The following is based on gen_SDL from Firebird src/dsql/array.cpp} |
220 |
|
|
221 |
|
case array_desc_dtype of |
222 |
|
blr_short,blr_long, |
223 |
< |
blr_int64,blr_quad: |
224 |
< |
SDLItem.addShortInt(byte(array_desc_scale)); |
223 |
> |
blr_int64,blr_quad, |
224 |
> |
blr_int128: |
225 |
> |
SDLItem.AddShortInt(array_desc_scale); |
226 |
|
|
227 |
|
blr_text,blr_cstring, blr_varying: |
228 |
|
SDLItem.addShortInteger(array_desc_length); |
257 |
|
end; |
258 |
|
end; |
259 |
|
|
260 |
+ |
procedure TFB30Array.AllocateBuffer; |
261 |
+ |
|
262 |
+ |
begin |
263 |
+ |
inherited AllocateBuffer; |
264 |
+ |
{Now set up the SDL} |
265 |
+ |
GenerateSDL; |
266 |
+ |
end; |
267 |
+ |
|
268 |
|
procedure TFB30Array.InternalGetSlice; |
269 |
|
begin |
270 |
|
with FFirebird30ClientAPI do |