32 |
|
{************************************************************************} |
33 |
|
|
34 |
|
unit IBHeader; |
35 |
+ |
{$IFDEF MSWINDOWS} |
36 |
+ |
{$DEFINE WINDOWS} |
37 |
+ |
{$ENDIF} |
38 |
|
|
39 |
|
{$IFDEF FPC} |
40 |
< |
{$mode objfpc}{$H+} |
40 |
> |
{$mode delphi} |
41 |
> |
{$codepage UTF8} |
42 |
|
{$ENDIF} |
43 |
|
|
44 |
|
interface |
48 |
|
|
49 |
|
|
50 |
|
const |
47 |
– |
ISC_TRUE = 1; |
48 |
– |
ISC_FALSE = 0; |
51 |
|
DSQL_close = 1; |
52 |
|
DSQL_drop = 2; |
53 |
|
|
99 |
|
TIME_SECONDS_PRECISION_SCALE = -4; |
100 |
|
|
101 |
|
type |
102 |
+ |
PPByte = ^PByte; |
103 |
|
ISC_DATE = Long; |
104 |
|
PISC_DATE = ^ISC_DATE; |
105 |
|
ISC_TIME = ULong; |
117 |
|
PISC_ARRAY_BOUND = ^TISC_ARRAY_BOUND; |
118 |
|
TISC_ARRAY_DESC = record |
119 |
|
array_desc_dtype : UChar; |
120 |
< |
array_desc_scale : Char; |
120 |
> |
array_desc_scale : ShortInt; |
121 |
|
array_desc_length : UShort; |
122 |
< |
array_desc_field_name : array[0..31] of Char; |
123 |
< |
array_desc_relation_name : array[0..31] of Char; |
122 |
> |
array_desc_field_name : array[0..31] of AnsiChar; |
123 |
> |
array_desc_relation_name : array[0..31] of AnsiChar; |
124 |
|
array_desc_dimensions : Short; |
125 |
|
array_desc_flags : Short; |
126 |
|
array_desc_bounds : array[0..15] of TISC_ARRAY_BOUND; |
131 |
|
blob_desc_subtype : Short; |
132 |
|
blob_desc_charset : Short; |
133 |
|
blob_desc_segment_size : Short; |
134 |
< |
blob_desc_field_name : array[0..31] of Char; |
135 |
< |
blob_desc_relation_name : array[0..31] of Char; |
134 |
> |
blob_desc_field_name : array[0..31] of AnsiChar; |
135 |
> |
blob_desc_relation_name : array[0..31] of AnsiChar; |
136 |
|
end; // TISC_BLOB_DESC |
137 |
|
PISC_BLOB_DESC = ^TISC_BLOB_DESC; |
138 |
|
|
152 |
|
ctl_segment_length : UShort; (** Length of current segment **) |
153 |
|
ctl_bpb_length : UShort; (** Length of blob parameter **) |
154 |
|
(** block **) |
155 |
< |
ctl_bpb : PChar; (** Address of blob parameter **) |
155 |
> |
ctl_bpb : PByte; (** Address of blob parameter **) |
156 |
|
(** block **) |
157 |
|
ctl_buffer : PUChar; (** Address of segment buffer **) |
158 |
|
ctl_max_segment : ISC_LONG; (** Length of longest segment **) |
166 |
|
(*****************************) |
167 |
|
TBSTREAM = record |
168 |
|
bstr_blob : PVoid; (** Blob handle **) |
169 |
< |
bstr_buffer : PChar; (** Address of buffer **) |
170 |
< |
bstr_ptr : PChar; (** Next character **) |
169 |
> |
bstr_buffer : PByte; (** Address of buffer **) |
170 |
> |
bstr_ptr : PByte; (** Next character **) |
171 |
|
bstr_length : Short; (** Length of buffer **) |
172 |
|
bstr_cnt : Short; (** Characters in buffer **) |
173 |
|
bstr_mode : Char; (** (mode) ? OUTPUT : INPUT **) |
181 |
|
TSQLVAR = record |
182 |
|
sqltype : Short; |
183 |
|
sqllen : Short; |
184 |
< |
sqldata : PChar; |
184 |
> |
sqldata : PByte; |
185 |
|
sqlind : PShort; |
186 |
|
sqlname_length : Short; |
187 |
< |
sqlname : array[0..29] of Char; |
187 |
> |
sqlname : array[0..29] of AnsiChar; |
188 |
|
end; |
189 |
|
PSQLVAR = ^TSQLVAR; |
190 |
|
|
191 |
|
TSQLDA = record |
192 |
< |
sqldaid : array[0..7] of Char; |
192 |
> |
sqldaid : array[0..7] of AnsiChar; |
193 |
|
sqldabc : ISC_LONG; |
194 |
|
sqln : Short; |
195 |
|
sqld : Short; |
207 |
|
sqlsubtype : Short; (** datatype subtype - BLOBs **) |
208 |
|
(** & text types only **) |
209 |
|
sqllen : Short; (** length of data area **) |
210 |
< |
sqldata : PChar; (** address of data **) |
210 |
> |
sqldata : PByte; (** address of data **) |
211 |
|
sqlind : PShort; (** address of indicator **) |
212 |
|
(** variable **) |
213 |
|
sqlname_length : Short; (** length of sqlname field **) |
214 |
|
(** name of field, name length + space for NULL **) |
215 |
< |
sqlname : array[0..31] of Char; |
215 |
> |
sqlname : array[0..31] of AnsiChar; |
216 |
|
relname_length : Short; (** length of relation name **) |
217 |
|
(** field's relation name + space for NULL **) |
218 |
< |
relname : array[0..31] of Char; |
218 |
> |
relname : array[0..31] of AnsiChar; |
219 |
|
ownname_length : Short; (** length of owner name **) |
220 |
|
(** relation's owner name + space for NULL **) |
221 |
< |
ownname : array[0..31] of Char; |
221 |
> |
ownname : array[0..31] of AnsiChar; |
222 |
|
aliasname_length : Short; (** length of alias name **) |
223 |
|
(** relation's alias name + space for NULL **) |
224 |
< |
aliasname : array[0..31] of Char; |
224 |
> |
aliasname : array[0..31] of AnsiChar; |
225 |
|
end; // TXSQLVAR |
226 |
|
PXSQLVAR = ^TXSQLVAR; |
227 |
|
|
228 |
|
TXSQLDA = record |
229 |
|
version : Short; (** version of this XSQLDA **) |
230 |
|
(** XSQLDA name field **) |
231 |
< |
sqldaid : array[0..7] of Char; |
231 |
> |
sqldaid : array[0..7] of AnsiChar; |
232 |
|
sqldabc : ISC_LONG; (** length in bytes of SQLDA **) |
233 |
|
sqln : Short; (** number of fields allocated **) |
234 |
|
sqld : Short; (** actual number of fields **) |
244 |
|
TISC_START_TRANS = record |
245 |
|
db_handle : PISC_DB_HANDLE; |
246 |
|
tpb_length : UShort; |
247 |
< |
tpb_address : PChar; |
247 |
> |
tpb_address : PByte; |
248 |
|
end; |
249 |
|
|
250 |
|
(********************************************************) |
254 |
|
TISC_TEB = record |
255 |
|
db_handle : PISC_DB_HANDLE; |
256 |
|
tpb_length : Long; |
257 |
< |
tpb_address : PChar; |
257 |
> |
tpb_address : PByte; |
258 |
|
end; |
259 |
|
PISC_TEB = ^TISC_TEB; |
260 |
|
TISC_TEB_ARRAY = array[0..0] of TISC_TEB; |
266 |
|
|
267 |
|
Tisc_attach_database = function (status_vector : PISC_STATUS; |
268 |
|
db_name_length : Short; |
269 |
< |
db_name : PChar; |
269 |
> |
db_name : PAnsiChar; |
270 |
|
db_handle : PISC_DB_HANDLE; |
271 |
< |
parm_buffer_length : Short; |
272 |
< |
parm_buffer : PChar): ISC_STATUS; |
271 |
> |
parm_buffer_length : Short; |
272 |
> |
parm_buffer : PByte): ISC_STATUS; |
273 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
274 |
|
|
275 |
|
Tisc_array_gen_sdl = function (status_vector : PISC_STATUS; |
276 |
|
isc_array_desc : PISC_ARRAY_DESC; |
277 |
|
isc_arg3 : PShort; |
278 |
< |
isc_arg4 : PChar; |
278 |
> |
isc_arg4 : PByte; |
279 |
|
isc_arg5 : PShort): ISC_STATUS; |
280 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
281 |
|
|
292 |
|
db_handle : PISC_DB_HANDLE; |
293 |
|
trans_handle : PISC_TR_HANDLE; |
294 |
|
table_name, |
295 |
< |
column_name : PChar; |
295 |
> |
column_name : PAnsiChar; |
296 |
|
descriptor : PISC_ARRAY_DESC): ISC_STATUS; |
297 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
298 |
|
|
300 |
|
db_handle : PISC_DB_HANDLE; |
301 |
|
trans_handle : PISC_TR_HANDLE; |
302 |
|
table_name, |
303 |
< |
column_name : PChar; |
303 |
> |
column_name : PByte; |
304 |
|
descriptor : PISC_ARRAY_DESC): ISC_STATUS; |
305 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
306 |
|
|
307 |
|
Tisc_array_set_desc = function (status_vector : PISC_STATUS; |
308 |
< |
table_name : PChar; |
309 |
< |
column_name : PChar; |
308 |
> |
table_name : PByte; |
309 |
> |
column_name : PByte; |
310 |
|
sql_dtype, |
311 |
|
sql_length, |
312 |
|
sql_dimensions : PShort; |
338 |
|
Tisc_blob_info = function (status_vector : PISC_STATUS; |
339 |
|
blob_handle : PISC_BLOB_HANDLE; |
340 |
|
item_list_buffer_length : Short; |
341 |
< |
item_list_buffer : PChar; |
341 |
> |
item_list_buffer : PByte; |
342 |
|
result_buffer_length : Short; |
343 |
< |
result_buffer : PChar): ISC_STATUS; |
343 |
> |
result_buffer : PByte): ISC_STATUS; |
344 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
345 |
|
|
346 |
|
Tisc_blob_lookup_desc = function (status_vector : PISC_STATUS; |
347 |
|
db_handle : PISC_DB_HANDLE; |
348 |
|
trans_handle : PISC_TR_HANDLE; |
349 |
|
table_name, |
350 |
< |
column_name : PChar; |
350 |
> |
column_name : PAnsiChar; |
351 |
|
descriptor : PISC_BLOB_DESC; |
352 |
|
global : PUChar): ISC_STATUS; |
353 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
354 |
|
|
355 |
|
Tisc_blob_set_desc = function (status_vector : PISC_STATUS; |
356 |
|
table_name, |
357 |
< |
column_name : PChar; |
357 |
> |
column_name : PAnsiChar; |
358 |
|
subtype, |
359 |
|
charset, |
360 |
|
segment_size : Short; |
395 |
|
blob_handle : PISC_BLOB_HANDLE; |
396 |
|
blob_id : PISC_QUAD; |
397 |
|
bpb_length : Short; |
398 |
< |
bpb_address : PChar): ISC_STATUS; |
398 |
> |
bpb_address : PByte): ISC_STATUS; |
399 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
400 |
|
|
401 |
|
Tisc_create_database = function (status_vector : PISC_STATUS; |
402 |
|
isc_arg2 : Short; |
403 |
< |
isc_arg3 : PChar; |
403 |
> |
isc_arg3 : PByte; |
404 |
|
db_handle : PISC_DB_HANDLE; |
405 |
|
isc_arg5 : Short; |
406 |
< |
isc_arg6 : PChar; |
406 |
> |
isc_arg6 : PByte; |
407 |
|
isc_arg7 : Short): ISC_STATUS; |
408 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
409 |
|
|
410 |
|
Tisc_database_info = function (status_vector : PISC_STATUS; |
411 |
|
db_handle : PISC_DB_HANDLE; |
412 |
|
item_list_buffer_length : Short; |
413 |
< |
item_list_buffer : PChar; |
413 |
> |
item_list_buffer : PByte; |
414 |
|
result_buffer_length : Short; |
415 |
< |
result_buffer : PChar): ISC_STATUS; |
415 |
> |
result_buffer : PByte): ISC_STATUS; |
416 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
417 |
|
|
418 |
|
Tisc_decode_date = procedure (ib_date: PISC_QUAD; |
465 |
|
db_handle : PISC_DB_HANDLE; |
466 |
|
tran_handle : PISC_TR_HANDLE; |
467 |
|
length : UShort; |
468 |
< |
statement : PChar; |
468 |
> |
statement : PByte; |
469 |
|
dialect : UShort; |
470 |
|
in_xsqlda, |
471 |
|
out_xsqlda : PXSQLDA): ISC_STATUS; |
490 |
|
db_handle : PISC_DB_HANDLE; |
491 |
|
tran_handle : PISC_TR_HANDLE; |
492 |
|
length : UShort; |
493 |
< |
statement : PChar; |
493 |
> |
statement : PAnsiChar; |
494 |
|
dialect : UShort; |
495 |
|
xsqlda : PXSQLDA): ISC_STATUS; |
496 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
529 |
|
tran_handle : PISC_TR_HANDLE; |
530 |
|
stmt_handle : PISC_STMT_HANDLE; |
531 |
|
length : UShort; |
532 |
< |
statement : PChar; |
532 |
> |
statement : PAnsiChar; |
533 |
|
dialect : UShort; |
534 |
|
xsqlda : PXSQLDA): ISC_STATUS; |
535 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
536 |
|
|
537 |
|
Tisc_dsql_set_cursor_name = function (status_vector : PISC_STATUS; |
538 |
|
stmt_handle : PISC_STMT_HANDLE; |
539 |
< |
cursor_name : PChar; |
539 |
> |
cursor_name : PAnsiChar; |
540 |
|
_type : UShort): ISC_STATUS; |
541 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
542 |
|
|
543 |
|
Tisc_dsql_sql_info = function (status_vector : PISC_STATUS; |
544 |
|
stmt_handle : PISC_STMT_HANDLE; |
545 |
|
item_length : Short; |
546 |
< |
items : PChar; |
546 |
> |
items : PByte; |
547 |
|
buffer_length : Short; |
548 |
< |
buffer : PChar): ISC_STATUS; |
548 |
> |
buffer : PByte): ISC_STATUS; |
549 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
550 |
|
|
551 |
|
Tisc_encode_date = procedure (tm_date : PCTimeStructure; |
564 |
|
ib_timestamp : PISC_TIMESTAMP); |
565 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
566 |
|
|
567 |
< |
Tisc_event_block = function (event_buffer : PPChar; |
568 |
< |
result_buffer : PPChar; |
567 |
> |
Tisc_event_block = function (event_buffer : PPByte; |
568 |
> |
result_buffer : PPByte; |
569 |
|
id_count : UShort):ISC_LONG; |
570 |
< |
varargs; cdecl; |
570 |
> |
cdecl varargs; |
571 |
|
|
572 |
|
Tisc_event_counts = procedure (status_vector : PISC_LONG; |
573 |
|
buffer_length : Short; |
574 |
< |
event_buffer : PChar; |
575 |
< |
result_buffer : PChar); |
574 |
> |
event_buffer : PByte; |
575 |
> |
result_buffer : PByte); |
576 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
577 |
|
|
578 |
< |
Tisc_expand_dpb = procedure (dpb : PPChar; |
578 |
> |
Tisc_expand_dpb = procedure (dpb : PPByte; |
579 |
|
dpb_length : PShort; |
580 |
|
item_list : array of Pointer); |
581 |
|
cdecl; |
582 |
|
|
583 |
< |
Tisc_modify_dpb = function (dpb : PPChar; |
583 |
> |
Tisc_modify_dpb = function (dpb : PPByte; |
584 |
|
isc_arg2, |
585 |
|
isc_arg3 : PShort; |
586 |
|
isc_arg4 : UShort; |
587 |
< |
isc_arg5 : PChar; |
587 |
> |
isc_arg5 : PByte; |
588 |
|
isc_arg6 : Short): Int; |
589 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
590 |
|
|
591 |
< |
Tisc_free = function (isc_arg1 : PChar): ISC_LONG; |
591 |
> |
Tisc_free = function (isc_arg1 : PByte): ISC_LONG; |
592 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
593 |
|
|
594 |
|
Tisc_get_segment = function (status_vector : PISC_STATUS; |
595 |
|
blob_handle : PISC_BLOB_HANDLE; |
596 |
|
actual_seg_length : PUShort; |
597 |
|
seg_buffer_length : UShort; |
598 |
< |
seg_buffer : PChar): ISC_STATUS; |
598 |
> |
seg_buffer : PByte): ISC_STATUS; |
599 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
600 |
|
|
601 |
|
Tisc_get_slice = function (status_vector : PISC_STATUS; |
603 |
|
tran_handle : PISC_TR_HANDLE; |
604 |
|
isc_arg4 : PISC_QUAD; |
605 |
|
isc_arg5 : Short; |
606 |
< |
isc_arg6 : PChar; |
606 |
> |
isc_arg6 : PByte; |
607 |
|
isc_arg7 : Short; |
608 |
|
isc_arg8 : PISC_LONG; |
609 |
|
isc_arg9 : ISC_LONG; |
611 |
|
isc_arg11 : PISC_LONG): ISC_STATUS; |
612 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
613 |
|
|
614 |
< |
Tisc_interprete = function (buffer : PChar; |
614 |
> |
Tisc_interprete = function (buffer : PByte; |
615 |
|
status_vector : PPISC_STATUS): ISC_STATUS; |
616 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
617 |
|
|
628 |
|
blob_handle : PISC_BLOB_HANDLE; |
629 |
|
blob_id : PISC_QUAD; |
630 |
|
bpb_length : Short; |
631 |
< |
bpb_buffer : PChar): ISC_STATUS; |
631 |
> |
bpb_buffer : PByte): ISC_STATUS; |
632 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
633 |
|
|
634 |
|
Tisc_prepare_transaction2 = function (status_vector : PISC_STATUS; |
635 |
|
tran_handle : PISC_TR_HANDLE; |
636 |
|
msg_length : Short; |
637 |
< |
msg : PChar): ISC_STATUS; |
637 |
> |
msg : PByte): ISC_STATUS; |
638 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
639 |
|
|
640 |
|
Tisc_print_sqlerror = procedure (sqlcode : Short; |
647 |
|
Tisc_put_segment = function (status_vector : PISC_STATUS; |
648 |
|
blob_handle : PISC_BLOB_HANDLE; |
649 |
|
seg_buffer_len : UShort; |
650 |
< |
seg_buffer : PChar): ISC_STATUS; |
650 |
> |
seg_buffer : PByte): ISC_STATUS; |
651 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
652 |
|
|
653 |
|
Tisc_put_slice = function (status_vector : PISC_STATUS; |
655 |
|
tran_handle : PISC_TR_HANDLE; |
656 |
|
isc_arg4 : PISC_QUAD; |
657 |
|
isc_arg5 : Short; |
658 |
< |
isc_arg6 : PChar; |
658 |
> |
isc_arg6 : PByte; |
659 |
|
isc_arg7 : Short; |
660 |
|
isc_arg8 : PISC_LONG; |
661 |
|
isc_arg9 : ISC_LONG; |
666 |
|
db_handle : PISC_DB_HANDLE; |
667 |
|
event_id : PISC_LONG; |
668 |
|
length : Short; |
669 |
< |
event_buffer : PChar; |
669 |
> |
event_buffer : PByte; |
670 |
|
event_function : TISC_CALLBACK; |
671 |
|
event_function_arg : PVoid): ISC_STATUS; |
672 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
690 |
|
db_handle_count : Short; |
691 |
|
db_handle : PISC_DB_HANDLE; |
692 |
|
tpb_length : UShort; |
693 |
< |
tpb_address : PChar): ISC_STATUS; |
693 |
> |
tpb_address : PByte): ISC_STATUS; |
694 |
|
cdecl; |
695 |
|
|
696 |
|
Tisc_sqlcode = function (status_vector : PISC_STATUS): ISC_LONG; |
698 |
|
|
699 |
|
|
700 |
|
Tisc_sql_interprete = procedure (sqlcode : Short; |
701 |
< |
buffer : PChar; |
701 |
> |
buffer : PAnsiChar; |
702 |
|
buffer_length : Short); |
703 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
704 |
|
|
705 |
|
Tisc_transaction_info = function (status_vector : PISC_STATUS; |
706 |
|
tran_handle : PISC_TR_HANDLE; |
707 |
|
item_list_buffer_length : Short; |
708 |
< |
item_list_buffer : PChar; |
708 |
> |
item_list_buffer : PByte; |
709 |
|
result_buffer_length : Short; |
710 |
< |
result_buffer : PChar): ISC_STATUS; |
710 |
> |
result_buffer : PByte): ISC_STATUS; |
711 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
712 |
|
|
713 |
|
Tisc_transact_request = function (status_vector : PISC_STATUS; |
714 |
|
db_handle : PISC_DB_HANDLE; |
715 |
|
tran_handle : PISC_TR_HANDLE; |
716 |
|
isc_arg4 : UShort; |
717 |
< |
isc_arg5 : PChar; |
717 |
> |
isc_arg5 : PByte; |
718 |
|
isc_arg6 : UShort; |
719 |
< |
isc_arg7 : PChar; |
719 |
> |
isc_arg7 : PByte; |
720 |
|
isc_arg8 : UShort; |
721 |
< |
isc_arg9 : PChar): ISC_STATUS; |
721 |
> |
isc_arg9 : PByte): ISC_STATUS; |
722 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
723 |
|
|
724 |
< |
Tisc_vax_integer = function (buffer : PChar; |
724 |
> |
Tisc_vax_integer = function (buffer : PByte; |
725 |
|
length : Short): ISC_LONG; |
726 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
727 |
|
|
728 |
< |
Tisc_portable_integer = function (buffer : PChar; |
728 |
> |
Tisc_portable_integer = function (buffer : PByte; |
729 |
|
length : Short): ISC_INT64; |
730 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
731 |
|
|
756 |
|
uid: Int; (** the user's id **) |
757 |
|
gid: int; (** the user's group id **) |
758 |
|
protocol: Int; (** protocol to use for connection **) |
759 |
< |
server: PChar; (** server to administer **) |
760 |
< |
user_name: PChar; (** the user's name **) |
761 |
< |
password: PChar; (** the user's password **) |
762 |
< |
group_name: PChar; (** the group name **) |
763 |
< |
first_name: PChar; (** the user's first name **) |
764 |
< |
middle_name: PChar; (** the user's middle name **) |
765 |
< |
last_name: PChar; (** the user's last name **) |
766 |
< |
dba_user_name: PChar; (** the dba user name **) |
767 |
< |
dba_password: PChar; (** the dba password **) |
759 |
> |
server: PByte; (** server to administer **) |
760 |
> |
user_name: PByte; (** the user's name **) |
761 |
> |
password: PByte; (** the user's password **) |
762 |
> |
group_name: PByte; (** the group name **) |
763 |
> |
first_name: PByte; (** the user's first name **) |
764 |
> |
middle_name: PByte; (** the user's middle name **) |
765 |
> |
last_name: PByte; (** the user's last name **) |
766 |
> |
dba_user_name: PByte; (** the dba user name **) |
767 |
> |
dba_password: PByte; (** the dba password **) |
768 |
|
end; |
769 |
|
PUserSecData = ^TUserSecData; |
770 |
|
|
788 |
|
db_handle : PISC_DB_HANDLE; |
789 |
|
request_handle : PISC_REQ_HANDLE; |
790 |
|
isc_arg4 : Short; |
791 |
< |
isc_arg5 : PChar): ISC_STATUS; |
791 |
> |
isc_arg5 : PByte): ISC_STATUS; |
792 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
793 |
|
|
794 |
|
Tisc_compile_request2 = function (status_vector : PISC_STATUS; |
795 |
|
db_handle : PISC_DB_HANDLE; |
796 |
|
request_handle : PISC_REQ_HANDLE; |
797 |
|
isc_arg4 : Short; |
798 |
< |
isc_arg5 : PChar): ISC_STATUS; |
798 |
> |
isc_arg5 : PByte): ISC_STATUS; |
799 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
800 |
|
|
801 |
|
Tisc_ddl = function (status_vector : PISC_STATUS; |
802 |
|
db_handle : PISC_DB_HANDLE; |
803 |
|
tran_handle : PISC_TR_HANDLE; |
804 |
|
isc_arg4 : Short; |
805 |
< |
isc_arg5 : PChar): ISC_STATUS; |
805 |
> |
isc_arg5 : PByte): ISC_STATUS; |
806 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
807 |
|
|
808 |
|
Tisc_prepare_transaction = function (status_vector : PISC_STATUS; |
832 |
|
db_handle : PISC_DB_HANDLE; |
833 |
|
tran_handle : PISC_TR_HANDLE; |
834 |
|
isc_arg4 : Short; |
835 |
< |
isc_arg5 : PChar): ISC_STATUS; |
835 |
> |
isc_arg5 : PByte): ISC_STATUS; |
836 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
837 |
|
|
838 |
|
Tisc_release_request = function (status_vector : PISC_STATUS; |
843 |
|
request_handle : PISC_REQ_HANDLE; |
844 |
|
isc_arg3 : Short; |
845 |
|
isc_arg4 : Short; |
846 |
< |
isc_arg5 : PChar; |
846 |
> |
isc_arg5 : PByte; |
847 |
|
isc_arg6 : Short; |
848 |
< |
isc_arg7 : PChar): ISC_STATUS; |
848 |
> |
isc_arg7 : PByte): ISC_STATUS; |
849 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
850 |
|
|
851 |
|
Tisc_seek_blob = function (status_vector : PISC_STATUS; |
887 |
|
db_handle : PISC_DB_HANDLE; |
888 |
|
length : Short; |
889 |
|
event_buffer, |
890 |
< |
result_buffer : PChar): ISC_STATUS; |
890 |
> |
result_buffer : PByte): ISC_STATUS; |
891 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
892 |
|
|
893 |
|
(*******************************) |
895 |
|
(*******************************) |
896 |
|
{$IFDEF IB5_ONLY} |
897 |
|
Tisc_close = function (status_vector : PISC_STATUS; |
898 |
< |
isc_arg2 : PChar): ISC_STATUS; |
898 |
> |
isc_arg2 : PByte): ISC_STATUS; |
899 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
900 |
|
|
901 |
|
Tisc_declare = function (status_vector : PISC_STATUS; |
902 |
|
isc_arg2, |
903 |
< |
isc_arg3 : PChar): ISC_STATUS; |
903 |
> |
isc_arg3 : PByte): ISC_STATUS; |
904 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
905 |
|
|
906 |
|
Tisc_describe = function (status_vector : PISC_STATUS; |
907 |
< |
isc_arg2 : PChar; |
907 |
> |
isc_arg2 : PByte; |
908 |
|
isc_arg3 : PSQLDA): ISC_STATUS; |
909 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
910 |
|
|
911 |
|
Tisc_describe_bind = function (status_vector : PISC_STATUS; |
912 |
< |
isc_arg2 : PChar; |
912 |
> |
isc_arg2 : PByte; |
913 |
|
isc_arg3 : PSQLDA): ISC_STATUS; |
914 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
915 |
|
|
916 |
|
Tisc_execute = function (status_vector : PISC_STATUS; |
917 |
|
tran_handle : PISC_TR_HANDLE; |
918 |
< |
isc_arg3 : PChar; |
918 |
> |
isc_arg3 : PByte; |
919 |
|
isc_arg4 : PSQLDA): ISC_STATUS; |
920 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
921 |
|
|
923 |
|
db_handle : PISC_DB_HANDLE; |
924 |
|
tran_handle : PISC_TR_HANDLE; |
925 |
|
isc_arg4 : PShort; |
926 |
< |
isc_arg5 : PChar): ISC_STATUS; |
926 |
> |
isc_arg5 : PByte): ISC_STATUS; |
927 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
928 |
|
|
929 |
|
Tisc_fetch = function (status_vector : PISC_STATUS; |
930 |
< |
isc_arg2 : PChar; |
930 |
> |
isc_arg2 : PByte; |
931 |
|
isc_arg3 : PSQLDA): ISC_STATUS; |
932 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
933 |
|
|
934 |
|
Tisc_open = function (status_vector : PISC_STATUS; |
935 |
|
tran_handle : PISC_TR_HANDLE; |
936 |
< |
isc_arg3 : PChar; |
936 |
> |
isc_arg3 : PByte; |
937 |
|
isc_arg4 : PSQLDA): ISC_STATUS; |
938 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
939 |
|
|
940 |
|
Tisc_prepare = function (status_vector : PISC_STATUS; |
941 |
|
db_handle : PISC_DB_HANDLE; |
942 |
|
tran_handle : PISC_TR_HANDLE; |
943 |
< |
isc_arg4 : PChar; |
943 |
> |
isc_arg4 : PByte; |
944 |
|
isc_arg5 : PShort; |
945 |
< |
isc_arg6 : PChar; |
945 |
> |
isc_arg6 : PByte; |
946 |
|
isc_arg7 : PSQLDA): ISC_STATUS; |
947 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
948 |
|
{$ELSE} |
949 |
|
Tisc_close = function (status_vector : PISC_STATUS; |
950 |
< |
isc_arg2 : PChar): ISC_STATUS; |
950 |
> |
isc_arg2 : PByte): ISC_STATUS; |
951 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
952 |
|
|
953 |
|
Tisc_declare = function (status_vector : PISC_STATUS; |
954 |
|
isc_arg2, |
955 |
< |
isc_arg3 : PChar): ISC_STATUS; |
955 |
> |
isc_arg3 : PByte): ISC_STATUS; |
956 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
957 |
|
|
958 |
|
Tisc_describe = function (status_vector : PISC_STATUS; |
959 |
< |
isc_arg2 : PChar; |
959 |
> |
isc_arg2 : PByte; |
960 |
|
isc_arg3 : PXSQLDA): ISC_STATUS; |
961 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
962 |
|
|
963 |
|
Tisc_describe_bind = function (status_vector : PISC_STATUS; |
964 |
< |
isc_arg2 : PChar; |
964 |
> |
isc_arg2 : PByte; |
965 |
|
isc_arg3 : PXSQLDA): ISC_STATUS; |
966 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
967 |
|
|
968 |
|
Tisc_execute = function (status_vector : PISC_STATUS; |
969 |
|
tran_handle : PISC_TR_HANDLE; |
970 |
< |
isc_arg3 : PChar; |
970 |
> |
isc_arg3 : PByte; |
971 |
|
isc_arg4 : PXSQLDA): ISC_STATUS; |
972 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
973 |
|
|
975 |
|
db_handle : PISC_DB_HANDLE; |
976 |
|
tran_handle : PISC_TR_HANDLE; |
977 |
|
isc_arg4 : PShort; |
978 |
< |
isc_arg5 : PChar): ISC_STATUS; |
978 |
> |
isc_arg5 : PByte): ISC_STATUS; |
979 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
980 |
|
|
981 |
|
Tisc_fetch = function (status_vector : PISC_STATUS; |
982 |
< |
isc_arg2 : PChar; |
982 |
> |
isc_arg2 : PByte; |
983 |
|
isc_arg3 : PXSQLDA): ISC_STATUS; |
984 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
985 |
|
|
986 |
|
Tisc_open = function (status_vector : PISC_STATUS; |
987 |
|
tran_handle : PISC_TR_HANDLE; |
988 |
< |
isc_arg3 : PChar; |
988 |
> |
isc_arg3 : PByte; |
989 |
|
isc_arg4 : PXSQLDA): ISC_STATUS; |
990 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
991 |
|
|
992 |
|
Tisc_prepare = function (status_vector : PISC_STATUS; |
993 |
|
db_handle : PISC_DB_HANDLE; |
994 |
|
tran_handle : PISC_TR_HANDLE; |
995 |
< |
isc_arg4 : PChar; |
995 |
> |
isc_arg4 : PByte; |
996 |
|
isc_arg5 : PShort; |
997 |
< |
isc_arg6 : PChar; |
997 |
> |
isc_arg6 : PByte; |
998 |
|
isc_arg7 : PXSQLDA): ISC_STATUS; |
999 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1000 |
|
{$ENDIF} |
1007 |
|
tran_handle : PISC_TR_HANDLE; |
1008 |
|
statement_handle : PISC_STMT_HANDLE; |
1009 |
|
isc_arg4 : UShort; |
1010 |
< |
isc_arg5 : PChar; |
1010 |
> |
isc_arg5 : PByte; |
1011 |
|
isc_arg6 : UShort; |
1012 |
|
isc_arg7 : UShort; |
1013 |
< |
isc_arg8 : PChar): ISC_STATUS; |
1013 |
> |
isc_arg8 : PByte): ISC_STATUS; |
1014 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1015 |
|
|
1016 |
|
Tisc_dsql_execute2_m = function (status_vector : PISC_STATUS; |
1017 |
|
tran_handle : PISC_TR_HANDLE; |
1018 |
|
statement_handle : PISC_STMT_HANDLE; |
1019 |
|
isc_arg4 : UShort; |
1020 |
< |
isc_arg5 : PChar; |
1020 |
> |
isc_arg5 : PByte; |
1021 |
|
isc_arg6 : UShort; |
1022 |
|
isc_arg7 : UShort; |
1023 |
< |
isc_arg8 : PChar; |
1023 |
> |
isc_arg8 : PByte; |
1024 |
|
isc_arg9 : UShort; |
1025 |
< |
isc_arg10 : PChar; |
1025 |
> |
isc_arg10 : PByte; |
1026 |
|
isc_arg11 : UShort; |
1027 |
|
isc_arg12 : UShort; |
1028 |
< |
isc_arg13 : PChar): ISC_STATUS; |
1028 |
> |
isc_arg13 : PByte): ISC_STATUS; |
1029 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1030 |
|
|
1031 |
|
Tisc_dsql_execute_immediate_m = function (status_vector : PISC_STATUS; |
1032 |
|
db_handle : PISC_DB_HANDLE; |
1033 |
|
tran_handle : PISC_TR_HANDLE; |
1034 |
|
isc_arg4 : UShort; |
1035 |
< |
isc_arg5 : PChar; |
1035 |
> |
isc_arg5 : PByte; |
1036 |
|
isc_arg6 : UShort; |
1037 |
|
isc_arg7 : UShort; |
1038 |
< |
isc_arg8 : PChar; |
1038 |
> |
isc_arg8 : PByte; |
1039 |
|
isc_arg9 : UShort; |
1040 |
|
isc_arg10 : UShort; |
1041 |
< |
isc_arg11 : PChar): ISC_STATUS; |
1041 |
> |
isc_arg11 : PByte): ISC_STATUS; |
1042 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1043 |
|
|
1044 |
|
Tisc_dsql_exec_immed3_m = function (status_vector : PISC_STATUS; |
1045 |
|
db_handle : PISC_DB_HANDLE; |
1046 |
|
tran_handle : PISC_TR_HANDLE; |
1047 |
|
isc_arg4 : UShort; |
1048 |
< |
isc_arg5 : PChar; |
1048 |
> |
isc_arg5 : PByte; |
1049 |
|
isc_arg6 : UShort; |
1050 |
|
isc_arg7 : UShort; |
1051 |
< |
isc_arg8 : PChar; |
1051 |
> |
isc_arg8 : PByte; |
1052 |
|
isc_arg9 : UShort; |
1053 |
|
isc_arg10 : UShort; |
1054 |
< |
isc_arg11 : PChar; |
1054 |
> |
isc_arg11 : PByte; |
1055 |
|
isc_arg12 : UShort; |
1056 |
< |
isc_arg13 : PChar; |
1056 |
> |
isc_arg13 : PByte; |
1057 |
|
isc_arg14 : UShort; |
1058 |
|
isc_arg15 : UShort; |
1059 |
< |
isc_arg16 : PChar): ISC_STATUS; |
1059 |
> |
isc_arg16 : PByte): ISC_STATUS; |
1060 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1061 |
|
|
1062 |
|
Tisc_dsql_fetch_m = function (status_vector : PISC_STATUS; |
1063 |
|
statement_handle : PISC_STMT_HANDLE; |
1064 |
|
isc_arg3 : UShort; |
1065 |
< |
isc_arg4 : PChar; |
1065 |
> |
isc_arg4 : PByte; |
1066 |
|
isc_arg5 : UShort; |
1067 |
|
isc_arg6 : UShort; |
1068 |
< |
isc_arg7 : PChar): ISC_STATUS; |
1068 |
> |
isc_arg7 : PByte): ISC_STATUS; |
1069 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1070 |
|
|
1071 |
|
(*$ifdef SCROLLABLE_CURSORS*) |
1072 |
|
Tisc_dsql_fetch2_m = function (status_vector : PISC_STATUS; |
1073 |
|
statement_handle : PISC_STMT_HANDLE; |
1074 |
|
isc_arg3 : UShort; |
1075 |
< |
isc_arg4 : PChar; |
1075 |
> |
isc_arg4 : PByte; |
1076 |
|
isc_arg5 : UShort; |
1077 |
|
isc_arg6 : UShort; |
1078 |
< |
isc_arg7 : PChar; |
1078 |
> |
isc_arg7 : PByte; |
1079 |
|
isc_arg8 : UShort; |
1080 |
|
isc_arg9 : Long): ISC_STATUS; |
1081 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1084 |
|
Tisc_dsql_insert_m = function (status_vector : PISC_STATUS; |
1085 |
|
statement_handle : PISC_STMT_HANDLE; |
1086 |
|
isc_arg3 : UShort; |
1087 |
< |
isc_arg4 : PChar; |
1087 |
> |
isc_arg4 : PByte; |
1088 |
|
isc_arg5 : UShort; |
1089 |
|
isc_arg6 : UShort; |
1090 |
< |
isc_arg7 : PChar): ISC_STATUS; |
1090 |
> |
isc_arg7 : PByte): ISC_STATUS; |
1091 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1092 |
|
|
1093 |
|
Tisc_dsql_prepare_m = function (status_vector : PISC_STATUS; |
1094 |
|
tran_handle : PISC_TR_HANDLE; |
1095 |
|
statement_handle : PISC_STMT_HANDLE; |
1096 |
|
isc_arg4 : UShort; |
1097 |
< |
isc_arg5 : PChar; |
1097 |
> |
isc_arg5 : PByte; |
1098 |
|
isc_arg6 : UShort; |
1099 |
|
isc_arg7 : UShort; |
1100 |
< |
isc_arg8 : PChar; |
1100 |
> |
isc_arg8 : PByte; |
1101 |
|
isc_arg9 : UShort; |
1102 |
< |
isc_arg10 : PChar): ISC_STATUS; |
1102 |
> |
isc_arg10 : PByte): ISC_STATUS; |
1103 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1104 |
|
|
1105 |
|
Tisc_dsql_release = function (status_vector : PISC_STATUS; |
1106 |
< |
isc_arg2 : PChar): ISC_STATUS; |
1106 |
> |
isc_arg2 : PByte): ISC_STATUS; |
1107 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1108 |
|
|
1109 |
|
Tisc_embed_dsql_close = function(status_vector : PISC_STATUS; |
1110 |
< |
isc_arg2 : PChar): ISC_STATUS; |
1110 |
> |
isc_arg2 : PByte): ISC_STATUS; |
1111 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1112 |
|
|
1113 |
|
Tisc_embed_dsql_declare = function (status_vector : PISC_STATUS; |
1114 |
< |
isc_arg2 : PChar; |
1115 |
< |
isc_arg3 : PChar): ISC_STATUS; |
1114 |
> |
isc_arg2 : PByte; |
1115 |
> |
isc_arg3 : PByte): ISC_STATUS; |
1116 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1117 |
|
|
1118 |
|
Tisc_embed_dsql_describe = function (status_vector : PISC_STATUS; |
1119 |
< |
isc_arg2 : PChar; |
1119 |
> |
isc_arg2 : PByte; |
1120 |
|
isc_arg3 : UShort; |
1121 |
|
isc_arg4 : PXSQLDA): ISC_STATUS; |
1122 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1123 |
|
|
1124 |
|
Tisc_embed_dsql_describe_bind = function (status_vector : PISC_STATUS; |
1125 |
< |
isc_arg2 : PChar; |
1125 |
> |
isc_arg2 : PByte; |
1126 |
|
isc_arg3 : UShort; |
1127 |
|
isc_arg4 : PXSQLDA): ISC_STATUS; |
1128 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1129 |
|
|
1130 |
|
Tisc_embed_dsql_execute = function (status_vector : PISC_STATUS; |
1131 |
|
tran_handle : PISC_TR_HANDLE; |
1132 |
< |
isc_arg3 : PChar; |
1132 |
> |
isc_arg3 : PByte; |
1133 |
|
isc_arg4 : UShort; |
1134 |
|
isc_arg5 : PXSQLDA): ISC_STATUS; |
1135 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1136 |
|
|
1137 |
|
Tisc_embed_dsql_execute2 = function (status_vector : PISC_STATUS; |
1138 |
|
tran_handle : PISC_TR_HANDLE; |
1139 |
< |
isc_arg3 : PChar; |
1139 |
> |
isc_arg3 : PByte; |
1140 |
|
isc_arg4 : UShort; |
1141 |
|
isc_arg5 : PXSQLDA; |
1142 |
|
isc_arg6 : PXSQLDA): ISC_STATUS; |
1146 |
|
db_handle : PISC_DB_HANDLE; |
1147 |
|
tran_handle : PISC_TR_HANDLE; |
1148 |
|
isc_arg4 : UShort; |
1149 |
< |
isc_arg5 : PChar; |
1149 |
> |
isc_arg5 : PByte; |
1150 |
|
isc_arg6 : UShort; |
1151 |
|
isc_arg7 : PXSQLDA): ISC_STATUS; |
1152 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1153 |
|
|
1154 |
|
Tisc_embed_dsql_fetch = function(status_vector : PISC_STATUS; |
1155 |
< |
isc_arg2 : PChar; |
1155 |
> |
isc_arg2 : PByte; |
1156 |
|
isc_arg3 : UShort; |
1157 |
|
isc_arg4 : PXSQLDA): ISC_STATUS; |
1158 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1159 |
|
|
1160 |
|
(*$ifdef SCROLLABLE_CURSORS*) |
1161 |
|
Tisc_embed_dsql_fetch2 = function (status_vector : PISC_STATUS; |
1162 |
< |
isc_arg2 : PChar; |
1162 |
> |
isc_arg2 : PByte; |
1163 |
|
isc_arg3 : UShort; |
1164 |
|
isc_arg4 : PXSQLDA; |
1165 |
|
isc_arg5 : UShort; |
1169 |
|
|
1170 |
|
Tisc_embed_dsql_open = function (status_vector : PISC_STATUS; |
1171 |
|
tran_handle : PISC_TR_HANDLE; |
1172 |
< |
isc_arg3 : PChar; |
1172 |
> |
isc_arg3 : PByte; |
1173 |
|
isc_arg4 : UShort; |
1174 |
|
isc_arg5 : PXSQLDA): ISC_STATUS; |
1175 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1176 |
|
|
1177 |
|
Tisc_embed_dsql_open2 = function (status_vector : PISC_STATUS; |
1178 |
|
tran_handle : PISC_TR_HANDLE; |
1179 |
< |
isc_arg3 : PChar; |
1179 |
> |
isc_arg3 : PByte; |
1180 |
|
isc_arg4 : UShort; |
1181 |
|
isc_arg5 : PXSQLDA; |
1182 |
|
isc_arg6 : PXSQLDA): ISC_STATUS; |
1183 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1184 |
|
|
1185 |
|
Tisc_embed_dsql_insert = function (status_vector : PISC_STATUS; |
1186 |
< |
isc_arg2 : PChar; |
1186 |
> |
isc_arg2 : PByte; |
1187 |
|
isc_arg3 : UShort; |
1188 |
|
isc_arg4 : PXSQLDA): ISC_STATUS; |
1189 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1191 |
|
Tisc_embed_dsql_prepare = function (status_vector : PISC_STATUS; |
1192 |
|
db_handle : PISC_DB_HANDLE; |
1193 |
|
tran_handle : PISC_TR_HANDLE; |
1194 |
< |
isc_arg4 : PChar; |
1194 |
> |
isc_arg4 : PByte; |
1195 |
|
isc_arg5 : UShort; |
1196 |
< |
isc_arg6 : PChar; |
1196 |
> |
isc_arg6 : PByte; |
1197 |
|
isc_arg7 : UShort; |
1198 |
|
isc_arg8 : PXSQLDA): ISC_STATUS; |
1199 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1200 |
|
|
1201 |
|
Tisc_embed_dsql_release = function (status_vector : PISC_STATUS; |
1202 |
< |
isc_arg2 : PChar): ISC_STATUS; |
1202 |
> |
isc_arg2 : PByte): ISC_STATUS; |
1203 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1204 |
|
|
1205 |
|
(********************************) |
1207 |
|
(********************************) |
1208 |
|
|
1209 |
|
TBLOB_open = function (blob_handle : TISC_BLOB_HANDLE; |
1210 |
< |
isc_arg2 : PChar; |
1210 |
> |
isc_arg2 : PByte; |
1211 |
|
isc_arg3 : int): PBSTREAM; |
1212 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1213 |
|
|
1224 |
|
TBLOB_display = function (isc_arg1 : PISC_QUAD; |
1225 |
|
db_handle : TISC_DB_HANDLE; |
1226 |
|
tran_handle : TISC_TR_HANDLE; |
1227 |
< |
isc_arg4 : PChar): Int; |
1227 |
> |
isc_arg4 : PByte): Int; |
1228 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1229 |
|
|
1230 |
|
TBLOB_dump = function (isc_arg1 : PISC_QUAD; |
1231 |
|
db_handle : TISC_DB_HANDLE; |
1232 |
|
tran_handle : TISC_TR_HANDLE; |
1233 |
< |
isc_arg4 : PChar): Int; |
1233 |
> |
isc_arg4 : PByte): Int; |
1234 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1235 |
|
|
1236 |
|
TBLOB_edit = function (isc_arg1 : PISC_QUAD; |
1237 |
|
db_handle : TISC_DB_HANDLE; |
1238 |
|
tran_handle : TISC_TR_HANDLE; |
1239 |
< |
isc_arg4 : PChar): Int; |
1239 |
> |
isc_arg4 : PByte): Int; |
1240 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1241 |
|
|
1242 |
|
TBLOB_load = function (isc_arg1 : PISC_QUAD; |
1243 |
|
db_handle : TISC_DB_HANDLE; |
1244 |
|
tran_handle : TISC_TR_HANDLE; |
1245 |
< |
isc_arg4 : PChar): Int; |
1245 |
> |
isc_arg4 : PByte): Int; |
1246 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1247 |
|
|
1248 |
|
TBLOB_text_dump = function (isc_arg1 : PISC_QUAD; |
1249 |
|
db_handle : TISC_DB_HANDLE; |
1250 |
|
tran_handle : TISC_TR_HANDLE; |
1251 |
< |
isc_arg4 : PChar): Int; |
1251 |
> |
isc_arg4 : PByte): Int; |
1252 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1253 |
|
|
1254 |
|
TBLOB_text_load = function (isc_arg1 : PISC_QUAD; |
1255 |
|
db_handle : TISC_DB_HANDLE; |
1256 |
|
tran_handle : TISC_TR_HANDLE; |
1257 |
< |
isc_arg4 : PChar): Int; |
1257 |
> |
isc_arg4 : PByte): Int; |
1258 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1259 |
|
|
1260 |
|
TBopen = function (isc_arg1 : PISC_QUAD; |
1261 |
|
db_handle : TISC_DB_HANDLE; |
1262 |
|
tran_handle : TISC_TR_HANDLE; |
1263 |
< |
isc_arg4 : PChar): Int; |
1263 |
> |
isc_arg4 : PByte): Int; |
1264 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1265 |
|
|
1266 |
|
TBopen2 = function (isc_arg1 : PISC_QUAD; |
1267 |
|
db_handle : TISC_DB_HANDLE; |
1268 |
|
tran_handle : TISC_TR_HANDLE; |
1269 |
< |
isc_arg4 : PChar; |
1269 |
> |
isc_arg4 : PByte; |
1270 |
|
isc_arg5 : UShort): PBSTREAM; |
1271 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1272 |
|
|
1274 |
|
(** Other Misc functions **) |
1275 |
|
(********************************) |
1276 |
|
|
1277 |
< |
Tisc_ftof = function (isc_arg1 : PChar; |
1277 |
> |
Tisc_ftof = function (isc_arg1 : PByte; |
1278 |
|
isc_arg2 : UShort; |
1279 |
< |
isc_arg3 : PChar; |
1279 |
> |
isc_arg3 : PByte; |
1280 |
|
isc_arg4 : UShort): ISC_LONG; |
1281 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1282 |
|
|
1283 |
< |
Tisc_print_blr = function (isc_arg1 : PChar; |
1283 |
> |
Tisc_print_blr = function (isc_arg1 : PByte; |
1284 |
|
isc_arg2 : TISC_CALLBACK; |
1285 |
|
isc_arg3 : PVoid; |
1286 |
|
isc_arg4 : Short): ISC_STATUS; |
1293 |
|
isc_arg2 : PISC_QUAD); |
1294 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1295 |
|
|
1296 |
< |
Tisc_vtof = procedure (isc_arg1 : PChar; |
1297 |
< |
isc_arg2 : PChar; |
1296 |
> |
Tisc_vtof = procedure (isc_arg1 : PByte; |
1297 |
> |
isc_arg2 : PByte; |
1298 |
|
isc_arg3 : UShort); |
1299 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1300 |
|
|
1301 |
< |
Tisc_vtov = procedure (isc_arg1 : PChar; |
1302 |
< |
isc_arg2 : PChar; |
1301 |
> |
Tisc_vtov = procedure (isc_arg1 : PByte; |
1302 |
> |
isc_arg2 : PByte; |
1303 |
|
isc_arg3 : Short); |
1304 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1305 |
|
|
1317 |
|
|
1318 |
|
Tisc_service_attach = function (status_vector : PISC_STATUS; |
1319 |
|
isc_arg2 : UShort; |
1320 |
< |
isc_arg3 : PChar; |
1320 |
> |
isc_arg3 : PAnsiChar; |
1321 |
|
service_handle : PISC_SVC_HANDLE; |
1322 |
|
isc_arg5 : UShort; |
1323 |
< |
isc_arg6 : PChar): ISC_STATUS; |
1323 |
> |
isc_arg6 : PByte): ISC_STATUS; |
1324 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1325 |
|
|
1326 |
|
Tisc_service_detach = function (status_vector : PISC_STATUS; |
1331 |
|
service_handle : PISC_SVC_HANDLE; |
1332 |
|
recv_handle : PISC_SVC_HANDLE; |
1333 |
|
isc_arg4 : UShort; |
1334 |
< |
isc_arg5 : PChar; |
1334 |
> |
isc_arg5 : PByte; |
1335 |
|
isc_arg6 : UShort; |
1336 |
< |
isc_arg7 : PChar; |
1336 |
> |
isc_arg7 : PByte; |
1337 |
|
isc_arg8 : UShort; |
1338 |
< |
isc_arg9 : PChar): ISC_STATUS; |
1338 |
> |
isc_arg9 : PByte): ISC_STATUS; |
1339 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1340 |
|
|
1341 |
|
Tisc_service_start = function (status_vector : PISC_STATUS; |
1342 |
|
service_handle : PISC_SVC_HANDLE; |
1343 |
|
recv_handle : PISC_SVC_HANDLE; |
1344 |
|
isc_arg4 : UShort; |
1345 |
< |
isc_arg5 : PChar): ISC_STATUS; |
1345 |
> |
isc_arg5 : PByte): ISC_STATUS; |
1346 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1347 |
|
|
1348 |
|
(*********************************) |
1353 |
|
form_handle : PISC_FORM_HANDLE; |
1354 |
|
request_handle : PISC_REQ_HANDLE; |
1355 |
|
isc_arg4 : PShort; |
1356 |
< |
isc_arg5 : PChar): ISC_STATUS; |
1356 |
> |
isc_arg5 : PByte): ISC_STATUS; |
1357 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1358 |
|
|
1359 |
|
Tisc_compile_menu = function (status_vector : PISC_STATUS; |
1360 |
|
form_handle : PISC_FORM_HANDLE; |
1361 |
|
request_handle : PISC_REQ_HANDLE; |
1362 |
|
isc_arg4 : PShort; |
1363 |
< |
isc_arg5 : PChar): ISC_STATUS; |
1363 |
> |
isc_arg5 : PByte): ISC_STATUS; |
1364 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1365 |
|
|
1366 |
|
Tisc_compile_sub_map = function (status_vector : PISC_STATUS; |
1367 |
|
win_handle : PISC_WIN_HANDLE; |
1368 |
|
request_handle : PISC_REQ_HANDLE; |
1369 |
|
isc_arg4 : PShort; |
1370 |
< |
isc_arg5 : PChar): ISC_STATUS; |
1370 |
> |
isc_arg5 : PByte): ISC_STATUS; |
1371 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1372 |
|
|
1373 |
|
Tisc_create_window = function (status_vector : PISC_STATUS; |
1374 |
|
win_handle : PISC_WIN_HANDLE; |
1375 |
|
isc_arg3 : PShort; |
1376 |
< |
isc_arg4 : PChar; |
1376 |
> |
isc_arg4 : PByte; |
1377 |
|
isc_arg5 : PShort; |
1378 |
|
isc_arg6 : PShort): ISC_STATUS; |
1379 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1395 |
|
win_handle : PISC_WIN_HANDLE; |
1396 |
|
request_handle : PISC_REQ_HANDLE; |
1397 |
|
isc_arg4 : PShort; |
1398 |
< |
isc_arg5 : PChar; |
1398 |
> |
isc_arg5 : PByte; |
1399 |
|
isc_arg6 : PShort; |
1400 |
< |
isc_arg7 : PChar; |
1400 |
> |
isc_arg7 : PByte; |
1401 |
|
isc_arg8 : PShort; |
1402 |
|
isc_arg9 : PShort; |
1403 |
< |
isc_arg10 : PChar; |
1403 |
> |
isc_arg10 : PByte; |
1404 |
|
isc_arg11 : PISC_LONG): ISC_STATUS; |
1405 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1406 |
|
|
1425 |
|
Tisc_get_entree = function (status_vector : PISC_STATUS; |
1426 |
|
request_handle : PISC_REQ_HANDLE; |
1427 |
|
isc_arg3 : PShort; |
1428 |
< |
isc_arg4 : PChar; |
1428 |
> |
isc_arg4 : PByte; |
1429 |
|
isc_arg5 : PISC_LONG; |
1430 |
|
isc_arg6 : PShort): ISC_STATUS; |
1431 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1438 |
|
win_handle : PISC_WIN_HANDLE; |
1439 |
|
request_handle : PISC_REQ_HANDLE; |
1440 |
|
isc_arg4 : PShort; |
1441 |
< |
isc_arg5 : PChar): ISC_STATUS; |
1441 |
> |
isc_arg5 : PByte): ISC_STATUS; |
1442 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1443 |
|
|
1444 |
|
Tisc_load_form = function (status_vector : PISC_STATUS; |
1446 |
|
tran_handle : PISC_TR_HANDLE; |
1447 |
|
form_handle : PISC_FORM_HANDLE; |
1448 |
|
isc_arg5 : PShort; |
1449 |
< |
isc_arg6 : PChar): ISC_STATUS; |
1449 |
> |
isc_arg6 : PByte): ISC_STATUS; |
1450 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1451 |
|
|
1452 |
|
Tisc_pop_window = function (status_vector : PISC_STATUS; |
1456 |
|
Tisc_put_entree = function (status_vector : PISC_STATUS; |
1457 |
|
request_handle : PISC_REQ_HANDLE; |
1458 |
|
isc_arg3 : PShort; |
1459 |
< |
isc_arg4 : PChar; |
1459 |
> |
isc_arg4 : PByte; |
1460 |
|
isc_arg5 : PISC_LONG): ISC_STATUS; |
1461 |
|
{$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} |
1462 |
|
|
1807 |
|
|
1808 |
|
|
1809 |
|
|
1807 |
– |
{$IFDEF IB5_ONLY} |
1808 |
– |
(** SQLDA_LENGTH is defined in C as a macro, but in Pascal we must defined it |
1809 |
– |
as a function... **) |
1810 |
– |
function SQLDA_LENGTH(n: Long): Long; |
1811 |
– |
{$ENDIF} |
1812 |
– |
|
1810 |
|
(** XSQLDA_LENGTH is defined in C as a macro, but in Pascal we must defined it |
1811 |
|
as a function... **) |
1812 |
|
function XSQLDA_LENGTH(n: Long): Long; |
1813 |
|
|
1817 |
– |
(** getb, putb, putbx are all defined in C as macros. |
1818 |
– |
Use functions and procedures for the functionality **) |
1819 |
– |
{function getb (p: PBSTREAM): Char; |
1820 |
– |
function putb (x: Char; p: PBSTREAM): Int; |
1821 |
– |
function putbx (x: Char; p: PBSTREAM): Int;} |
1822 |
– |
|
1823 |
– |
(* |
1824 |
– |
#define ADD_SPB_LENGTH(p, length) {*(p)++ = (length); \ |
1825 |
– |
*(p)++ = (length) >> 8;} |
1826 |
– |
|
1827 |
– |
#define ADD_SPB_NUMERIC(p, data) {*(p)++ = (data); \ |
1828 |
– |
*(p)++ = (data) >> 8; \ |
1829 |
– |
*(p)++ = (data) >> 16; \ |
1830 |
– |
*(p)++ = (data) >> 24;} |
1831 |
– |
*) |
1832 |
– |
procedure add_spb_length(var p: PChar; length: integer); |
1833 |
– |
procedure add_spb_numeric(var p: PChar; data: integer); |
1834 |
– |
|
1835 |
– |
|
1814 |
|
implementation |
1815 |
|
|
1816 |
|
|
1839 |
– |
{$IFDEF IB5_ONLY} |
1840 |
– |
function SQLDA_LENGTH(n: Long): Long; |
1841 |
– |
(* The C-macro reads like this: |
1842 |
– |
SQLDA_LENGTH(n) (sizeof (SQLDA) + (n-1) * sizeof (SQLVAR)) *) |
1843 |
– |
begin |
1844 |
– |
result := sizeof(TSQLDA) + ((n - 1) * sizeof(TSQLVAR)); |
1845 |
– |
end; |
1846 |
– |
{$ENDIF} |
1847 |
– |
|
1848 |
– |
|
1817 |
|
function XSQLDA_LENGTH(n: Long): Long; |
1818 |
|
(* The C-macro reads like this: |
1819 |
|
XSQLDA_LENGTH(n) (sizeof (XSQLDA) + (n-1) * sizeof (XSQLVAR)) *) |
1821 |
|
result := SizeOf(TXSQLDA) + ((n - 1) * SizeOf(TXSQLVAR)); |
1822 |
|
end; |
1823 |
|
|
1856 |
– |
{function getb(p: PBSTREAM): Char; |
1857 |
– |
(* The C-macro reads like this: |
1858 |
– |
getb(p) (--(p)->bstr_cnt >= 0 ? *(p)->bstr_ptr++ & 0377: BLOB_get (p)) *) |
1859 |
– |
begin |
1860 |
– |
Dec(p^.bstr_cnt); |
1861 |
– |
if (p^.bstr_cnt >= 0) then begin |
1862 |
– |
result := Char(Int(p^.bstr_ptr^) and Int(0377)); |
1863 |
– |
Inc(p^.bstr_ptr); |
1864 |
– |
end else |
1865 |
– |
result := Char(BLOB_get(p)); |
1866 |
– |
end;} |
1867 |
– |
|
1868 |
– |
//function putb(x: Char; p: PBSTREAM): Int; |
1869 |
– |
(* The C-macro reads like this: |
1870 |
– |
putb(x,p) ((x == '\n' || (!(--(p)->bstr_cnt))) ? // then |
1871 |
– |
BLOB_put (x,p) : // else |
1872 |
– |
((int) (*(p)->bstr_ptr++ = (unsigned) (x)))) *) |
1873 |
– |
begin |
1874 |
– |
Dec(p^.bstr_cnt); |
1875 |
– |
if (x = Chr(Int('n') - Int('a'))) or (p^.bstr_cnt = 0) then |
1876 |
– |
result := BLOB_put(x, p) |
1877 |
– |
else begin |
1878 |
– |
p^.bstr_ptr^ := Char(x); |
1879 |
– |
result := UInt(x); |
1880 |
– |
Inc(p^.bstr_ptr^); |
1881 |
– |
end; |
1882 |
– |
end; |
1883 |
– |
|
1884 |
– |
function putbx(x: Char; p: PBSTREAM): Int; |
1885 |
– |
(* The C-macro reads like this: |
1886 |
– |
putbx(x,p) ((!(--(p)->bstr_cnt)) ? // then |
1887 |
– |
BLOB_put (x,p) : // else |
1888 |
– |
((int) (*(p)->bstr_ptr++ = (unsigned) (x)))) *) |
1889 |
– |
begin |
1890 |
– |
Dec(p^.bstr_cnt); |
1891 |
– |
if (p^.bstr_cnt = 0) then |
1892 |
– |
result := BLOB_put(x, p) |
1893 |
– |
else begin |
1894 |
– |
p^.bstr_ptr^ := Char(x); |
1895 |
– |
Inc(p^.bstr_ptr^); |
1896 |
– |
result := UInt(x); |
1897 |
– |
end; |
1898 |
– |
end; |
1899 |
– |
|
1900 |
– |
(*******************************************) |
1901 |
– |
(** Service manager functions **) |
1902 |
– |
(*******************************************) |
1903 |
– |
|
1904 |
– |
|
1905 |
– |
procedure add_spb_length(var p: PChar; length: integer); |
1906 |
– |
(* |
1907 |
– |
#define ADD_SPB_LENGTH(p, length) {*(p)++ = (length); \ |
1908 |
– |
*(p)++ = (length) >> 8;} |
1909 |
– |
*) |
1910 |
– |
begin |
1911 |
– |
p^ := char(length); |
1912 |
– |
Inc (p); |
1913 |
– |
p^ := char(length shr 8); |
1914 |
– |
Inc (p); |
1915 |
– |
end; |
1916 |
– |
|
1917 |
– |
procedure add_spb_numeric(var p: PChar; data: integer); |
1918 |
– |
(* |
1919 |
– |
#define ADD_SPB_NUMERIC(p, data) {*(p)++ = (data); \ |
1920 |
– |
*(p)++ = (data) >> 8; \ |
1921 |
– |
*(p)++ = (data) >> 16; \ |
1922 |
– |
*(p)++ = (data) >> 24;} |
1923 |
– |
*) |
1924 |
– |
begin |
1925 |
– |
p^ := char(data); |
1926 |
– |
Inc (p); |
1927 |
– |
p^ := char(data shr 8); |
1928 |
– |
Inc (p); |
1929 |
– |
p^ := char(data shr 16); |
1930 |
– |
Inc (p); |
1931 |
– |
p^ := char(data shr 24); |
1932 |
– |
Inc (p); |
1933 |
– |
end; |
1824 |
|
|
1825 |
|
end. |
1826 |
|
|