ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/public/ibx/trunk/fbintf/client/2.5/IBHeader.pas
(Generate patch)

Comparing ibx/trunk/fbintf/client/2.5/IBHeader.pas (file contents):
Revision 55 by tony, Mon Jan 9 15:31:51 2017 UTC vs.
Revision 56 by tony, Mon Mar 6 10:20:02 2017 UTC

# Line 32 | Line 32
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
# Line 97 | Line 101 | const
101    TIME_SECONDS_PRECISION_SCALE = -4;
102  
103   type
104 +  PPByte = ^PByte;
105    ISC_DATE = Long;
106    PISC_DATE = ^ISC_DATE;
107    ISC_TIME = ULong;
# Line 114 | Line 119 | type
119    PISC_ARRAY_BOUND     = ^TISC_ARRAY_BOUND;
120     TISC_ARRAY_DESC = record
121      array_desc_dtype            : UChar;
122 <    array_desc_scale            : Char;
122 >    array_desc_scale            : ShortInt;
123      array_desc_length           : UShort;
124 <    array_desc_field_name       : array[0..31] of Char;
125 <    array_desc_relation_name    : array[0..31] of Char;
124 >    array_desc_field_name       : array[0..31] of AnsiChar;
125 >    array_desc_relation_name    : array[0..31] of AnsiChar;
126      array_desc_dimensions       : Short;
127      array_desc_flags            : Short;
128      array_desc_bounds           : array[0..15] of TISC_ARRAY_BOUND;
# Line 128 | Line 133 | type
133      blob_desc_subtype           : Short;
134      blob_desc_charset           : Short;
135      blob_desc_segment_size      : Short;
136 <    blob_desc_field_name        : array[0..31] of Char;
137 <    blob_desc_relation_name     : array[0..31] of Char;
136 >    blob_desc_field_name        : array[0..31] of AnsiChar;
137 >    blob_desc_relation_name     : array[0..31] of AnsiChar;
138    end; // TISC_BLOB_DESC
139    PISC_BLOB_DESC = ^TISC_BLOB_DESC;
140  
# Line 149 | Line 154 | type
154      ctl_segment_length          : UShort;       (** Length of current segment **)
155      ctl_bpb_length              : UShort;       (** Length of blob parameter **)
156                                                  (** block **)
157 <    ctl_bpb                     : PChar;        (** Address of blob parameter **)
157 >    ctl_bpb                     : PByte;        (** Address of blob parameter **)
158                                                  (** block **)
159      ctl_buffer                  : PUChar;       (** Address of segment buffer **)
160      ctl_max_segment             : ISC_LONG;     (** Length of longest segment **)
# Line 163 | Line 168 | type
168    (*****************************)
169    TBSTREAM = record
170      bstr_blob                   : PVoid;        (** Blob handle **)
171 <    bstr_buffer                 : PChar;        (** Address of buffer **)
172 <    bstr_ptr                    : PChar;        (** Next character **)
171 >    bstr_buffer                 : PByte;        (** Address of buffer **)
172 >    bstr_ptr                    : PByte;        (** Next character **)
173      bstr_length                 : Short;        (** Length of buffer **)
174      bstr_cnt                    : Short;        (** Characters in buffer **)
175      bstr_mode                   : Char;         (** (mode) ? OUTPUT : INPUT **)
# Line 178 | Line 183 | type
183    TSQLVAR = record
184      sqltype                     : Short;
185      sqllen                      : Short;
186 <    sqldata                     : PChar;
186 >    sqldata                     : PByte;
187      sqlind                      : PShort;
188      sqlname_length              : Short;
189 <    sqlname                     : array[0..29] of Char;
189 >    sqlname                     : array[0..29] of AnsiChar;
190    end;
191    PSQLVAR                       = ^TSQLVAR;
192  
193    TSQLDA = record
194 <    sqldaid                     : array[0..7] of Char;
194 >    sqldaid                     : array[0..7] of AnsiChar;
195      sqldabc                     : ISC_LONG;
196      sqln                        : Short;
197      sqld                        : Short;
# Line 204 | Line 209 | type
209      sqlsubtype                  : Short;     (** datatype subtype - BLOBs **)
210                                               (** & text types only **)
211      sqllen                      : Short;     (** length of data area **)
212 <    sqldata                     : PChar;     (** address of data **)
212 >    sqldata                     : PByte;     (** address of data **)
213      sqlind                      : PShort;    (** address of indicator **)
214                                               (** variable **)
215      sqlname_length              : Short;     (** length of sqlname field **)
216      (** name of field, name length + space for NULL **)
217 <    sqlname                     : array[0..31] of Char;
217 >    sqlname                     : array[0..31] of AnsiChar;
218      relname_length              : Short;     (** length of relation name **)
219      (** field's relation name + space for NULL **)
220 <    relname                     : array[0..31] of Char;
220 >    relname                     : array[0..31] of AnsiChar;
221      ownname_length              : Short;     (** length of owner name **)
222      (** relation's owner name + space for NULL **)
223 <    ownname                     : array[0..31] of Char;
223 >    ownname                     : array[0..31] of AnsiChar;
224      aliasname_length            : Short;     (** length of alias name **)
225      (** relation's alias name + space for NULL **)
226 <    aliasname                   : array[0..31] of Char;
226 >    aliasname                   : array[0..31] of AnsiChar;
227    end;  // TXSQLVAR
228    PXSQLVAR                      = ^TXSQLVAR;
229  
230    TXSQLDA = record
231      version                     : Short;     (** version of this XSQLDA **)
232      (** XSQLDA name field **)
233 <    sqldaid                     : array[0..7] of Char;
233 >    sqldaid                     : array[0..7] of AnsiChar;
234      sqldabc                     : ISC_LONG;  (** length in bytes of SQLDA **)
235      sqln                        : Short;     (** number of fields allocated **)
236      sqld                        : Short;     (** actual number of fields **)
# Line 241 | Line 246 | type
246    TISC_START_TRANS = record
247      db_handle      : PISC_DB_HANDLE;
248      tpb_length     : UShort;
249 <    tpb_address    : PChar;
249 >    tpb_address    : PByte;
250    end;
251  
252   (********************************************************)
# Line 251 | Line 256 | type
256    TISC_TEB = record
257      db_handle      : PISC_DB_HANDLE;
258      tpb_length     : Long;
259 <    tpb_address    : PChar;
259 >    tpb_address    : PByte;
260    end;
261    PISC_TEB = ^TISC_TEB;
262    TISC_TEB_ARRAY = array[0..0] of TISC_TEB;
# Line 263 | Line 268 | type
268  
269   Tisc_attach_database = function (status_vector            : PISC_STATUS;
270                                   db_name_length           : Short;
271 <                                 db_name                  : PChar;
271 >                                 db_name                  : PAnsiChar;
272                                   db_handle                : PISC_DB_HANDLE;
273 <                                 parm_buffer_length       : Short;
274 <                                 parm_buffer              : PChar): ISC_STATUS;
273 >                                                   parm_buffer_length         : Short;
274 >                                 parm_buffer              : PByte): ISC_STATUS;
275                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
276  
277   Tisc_array_gen_sdl = function   (status_vector            : PISC_STATUS;
278                                   isc_array_desc           : PISC_ARRAY_DESC;
279                                   isc_arg3                 : PShort;
280 <                                 isc_arg4                 : PChar;
280 >                                 isc_arg4                 : PByte;
281                                   isc_arg5                 : PShort): ISC_STATUS;
282                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
283  
# Line 289 | Line 294 | Tisc_array_lookup_bounds = function (sta
294                                   db_handle                : PISC_DB_HANDLE;
295                                   trans_handle             : PISC_TR_HANDLE;
296                                   table_name,
297 <                                 column_name              : PChar;
297 >                                 column_name              : PAnsiChar;
298                                   descriptor               : PISC_ARRAY_DESC): ISC_STATUS;
299                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
300  
# Line 297 | Line 302 | Tisc_array_lookup_desc = function (statu
302                                   db_handle                : PISC_DB_HANDLE;
303                                   trans_handle             : PISC_TR_HANDLE;
304                                   table_name,
305 <                                 column_name              : PChar;
305 >                                 column_name              : PByte;
306                                   descriptor               : PISC_ARRAY_DESC): ISC_STATUS;
307                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
308  
309   Tisc_array_set_desc = function  (status_vector            : PISC_STATUS;
310 <                                 table_name               : PChar;
311 <                                 column_name              : PChar;
310 >                                 table_name               : PByte;
311 >                                 column_name              : PByte;
312                                   sql_dtype,
313                                   sql_length,
314                                   sql_dimensions           : PShort;
# Line 335 | Line 340 | Tisc_blob_gen_bpb = function    (status_
340   Tisc_blob_info = function       (status_vector            : PISC_STATUS;
341                                   blob_handle              : PISC_BLOB_HANDLE;
342                                   item_list_buffer_length  : Short;
343 <                                 item_list_buffer         : PChar;
343 >                                 item_list_buffer         : PByte;
344                                   result_buffer_length     : Short;
345 <                                 result_buffer            : PChar): ISC_STATUS;
345 >                                 result_buffer            : PByte): ISC_STATUS;
346                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
347  
348   Tisc_blob_lookup_desc = function (status_vector           : PISC_STATUS;
349                                   db_handle                : PISC_DB_HANDLE;
350                                   trans_handle             : PISC_TR_HANDLE;
351                                   table_name,
352 <                                 column_name              : PChar;
352 >                                 column_name              : PAnsiChar;
353                                   descriptor               : PISC_BLOB_DESC;
354                                   global                   : PUChar): ISC_STATUS;
355                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
356  
357   Tisc_blob_set_desc = function   (status_vector            : PISC_STATUS;
358                                   table_name,
359 <                                 column_name              : PChar;
359 >                                 column_name              : PAnsiChar;
360                                   subtype,
361                                   charset,
362                                   segment_size             : Short;
# Line 392 | Line 397 | Tisc_create_blob2 = function    (status_
397                                   blob_handle              : PISC_BLOB_HANDLE;
398                                   blob_id                  : PISC_QUAD;
399                                   bpb_length               : Short;
400 <                                 bpb_address              : PChar): ISC_STATUS;
400 >                                 bpb_address              : PByte): ISC_STATUS;
401                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
402  
403   Tisc_create_database = function (status_vector            : PISC_STATUS;
404                                   isc_arg2                 : Short;
405 <                                 isc_arg3                 : PChar;
405 >                                 isc_arg3                 : PByte;
406                                   db_handle                : PISC_DB_HANDLE;
407                                   isc_arg5                 : Short;
408 <                                 isc_arg6                 : PChar;
408 >                                 isc_arg6                 : PByte;
409                                   isc_arg7                 : Short): ISC_STATUS;
410                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
411  
412   Tisc_database_info = function   (status_vector            : PISC_STATUS;
413                                   db_handle                : PISC_DB_HANDLE;
414                                   item_list_buffer_length  : Short;
415 <                                 item_list_buffer         : PChar;
415 >                                 item_list_buffer         : PByte;
416                                   result_buffer_length     : Short;
417 <                                 result_buffer            : PChar): ISC_STATUS;
417 >                                 result_buffer            : PByte): ISC_STATUS;
418                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
419  
420   Tisc_decode_date = procedure    (ib_date: PISC_QUAD;
# Line 462 | Line 467 | Tisc_dsql_exec_immed2 = function (status
467                                   db_handle                : PISC_DB_HANDLE;
468                                   tran_handle              : PISC_TR_HANDLE;
469                                   length                   : UShort;
470 <                                 statement                : PChar;
470 >                                 statement                : PByte;
471                                   dialect                  : UShort;
472                                   in_xsqlda,
473                                   out_xsqlda               : PXSQLDA): ISC_STATUS;
# Line 487 | Line 492 | Tisc_dsql_execute_immediate = function (
492                                   db_handle                : PISC_DB_HANDLE;
493                                   tran_handle              : PISC_TR_HANDLE;
494                                   length                   : UShort;
495 <                                 statement                : PChar;
495 >                                 statement                : PAnsiChar;
496                                   dialect                  : UShort;
497                                   xsqlda                   : PXSQLDA): ISC_STATUS;
498                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
# Line 526 | Line 531 | Tisc_dsql_prepare = function    (status_
531                                   tran_handle              : PISC_TR_HANDLE;
532                                   stmt_handle              : PISC_STMT_HANDLE;
533                                   length                   : UShort;
534 <                                 statement                : PChar;
534 >                                 statement                : PAnsiChar;
535                                   dialect                  : UShort;
536                                   xsqlda                   : PXSQLDA): ISC_STATUS;
537                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
538  
539   Tisc_dsql_set_cursor_name = function (status_vector        : PISC_STATUS;
540                                   stmt_handle               : PISC_STMT_HANDLE;
541 <                                 cursor_name               : PChar;
541 >                                 cursor_name               : PAnsiChar;
542                                   _type                     : UShort): ISC_STATUS;
543                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
544  
545   Tisc_dsql_sql_info = function   (status_vector             : PISC_STATUS;
546                                   stmt_handle               : PISC_STMT_HANDLE;
547                                   item_length               : Short;
548 <                                 items                     : PChar;
548 >                                 items                     : PByte;
549                                   buffer_length             : Short;
550 <                                 buffer                    : PChar): ISC_STATUS;
550 >                                 buffer                    : PByte): ISC_STATUS;
551                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
552  
553   Tisc_encode_date = procedure    (tm_date                    : PCTimeStructure;
# Line 561 | Line 566 | Tisc_encode_timestamp = procedure (tm_da
566                                   ib_timestamp               : PISC_TIMESTAMP);
567                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
568  
569 < Tisc_event_block = function     (event_buffer               : PPChar;
570 <                                 result_buffer              : PPChar;
569 > Tisc_event_block = function     (event_buffer               : PPByte;
570 >                                 result_buffer              : PPByte;
571                                   id_count                   : UShort):ISC_LONG;
572 <                                 varargs; cdecl;
572 >                                 cdecl varargs;
573  
574   Tisc_event_counts = procedure   (status_vector             : PISC_LONG;
575                                   buffer_length             : Short;
576 <                                 event_buffer              : PChar;
577 <                                 result_buffer             : PChar);
576 >                                 event_buffer              : PByte;
577 >                                 result_buffer             : PByte);
578                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
579  
580 < Tisc_expand_dpb = procedure     (dpb                       : PPChar;
580 > Tisc_expand_dpb = procedure     (dpb                       : PPByte;
581                                   dpb_length                : PShort;
582                                   item_list                 : array of Pointer);
583                                  cdecl;
584  
585 < Tisc_modify_dpb = function      (dpb                       : PPChar;
585 > Tisc_modify_dpb = function      (dpb                       : PPByte;
586                                   isc_arg2,
587                                   isc_arg3                  : PShort;
588                                   isc_arg4                  : UShort;
589 <                                 isc_arg5                  : PChar;
589 >                                 isc_arg5                  : PByte;
590                                   isc_arg6                  : Short): Int;
591                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
592  
593 < Tisc_free = function           (isc_arg1                  : PChar): ISC_LONG;
593 > Tisc_free = function           (isc_arg1                  : PByte): ISC_LONG;
594                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
595  
596   Tisc_get_segment = function     (status_vector             : PISC_STATUS;
597                                   blob_handle               : PISC_BLOB_HANDLE;
598                                   actual_seg_length         : PUShort;
599                                   seg_buffer_length         : UShort;
600 <                                 seg_buffer                : PChar): ISC_STATUS;
600 >                                 seg_buffer                : PByte): ISC_STATUS;
601                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
602  
603   Tisc_get_slice = function       (status_vector             : PISC_STATUS;
# Line 600 | Line 605 | Tisc_get_slice = function       (status_
605                                   tran_handle               : PISC_TR_HANDLE;
606                                   isc_arg4                  : PISC_QUAD;
607                                   isc_arg5                  : Short;
608 <                                 isc_arg6                  : PChar;
608 >                                 isc_arg6                  : PByte;
609                                   isc_arg7                  : Short;
610                                   isc_arg8                  : PISC_LONG;
611                                   isc_arg9                  : ISC_LONG;
# Line 608 | Line 613 | Tisc_get_slice = function       (status_
613                                   isc_arg11                 : PISC_LONG): ISC_STATUS;
614                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
615  
616 < Tisc_interprete = function      (buffer                    : PChar;
616 > Tisc_interprete = function      (buffer                    : PByte;
617                                   status_vector             : PPISC_STATUS): ISC_STATUS;
618                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
619  
# Line 625 | Line 630 | Tisc_open_blob2 = function      (status_
630                                   blob_handle               : PISC_BLOB_HANDLE;
631                                   blob_id                   : PISC_QUAD;
632                                   bpb_length                : Short;
633 <                                 bpb_buffer                : PChar): ISC_STATUS;
633 >                                 bpb_buffer                : PByte): ISC_STATUS;
634                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
635  
636   Tisc_prepare_transaction2 = function (status_vector        : PISC_STATUS;
637                                   tran_handle               : PISC_TR_HANDLE;
638                                   msg_length                : Short;
639 <                                 msg                       : PChar): ISC_STATUS;
639 >                                 msg                       : PByte): ISC_STATUS;
640                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
641  
642   Tisc_print_sqlerror = procedure (sqlcode                   : Short;
# Line 644 | Line 649 | Tisc_print_status = function   (status_v
649   Tisc_put_segment = function     (status_vector             : PISC_STATUS;
650                                   blob_handle               : PISC_BLOB_HANDLE;
651                                   seg_buffer_len            : UShort;
652 <                                 seg_buffer                : PChar): ISC_STATUS;
652 >                                 seg_buffer                : PByte): ISC_STATUS;
653                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
654  
655   Tisc_put_slice = function       (status_vector             : PISC_STATUS;
# Line 652 | Line 657 | Tisc_put_slice = function       (status_
657                                   tran_handle               : PISC_TR_HANDLE;
658                                   isc_arg4                  : PISC_QUAD;
659                                   isc_arg5                  : Short;
660 <                                 isc_arg6                  : PChar;
660 >                                 isc_arg6                  : PByte;
661                                   isc_arg7                  : Short;
662                                   isc_arg8                  : PISC_LONG;
663                                   isc_arg9                  : ISC_LONG;
# Line 663 | Line 668 | Tisc_que_events = function      (status_
668                                   db_handle                 : PISC_DB_HANDLE;
669                                   event_id                  : PISC_LONG;
670                                   length                    : Short;
671 <                                 event_buffer              : PChar;
671 >                                 event_buffer              : PByte;
672                                   event_function            : TISC_CALLBACK;
673                                   event_function_arg        : PVoid): ISC_STATUS;
674                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
# Line 687 | Line 692 | Tisc_start_transaction = function (statu
692                                   db_handle_count           : Short;
693                                   db_handle                 : PISC_DB_HANDLE;
694                                   tpb_length                : UShort;
695 <                                 tpb_address               : PChar): ISC_STATUS;
695 >                                 tpb_address               : PByte): ISC_STATUS;
696                                  cdecl;
697  
698   Tisc_sqlcode = function        (status_vector             : PISC_STATUS): ISC_LONG;
# Line 695 | Line 700 | Tisc_sqlcode = function        (status_v
700  
701  
702   Tisc_sql_interprete = procedure (sqlcode                   : Short;
703 <                                 buffer                    : PChar;
703 >                                 buffer                    : PAnsiChar;
704                                   buffer_length             : Short);
705                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
706  
707   Tisc_transaction_info = function (status_vector            : PISC_STATUS;
708                                   tran_handle               : PISC_TR_HANDLE;
709                                   item_list_buffer_length   : Short;
710 <                                 item_list_buffer          : PChar;
710 >                                 item_list_buffer          : PByte;
711                                   result_buffer_length      : Short;
712 <                                 result_buffer             : PChar): ISC_STATUS;
712 >                                 result_buffer             : PByte): ISC_STATUS;
713                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
714  
715   Tisc_transact_request = function (status_vector            : PISC_STATUS;
716                                   db_handle                 : PISC_DB_HANDLE;
717                                   tran_handle               : PISC_TR_HANDLE;
718                                   isc_arg4                  : UShort;
719 <                                 isc_arg5                  : PChar;
719 >                                 isc_arg5                  : PByte;
720                                   isc_arg6                  : UShort;
721 <                                 isc_arg7                  : PChar;
721 >                                 isc_arg7                  : PByte;
722                                   isc_arg8                  : UShort;
723 <                                 isc_arg9                  : PChar): ISC_STATUS;
723 >                                 isc_arg9                  : PByte): ISC_STATUS;
724                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
725  
726 < Tisc_vax_integer = function     (buffer                    : PChar;
726 > Tisc_vax_integer = function     (buffer                    : PByte;
727                                   length                    : Short): ISC_LONG;
728                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
729  
730 < Tisc_portable_integer = function (buffer                   : PChar;
730 > Tisc_portable_integer = function (buffer                   : PByte;
731                                   length                    : Short): ISC_INT64;
732                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
733  
# Line 753 | Line 758 | type
758      uid: Int;                        (** the user's id **)
759      gid: int;                        (** the user's group id **)
760      protocol: Int;                   (** protocol to use for connection **)
761 <    server: PChar;                   (** server to administer **)
762 <    user_name: PChar;                (** the user's name **)
763 <    password: PChar;                 (** the user's password **)
764 <    group_name: PChar;               (** the group name **)
765 <    first_name: PChar;               (** the user's first name **)
766 <    middle_name: PChar;              (** the user's middle name **)
767 <    last_name: PChar;                (** the user's last name **)
768 <    dba_user_name: PChar;            (** the dba user name **)
769 <    dba_password: PChar;             (** the dba password **)
761 >    server: PByte;                   (** server to administer **)
762 >    user_name: PByte;                (** the user's name **)
763 >    password: PByte;                 (** the user's password **)
764 >    group_name: PByte;               (** the group name **)
765 >    first_name: PByte;               (** the user's first name **)
766 >    middle_name: PByte;              (** the user's middle name **)
767 >    last_name: PByte;                (** the user's last name **)
768 >    dba_user_name: PByte;            (** the dba user name **)
769 >    dba_password: PByte;             (** the dba password **)
770    end;
771    PUserSecData = ^TUserSecData;
772  
# Line 785 | Line 790 | Tisc_compile_request = function (status_
790                                   db_handle                 : PISC_DB_HANDLE;
791                                   request_handle            : PISC_REQ_HANDLE;
792                                   isc_arg4                  : Short;
793 <                                 isc_arg5                  : PChar): ISC_STATUS;
793 >                                 isc_arg5                  : PByte): ISC_STATUS;
794                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
795  
796   Tisc_compile_request2 = function (status_vector            : PISC_STATUS;
797                                   db_handle                 : PISC_DB_HANDLE;
798                                   request_handle            : PISC_REQ_HANDLE;
799                                   isc_arg4                  : Short;
800 <                                 isc_arg5                  : PChar): ISC_STATUS;
800 >                                 isc_arg5                  : PByte): ISC_STATUS;
801                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
802  
803   Tisc_ddl = function             (status_vector             : PISC_STATUS;
804                                   db_handle                 : PISC_DB_HANDLE;
805                                   tran_handle               : PISC_TR_HANDLE;
806                                   isc_arg4                  : Short;
807 <                                 isc_arg5                  : PChar): ISC_STATUS;
807 >                                 isc_arg5                  : PByte): ISC_STATUS;
808                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
809  
810   Tisc_prepare_transaction = function (status_vector         : PISC_STATUS;
# Line 829 | Line 834 | Tisc_reconnect_transaction = function (s
834                                   db_handle                 : PISC_DB_HANDLE;
835                                   tran_handle               : PISC_TR_HANDLE;
836                                   isc_arg4                  : Short;
837 <                                 isc_arg5                  : PChar): ISC_STATUS;
837 >                                 isc_arg5                  : PByte): ISC_STATUS;
838                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
839  
840   Tisc_release_request = function (status_vector             : PISC_STATUS;
# Line 840 | Line 845 | Tisc_request_info = function    (status_
845                                   request_handle            : PISC_REQ_HANDLE;
846                                   isc_arg3                  : Short;
847                                   isc_arg4                  : Short;
848 <                                 isc_arg5                  : PChar;
848 >                                 isc_arg5                  : PByte;
849                                   isc_arg6                  : Short;
850 <                                 isc_arg7                  : PChar): ISC_STATUS;
850 >                                 isc_arg7                  : PByte): ISC_STATUS;
851                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
852  
853   Tisc_seek_blob = function       (status_vector             : PISC_STATUS;
# Line 884 | Line 889 | Tisc_wait_for_event = function  (status_
889                                   db_handle                 : PISC_DB_HANDLE;
890                                   length                    : Short;
891                                   event_buffer,
892 <                                 result_buffer             : PChar): ISC_STATUS;
892 >                                 result_buffer             : PByte): ISC_STATUS;
893                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
894  
895   (*******************************)
# Line 892 | Line 897 | Tisc_wait_for_event = function  (status_
897   (*******************************)
898   {$IFDEF IB5_ONLY}
899   Tisc_close = function           (status_vector             : PISC_STATUS;
900 <                                 isc_arg2                  : PChar): ISC_STATUS;
900 >                                 isc_arg2                  : PByte): ISC_STATUS;
901                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
902  
903   Tisc_declare = function         (status_vector             : PISC_STATUS;
904                                   isc_arg2,
905 <                                 isc_arg3                  : PChar): ISC_STATUS;
905 >                                 isc_arg3                  : PByte): ISC_STATUS;
906                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
907  
908   Tisc_describe = function        (status_vector             : PISC_STATUS;
909 <                                 isc_arg2                  : PChar;
909 >                                 isc_arg2                  : PByte;
910                                   isc_arg3                  : PSQLDA): ISC_STATUS;
911                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
912  
913   Tisc_describe_bind = function   (status_vector             : PISC_STATUS;
914 <                                 isc_arg2                  : PChar;
914 >                                 isc_arg2                  : PByte;
915                                   isc_arg3                  : PSQLDA): ISC_STATUS;
916                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
917  
918   Tisc_execute = function         (status_vector             : PISC_STATUS;
919                                   tran_handle               : PISC_TR_HANDLE;
920 <                                 isc_arg3                  : PChar;
920 >                                 isc_arg3                  : PByte;
921                                   isc_arg4                  : PSQLDA): ISC_STATUS;
922                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
923  
# Line 920 | Line 925 | Tisc_execute_immediate = function (statu
925                                   db_handle                 : PISC_DB_HANDLE;
926                                   tran_handle               : PISC_TR_HANDLE;
927                                   isc_arg4                  : PShort;
928 <                                 isc_arg5                  : PChar): ISC_STATUS;
928 >                                 isc_arg5                  : PByte): ISC_STATUS;
929                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
930  
931   Tisc_fetch = function           (status_vector             : PISC_STATUS;
932 <                                 isc_arg2                  : PChar;
932 >                                 isc_arg2                  : PByte;
933                                   isc_arg3                  : PSQLDA): ISC_STATUS;
934                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
935  
936   Tisc_open = function            (status_vector             : PISC_STATUS;
937                                   tran_handle               : PISC_TR_HANDLE;
938 <                                 isc_arg3                  : PChar;
938 >                                 isc_arg3                  : PByte;
939                                   isc_arg4                  : PSQLDA): ISC_STATUS;
940                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
941  
942   Tisc_prepare = function         (status_vector             : PISC_STATUS;
943                                   db_handle                 : PISC_DB_HANDLE;
944                                   tran_handle               : PISC_TR_HANDLE;
945 <                                 isc_arg4                  : PChar;
945 >                                 isc_arg4                  : PByte;
946                                   isc_arg5                  : PShort;
947 <                                 isc_arg6                  : PChar;
947 >                                 isc_arg6                  : PByte;
948                                   isc_arg7                  : PSQLDA): ISC_STATUS;
949                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
950   {$ELSE}
951   Tisc_close = function           (status_vector             : PISC_STATUS;
952 <                                 isc_arg2                  : PChar): ISC_STATUS;
952 >                                 isc_arg2                  : PByte): ISC_STATUS;
953                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
954  
955   Tisc_declare = function         (status_vector             : PISC_STATUS;
956                                   isc_arg2,
957 <                                 isc_arg3                  : PChar): ISC_STATUS;
957 >                                 isc_arg3                  : PByte): ISC_STATUS;
958                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
959  
960   Tisc_describe = function        (status_vector             : PISC_STATUS;
961 <                                 isc_arg2                  : PChar;
961 >                                 isc_arg2                  : PByte;
962                                   isc_arg3                  : PXSQLDA): ISC_STATUS;
963                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
964  
965   Tisc_describe_bind = function   (status_vector             : PISC_STATUS;
966 <                                 isc_arg2                  : PChar;
966 >                                 isc_arg2                  : PByte;
967                                   isc_arg3                  : PXSQLDA): ISC_STATUS;
968                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
969  
970   Tisc_execute = function         (status_vector             : PISC_STATUS;
971                                   tran_handle               : PISC_TR_HANDLE;
972 <                                 isc_arg3                  : PChar;
972 >                                 isc_arg3                  : PByte;
973                                   isc_arg4                  : PXSQLDA): ISC_STATUS;
974                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
975  
# Line 972 | Line 977 | Tisc_execute_immediate = function (statu
977                                   db_handle                 : PISC_DB_HANDLE;
978                                   tran_handle               : PISC_TR_HANDLE;
979                                   isc_arg4                  : PShort;
980 <                                 isc_arg5                  : PChar): ISC_STATUS;
980 >                                 isc_arg5                  : PByte): ISC_STATUS;
981                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
982  
983   Tisc_fetch = function           (status_vector             : PISC_STATUS;
984 <                                 isc_arg2                  : PChar;
984 >                                 isc_arg2                  : PByte;
985                                   isc_arg3                  : PXSQLDA): ISC_STATUS;
986                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
987  
988   Tisc_open = function            (status_vector             : PISC_STATUS;
989                                   tran_handle               : PISC_TR_HANDLE;
990 <                                 isc_arg3                  : PChar;
990 >                                 isc_arg3                  : PByte;
991                                   isc_arg4                  : PXSQLDA): ISC_STATUS;
992                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
993  
994   Tisc_prepare = function         (status_vector             : PISC_STATUS;
995                                   db_handle                 : PISC_DB_HANDLE;
996                                   tran_handle               : PISC_TR_HANDLE;
997 <                                 isc_arg4                  : PChar;
997 >                                 isc_arg4                  : PByte;
998                                   isc_arg5                  : PShort;
999 <                                 isc_arg6                  : PChar;
999 >                                 isc_arg6                  : PByte;
1000                                   isc_arg7                  : PXSQLDA): ISC_STATUS;
1001                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1002   {$ENDIF}
# Line 1004 | Line 1009 | Tisc_dsql_execute_m = function  (status_
1009                                   tran_handle               : PISC_TR_HANDLE;
1010                                   statement_handle          : PISC_STMT_HANDLE;
1011                                   isc_arg4                  : UShort;
1012 <                                 isc_arg5                  : PChar;
1012 >                                 isc_arg5                  : PByte;
1013                                   isc_arg6                  : UShort;
1014                                   isc_arg7                  : UShort;
1015 <                                 isc_arg8                  : PChar): ISC_STATUS;
1015 >                                 isc_arg8                  : PByte): ISC_STATUS;
1016                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1017  
1018   Tisc_dsql_execute2_m = function (status_vector             : PISC_STATUS;
1019                                   tran_handle               : PISC_TR_HANDLE;
1020                                   statement_handle          : PISC_STMT_HANDLE;
1021                                   isc_arg4                  : UShort;
1022 <                                 isc_arg5                  : PChar;
1022 >                                 isc_arg5                  : PByte;
1023                                   isc_arg6                  : UShort;
1024                                   isc_arg7                  : UShort;
1025 <                                 isc_arg8                  : PChar;
1025 >                                 isc_arg8                  : PByte;
1026                                   isc_arg9                  : UShort;
1027 <                                 isc_arg10                 : PChar;
1027 >                                 isc_arg10                 : PByte;
1028                                   isc_arg11                 : UShort;
1029                                   isc_arg12                 : UShort;
1030 <                                 isc_arg13                 : PChar): ISC_STATUS;
1030 >                                 isc_arg13                 : PByte): ISC_STATUS;
1031                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1032  
1033   Tisc_dsql_execute_immediate_m = function (status_vector    : PISC_STATUS;
1034                                   db_handle                 : PISC_DB_HANDLE;
1035                                   tran_handle               : PISC_TR_HANDLE;
1036                                   isc_arg4                  : UShort;
1037 <                                 isc_arg5                  : PChar;
1037 >                                 isc_arg5                  : PByte;
1038                                   isc_arg6                  : UShort;
1039                                   isc_arg7                  : UShort;
1040 <                                 isc_arg8                  : PChar;
1040 >                                 isc_arg8                  : PByte;
1041                                   isc_arg9                  : UShort;
1042                                   isc_arg10                 : UShort;
1043 <                                 isc_arg11                 : PChar): ISC_STATUS;
1043 >                                 isc_arg11                 : PByte): ISC_STATUS;
1044                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1045  
1046   Tisc_dsql_exec_immed3_m = function  (status_vector         : PISC_STATUS;
1047                                   db_handle                 : PISC_DB_HANDLE;
1048                                   tran_handle               : PISC_TR_HANDLE;
1049                                   isc_arg4                  : UShort;
1050 <                                 isc_arg5                  : PChar;
1050 >                                 isc_arg5                  : PByte;
1051                                   isc_arg6                  : UShort;
1052                                   isc_arg7                  : UShort;
1053 <                                 isc_arg8                  : PChar;
1053 >                                 isc_arg8                  : PByte;
1054                                   isc_arg9                  : UShort;
1055                                   isc_arg10                 : UShort;
1056 <                                 isc_arg11                 : PChar;
1056 >                                 isc_arg11                 : PByte;
1057                                   isc_arg12                 : UShort;
1058 <                                 isc_arg13                 : PChar;
1058 >                                 isc_arg13                 : PByte;
1059                                   isc_arg14                 : UShort;
1060                                   isc_arg15                 : UShort;
1061 <                                 isc_arg16                 : PChar): ISC_STATUS;
1061 >                                 isc_arg16                 : PByte): ISC_STATUS;
1062                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1063  
1064   Tisc_dsql_fetch_m = function    (status_vector             : PISC_STATUS;
1065                                   statement_handle          : PISC_STMT_HANDLE;
1066                                   isc_arg3                  : UShort;
1067 <                                 isc_arg4                  : PChar;
1067 >                                 isc_arg4                  : PByte;
1068                                   isc_arg5                  : UShort;
1069                                   isc_arg6                  : UShort;
1070 <                                 isc_arg7                  : PChar): ISC_STATUS;
1070 >                                 isc_arg7                  : PByte): ISC_STATUS;
1071                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1072  
1073   (*$ifdef SCROLLABLE_CURSORS*)
1074   Tisc_dsql_fetch2_m = function   (status_vector             : PISC_STATUS;
1075                                   statement_handle          : PISC_STMT_HANDLE;
1076                                   isc_arg3                  : UShort;
1077 <                                 isc_arg4                  : PChar;
1077 >                                 isc_arg4                  : PByte;
1078                                   isc_arg5                  : UShort;
1079                                   isc_arg6                  : UShort;
1080 <                                 isc_arg7                  : PChar;
1080 >                                 isc_arg7                  : PByte;
1081                                   isc_arg8                  : UShort;
1082                                   isc_arg9                  : Long): ISC_STATUS;
1083                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
# Line 1081 | Line 1086 | Tisc_dsql_fetch2_m = function   (status_
1086   Tisc_dsql_insert_m = function   (status_vector             : PISC_STATUS;
1087                                   statement_handle          : PISC_STMT_HANDLE;
1088                                   isc_arg3                  : UShort;
1089 <                                 isc_arg4                  : PChar;
1089 >                                 isc_arg4                  : PByte;
1090                                   isc_arg5                  : UShort;
1091                                   isc_arg6                  : UShort;
1092 <                                 isc_arg7                  : PChar): ISC_STATUS;
1092 >                                 isc_arg7                  : PByte): ISC_STATUS;
1093                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1094  
1095   Tisc_dsql_prepare_m = function  (status_vector             : PISC_STATUS;
1096                                   tran_handle               : PISC_TR_HANDLE;
1097                                   statement_handle          : PISC_STMT_HANDLE;
1098                                   isc_arg4                  : UShort;
1099 <                                 isc_arg5                  : PChar;
1099 >                                 isc_arg5                  : PByte;
1100                                   isc_arg6                  : UShort;
1101                                   isc_arg7                  : UShort;
1102 <                                 isc_arg8                  : PChar;
1102 >                                 isc_arg8                  : PByte;
1103                                   isc_arg9                  : UShort;
1104 <                                 isc_arg10                 : PChar): ISC_STATUS;
1104 >                                 isc_arg10                 : PByte): ISC_STATUS;
1105                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1106  
1107   Tisc_dsql_release = function    (status_vector             : PISC_STATUS;
1108 <                                 isc_arg2                  : PChar): ISC_STATUS;
1108 >                                 isc_arg2                  : PByte): ISC_STATUS;
1109                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1110  
1111   Tisc_embed_dsql_close = function(status_vector             : PISC_STATUS;
1112 <                                 isc_arg2                  : PChar): ISC_STATUS;
1112 >                                 isc_arg2                  : PByte): ISC_STATUS;
1113                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1114  
1115   Tisc_embed_dsql_declare = function  (status_vector         : PISC_STATUS;
1116 <                                 isc_arg2                  : PChar;
1117 <                                 isc_arg3                  : PChar): ISC_STATUS;
1116 >                                 isc_arg2                  : PByte;
1117 >                                 isc_arg3                  : PByte): ISC_STATUS;
1118                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1119  
1120   Tisc_embed_dsql_describe = function (status_vector         : PISC_STATUS;
1121 <                                 isc_arg2                  : PChar;
1121 >                                 isc_arg2                  : PByte;
1122                                   isc_arg3                  : UShort;
1123                                   isc_arg4                  : PXSQLDA): ISC_STATUS;
1124                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1125  
1126   Tisc_embed_dsql_describe_bind = function (status_vector    : PISC_STATUS;
1127 <                                 isc_arg2                  : PChar;
1127 >                                 isc_arg2                  : PByte;
1128                                   isc_arg3                  : UShort;
1129                                   isc_arg4                  : PXSQLDA): ISC_STATUS;
1130                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1131  
1132   Tisc_embed_dsql_execute = function  (status_vector         : PISC_STATUS;
1133                                   tran_handle               : PISC_TR_HANDLE;
1134 <                                 isc_arg3                  : PChar;
1134 >                                 isc_arg3                  : PByte;
1135                                   isc_arg4                  : UShort;
1136                                   isc_arg5                  : PXSQLDA): ISC_STATUS;
1137                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1138  
1139   Tisc_embed_dsql_execute2 = function (status_vector         : PISC_STATUS;
1140                                   tran_handle               : PISC_TR_HANDLE;
1141 <                                 isc_arg3                  : PChar;
1141 >                                 isc_arg3                  : PByte;
1142                                   isc_arg4                  : UShort;
1143                                   isc_arg5                  : PXSQLDA;
1144                                   isc_arg6                  : PXSQLDA): ISC_STATUS;
# Line 1143 | Line 1148 | Tisc_embed_dsql_execute_immed = function
1148                                   db_handle                 : PISC_DB_HANDLE;
1149                                   tran_handle               : PISC_TR_HANDLE;
1150                                   isc_arg4                  : UShort;
1151 <                                 isc_arg5                  : PChar;
1151 >                                 isc_arg5                  : PByte;
1152                                   isc_arg6                  : UShort;
1153                                   isc_arg7                  : PXSQLDA): ISC_STATUS;
1154                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1155  
1156   Tisc_embed_dsql_fetch = function(status_vector             : PISC_STATUS;
1157 <                                 isc_arg2                  : PChar;
1157 >                                 isc_arg2                  : PByte;
1158                                   isc_arg3                  : UShort;
1159                                   isc_arg4                  : PXSQLDA): ISC_STATUS;
1160                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1161  
1162   (*$ifdef SCROLLABLE_CURSORS*)
1163   Tisc_embed_dsql_fetch2 = function  (status_vector         : PISC_STATUS;
1164 <                                isc_arg2                  : PChar;
1164 >                                isc_arg2                  : PByte;
1165                                  isc_arg3                  : UShort;
1166                                  isc_arg4                  : PXSQLDA;
1167                                  isc_arg5                  : UShort;
# Line 1166 | Line 1171 | Tisc_embed_dsql_fetch2 = function  (stat
1171  
1172   Tisc_embed_dsql_open = function (status_vector             : PISC_STATUS;
1173                                   tran_handle               : PISC_TR_HANDLE;
1174 <                                 isc_arg3                  : PChar;
1174 >                                 isc_arg3                  : PByte;
1175                                   isc_arg4                  : UShort;
1176                                   isc_arg5                  : PXSQLDA): ISC_STATUS;
1177                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1178  
1179   Tisc_embed_dsql_open2 = function (status_vector            : PISC_STATUS;
1180                                   tran_handle               : PISC_TR_HANDLE;
1181 <                                 isc_arg3                  : PChar;
1181 >                                 isc_arg3                  : PByte;
1182                                   isc_arg4                  : UShort;
1183                                   isc_arg5                  : PXSQLDA;
1184                                   isc_arg6                  : PXSQLDA): ISC_STATUS;
1185                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1186  
1187   Tisc_embed_dsql_insert = function (status_vector           : PISC_STATUS;
1188 <                                 isc_arg2                  : PChar;
1188 >                                 isc_arg2                  : PByte;
1189                                   isc_arg3                  : UShort;
1190                                   isc_arg4                  : PXSQLDA): ISC_STATUS;
1191                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
# Line 1188 | Line 1193 | Tisc_embed_dsql_insert = function (statu
1193   Tisc_embed_dsql_prepare = function  (status_vector         : PISC_STATUS;
1194                                   db_handle                 : PISC_DB_HANDLE;
1195                                   tran_handle               : PISC_TR_HANDLE;
1196 <                                 isc_arg4                  : PChar;
1196 >                                 isc_arg4                  : PByte;
1197                                   isc_arg5                  : UShort;
1198 <                                 isc_arg6                  : PChar;
1198 >                                 isc_arg6                  : PByte;
1199                                   isc_arg7                  : UShort;
1200                                   isc_arg8                  : PXSQLDA): ISC_STATUS;
1201                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1202  
1203   Tisc_embed_dsql_release = function  (status_vector         : PISC_STATUS;
1204 <                                 isc_arg2                  : PChar): ISC_STATUS;
1204 >                                 isc_arg2                  : PByte): ISC_STATUS;
1205                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1206  
1207   (********************************)
# Line 1204 | Line 1209 | Tisc_embed_dsql_release = function  (sta
1209   (********************************)
1210  
1211   TBLOB_open = function           (blob_handle               : TISC_BLOB_HANDLE;
1212 <                                 isc_arg2                  : PChar;
1212 >                                 isc_arg2                  : PByte;
1213                                   isc_arg3                  : int): PBSTREAM;
1214                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1215  
# Line 1221 | Line 1226 | TBLOB_get = function           (isc_arg1
1226   TBLOB_display = function        (isc_arg1                  : PISC_QUAD;
1227                                   db_handle                 : TISC_DB_HANDLE;
1228                                   tran_handle               : TISC_TR_HANDLE;
1229 <                                 isc_arg4                  : PChar): Int;
1229 >                                 isc_arg4                  : PByte): Int;
1230                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1231  
1232   TBLOB_dump = function           (isc_arg1                  : PISC_QUAD;
1233                                   db_handle                 : TISC_DB_HANDLE;
1234                                   tran_handle               : TISC_TR_HANDLE;
1235 <                                 isc_arg4                  : PChar): Int;
1235 >                                 isc_arg4                  : PByte): Int;
1236                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1237  
1238   TBLOB_edit = function           (isc_arg1                  : PISC_QUAD;
1239                                   db_handle                 : TISC_DB_HANDLE;
1240                                   tran_handle               : TISC_TR_HANDLE;
1241 <                                 isc_arg4                  : PChar): Int;
1241 >                                 isc_arg4                  : PByte): Int;
1242                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1243  
1244   TBLOB_load = function           (isc_arg1                  : PISC_QUAD;
1245                                   db_handle                 : TISC_DB_HANDLE;
1246                                   tran_handle               : TISC_TR_HANDLE;
1247 <                                 isc_arg4                  : PChar): Int;
1247 >                                 isc_arg4                  : PByte): Int;
1248                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1249  
1250   TBLOB_text_dump = function      (isc_arg1                  : PISC_QUAD;
1251                                   db_handle                 : TISC_DB_HANDLE;
1252                                   tran_handle               : TISC_TR_HANDLE;
1253 <                                 isc_arg4                  : PChar): Int;
1253 >                                 isc_arg4                  : PByte): Int;
1254                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1255  
1256   TBLOB_text_load = function      (isc_arg1                  : PISC_QUAD;
1257                                   db_handle                 : TISC_DB_HANDLE;
1258                                   tran_handle               : TISC_TR_HANDLE;
1259 <                                 isc_arg4                  : PChar): Int;
1259 >                                 isc_arg4                  : PByte): Int;
1260                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1261  
1262   TBopen = function               (isc_arg1                  : PISC_QUAD;
1263                                   db_handle                 : TISC_DB_HANDLE;
1264                                   tran_handle               : TISC_TR_HANDLE;
1265 <                                 isc_arg4                  : PChar): Int;
1265 >                                 isc_arg4                  : PByte): Int;
1266                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1267  
1268   TBopen2 = function              (isc_arg1                  : PISC_QUAD;
1269                                   db_handle                 : TISC_DB_HANDLE;
1270                                   tran_handle               : TISC_TR_HANDLE;
1271 <                                 isc_arg4                  : PChar;
1271 >                                 isc_arg4                  : PByte;
1272                                   isc_arg5                  : UShort): PBSTREAM;
1273                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1274  
# Line 1271 | Line 1276 | TBopen2 = function              (isc_arg
1276   (** Other Misc functions       **)
1277   (********************************)
1278  
1279 < Tisc_ftof = function            (isc_arg1                  : PChar;
1279 > Tisc_ftof = function            (isc_arg1                  : PByte;
1280                                   isc_arg2                  : UShort;
1281 <                                 isc_arg3                  : PChar;
1281 >                                 isc_arg3                  : PByte;
1282                                   isc_arg4                  : UShort): ISC_LONG;
1283                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1284  
1285 < Tisc_print_blr = function       (isc_arg1                  : PChar;
1285 > Tisc_print_blr = function       (isc_arg1                  : PByte;
1286                                   isc_arg2                  : TISC_CALLBACK;
1287                                   isc_arg3                  : PVoid;
1288                                   isc_arg4                  : Short): ISC_STATUS;
# Line 1290 | Line 1295 | Tisc_qtoq = procedure           (isc_arg
1295                                   isc_arg2                  : PISC_QUAD);
1296                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1297  
1298 < Tisc_vtof = procedure           (isc_arg1                  : PChar;
1299 <                                 isc_arg2                  : PChar;
1298 > Tisc_vtof = procedure           (isc_arg1                  : PByte;
1299 >                                 isc_arg2                  : PByte;
1300                                   isc_arg3                  : UShort);
1301                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1302  
1303 < Tisc_vtov = procedure           (isc_arg1                  : PChar;
1304 <                                 isc_arg2                  : PChar;
1303 > Tisc_vtov = procedure           (isc_arg1                  : PByte;
1304 >                                 isc_arg2                  : PByte;
1305                                   isc_arg3                  : Short);
1306                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1307  
# Line 1314 | Line 1319 | Tisc_reset_fpe = function      (isc_arg1
1319  
1320   Tisc_service_attach = function  (status_vector             : PISC_STATUS;
1321                                   isc_arg2                  : UShort;
1322 <                                 isc_arg3                  : PChar;
1322 >                                 isc_arg3                  : PAnsiChar;
1323                                   service_handle            : PISC_SVC_HANDLE;
1324                                   isc_arg5                  : UShort;
1325 <                                 isc_arg6                  : PChar): ISC_STATUS;
1325 >                                 isc_arg6                  : PByte): ISC_STATUS;
1326                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1327  
1328   Tisc_service_detach = function (status_vector             : PISC_STATUS;
# Line 1328 | Line 1333 | Tisc_service_query = function   (status_
1333                                   service_handle            : PISC_SVC_HANDLE;
1334                                   recv_handle               : PISC_SVC_HANDLE;
1335                                   isc_arg4                  : UShort;
1336 <                                 isc_arg5                  : PChar;
1336 >                                 isc_arg5                  : PByte;
1337                                   isc_arg6                  : UShort;
1338 <                                 isc_arg7                  : PChar;
1338 >                                 isc_arg7                  : PByte;
1339                                   isc_arg8                  : UShort;
1340 <                                 isc_arg9                  : PChar): ISC_STATUS;
1340 >                                 isc_arg9                  : PByte): ISC_STATUS;
1341                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1342  
1343   Tisc_service_start = function  (status_vector             : PISC_STATUS;
1344                                  service_handle            : PISC_SVC_HANDLE;
1345                                  recv_handle               : PISC_SVC_HANDLE;
1346                                  isc_arg4                  : UShort;
1347 <                                isc_arg5                  : PChar): ISC_STATUS;
1347 >                                isc_arg5                  : PByte): ISC_STATUS;
1348                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1349  
1350   (*********************************)
# Line 1350 | Line 1355 | Tisc_compile_map = function     (status_
1355                                   form_handle               : PISC_FORM_HANDLE;
1356                                   request_handle            : PISC_REQ_HANDLE;
1357                                   isc_arg4                  : PShort;
1358 <                                 isc_arg5                  : PChar): ISC_STATUS;
1358 >                                 isc_arg5                  : PByte): ISC_STATUS;
1359                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1360  
1361   Tisc_compile_menu = function    (status_vector             : PISC_STATUS;
1362                                   form_handle               : PISC_FORM_HANDLE;
1363                                   request_handle            : PISC_REQ_HANDLE;
1364                                   isc_arg4                  : PShort;
1365 <                                 isc_arg5                  : PChar): ISC_STATUS;
1365 >                                 isc_arg5                  : PByte): ISC_STATUS;
1366                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1367  
1368   Tisc_compile_sub_map = function (status_vector             : PISC_STATUS;
1369                                   win_handle                : PISC_WIN_HANDLE;
1370                                   request_handle            : PISC_REQ_HANDLE;
1371                                   isc_arg4                  : PShort;
1372 <                                 isc_arg5                  : PChar): ISC_STATUS;
1372 >                                 isc_arg5                  : PByte): ISC_STATUS;
1373                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1374  
1375   Tisc_create_window = function   (status_vector             : PISC_STATUS;
1376                                   win_handle                : PISC_WIN_HANDLE;
1377                                   isc_arg3                  : PShort;
1378 <                                 isc_arg4                  : PChar;
1378 >                                 isc_arg4                  : PByte;
1379                                   isc_arg5                  : PShort;
1380                                   isc_arg6                  : PShort): ISC_STATUS;
1381                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
# Line 1392 | Line 1397 | Tisc_drive_menu = function      (status_
1397                                   win_handle                : PISC_WIN_HANDLE;
1398                                   request_handle            : PISC_REQ_HANDLE;
1399                                   isc_arg4                  : PShort;
1400 <                                 isc_arg5                  : PChar;
1400 >                                 isc_arg5                  : PByte;
1401                                   isc_arg6                  : PShort;
1402 <                                 isc_arg7                  : PChar;
1402 >                                 isc_arg7                  : PByte;
1403                                   isc_arg8                  : PShort;
1404                                   isc_arg9                  : PShort;
1405 <                                 isc_arg10                 : PChar;
1405 >                                 isc_arg10                 : PByte;
1406                                   isc_arg11                 : PISC_LONG): ISC_STATUS;
1407                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1408  
# Line 1422 | Line 1427 | Tisc_form_insert = function     (status_
1427   Tisc_get_entree = function      (status_vector             : PISC_STATUS;
1428                                   request_handle            : PISC_REQ_HANDLE;
1429                                   isc_arg3                  : PShort;
1430 <                                 isc_arg4                  : PChar;
1430 >                                 isc_arg4                  : PByte;
1431                                   isc_arg5                  : PISC_LONG;
1432                                   isc_arg6                  : PShort): ISC_STATUS;
1433                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
# Line 1435 | Line 1440 | Tisc_menu = function            (status_
1440                                   win_handle                : PISC_WIN_HANDLE;
1441                                   request_handle            : PISC_REQ_HANDLE;
1442                                   isc_arg4                  : PShort;
1443 <                                 isc_arg5                  : PChar): ISC_STATUS;
1443 >                                 isc_arg5                  : PByte): ISC_STATUS;
1444                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1445  
1446   Tisc_load_form = function       (status_vector             : PISC_STATUS;
# Line 1443 | Line 1448 | Tisc_load_form = function       (status_
1448                                   tran_handle               : PISC_TR_HANDLE;
1449                                   form_handle               : PISC_FORM_HANDLE;
1450                                   isc_arg5                  : PShort;
1451 <                                 isc_arg6                  : PChar): ISC_STATUS;
1451 >                                 isc_arg6                  : PByte): ISC_STATUS;
1452                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1453  
1454   Tisc_pop_window = function      (status_vector             : PISC_STATUS;
# Line 1453 | Line 1458 | Tisc_pop_window = function      (status_
1458   Tisc_put_entree = function      (status_vector             : PISC_STATUS;
1459                                   request_handle            : PISC_REQ_HANDLE;
1460                                   isc_arg3                  : PShort;
1461 <                                 isc_arg4                  : PChar;
1461 >                                 isc_arg4                  : PByte;
1462                                   isc_arg5                  : PISC_LONG): ISC_STATUS;
1463                                  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF}
1464  
# Line 1804 | Line 1809 | const
1809  
1810  
1811  
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
1812   (** XSQLDA_LENGTH is defined in C as a macro, but in Pascal we must defined it
1813     as a function... **)
1814   function XSQLDA_LENGTH(n: Long): Long;
1815  
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
1816   implementation
1817  
1818  
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
1819   function XSQLDA_LENGTH(n: Long): Long;
1820   (*  The C-macro reads like this:
1821     XSQLDA_LENGTH(n)     (sizeof (XSQLDA) + (n-1) * sizeof (XSQLVAR)) *)
# Line 1853 | Line 1823 | begin
1823    result := SizeOf(TXSQLDA) + ((n - 1) * SizeOf(TXSQLVAR));
1824   end;
1825  
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;
1826  
1827   end.
1828  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines