60 |
|
{ } |
61 |
|
{************************************************************************} |
62 |
|
unit FBMessages; |
63 |
+ |
{$IFDEF MSWINDOWS} |
64 |
+ |
{$DEFINE WINDOWS} |
65 |
+ |
{$ENDIF} |
66 |
|
|
67 |
|
{$IFDEF FPC} |
68 |
< |
{$mode objfpc}{$H+} |
68 |
> |
{$mode delphi} |
69 |
|
{$codepage UTF8} |
70 |
|
{$ENDIF} |
71 |
|
|
239 |
|
ibxeParamBufferOverflow, |
240 |
|
ibxeInvalidParamCount, |
241 |
|
ibxeInvalidVariantType, |
242 |
< |
ibxeServiceRunning |
242 |
> |
ibxeServiceRunning, |
243 |
> |
ibxeUniqueRelationReqd, |
244 |
> |
ibxeInterfaceNotSupported, |
245 |
> |
ibxeCharacterSetExists, |
246 |
> |
ibxeUnknownUserCharSet, |
247 |
> |
ibxeUninitializedInputParameter, |
248 |
> |
ibxeNegativeGenerator |
249 |
|
); |
250 |
|
|
251 |
< |
function GetErrorMessage(ErrMess: TIBClientError): string; |
251 |
> |
function GetErrorMessage(ErrMess: TIBClientError): AnsiString; |
252 |
|
|
253 |
|
resourcestring |
254 |
|
{ generic strings used in code } |
270 |
|
SDatabaseFilter = 'Database Files (*.fdb; *.gdb)|*.gdb; *.fdb|All files (*.*)|*.*'; |
271 |
|
STrue = 'true'; |
272 |
|
SFalse = 'false'; |
273 |
+ |
SArray = '(array)'; |
274 |
+ |
SBlob = '(blob)'; |
275 |
|
|
276 |
|
implementation |
277 |
|
|
416 |
|
SPBIndexError = 'DPB Index out of range (%d)'; |
417 |
|
SPBParamTypeError = 'Invalid Request for DPB Param Type'; |
418 |
|
SDuplicateParamName = 'Blob or array parameter name must be unique (%s)'; |
419 |
< |
SInvalidArrayDimensions = 'Invalid number of array dimensions {%d)'; |
419 |
> |
SInvalidArrayDimensions = 'Invalid number of array dimensions (%d)'; |
420 |
|
SNotAMultiDatabaseTransaction = 'This is not a multi-database transaction'; |
421 |
|
SAttachmentListIndexError = 'Attachment List index out of range (%d)'; |
422 |
|
SNotAnArray = 'Table Column must be an array'; |
440 |
|
SInvalidParamCount = 'Invalid Parameter Count. %d expected, %d found'; |
441 |
|
SInvalidVariantType = 'Invalid variant type'; |
442 |
|
SServiceRunning = 'Cannot start a new service while an existing service is running'; |
443 |
+ |
SUniqueRelationReqd = 'All Output Fields must derived from the same table'; |
444 |
+ |
SInterfaceNotSupported = 'Interface not supported; Guid %s not found'; |
445 |
+ |
SCharacterSetExists = 'Character set "%s" is already defined'; |
446 |
+ |
SUnknownUserCharSet = 'Unknown user character set "%s"'; |
447 |
+ |
SUninitializedInputParameter = 'SQL Param No. %d (%s) is uninitialised'; |
448 |
+ |
SNegativeGenerator = 'A Generator Increment cannot be negative'; |
449 |
|
|
450 |
|
const |
451 |
|
IBErrorMessages: array[TIBClientError] of string = ( |
607 |
|
SParamBufferOverflow, |
608 |
|
SInvalidParamCount, |
609 |
|
SInvalidVariantType, |
610 |
< |
SServiceRunning |
610 |
> |
SServiceRunning, |
611 |
> |
SUniqueRelationReqd, |
612 |
> |
SInterfaceNotSupported, |
613 |
> |
SCharacterSetExists, |
614 |
> |
SUnknownUserCharSet, |
615 |
> |
SUninitializedInputParameter, |
616 |
> |
SNegativeGenerator |
617 |
|
); |
618 |
|
|
619 |
< |
function GetErrorMessage(ErrMess: TIBClientError): string; |
619 |
> |
function GetErrorMessage(ErrMess: TIBClientError): AnsiString; |
620 |
|
begin |
621 |
|
Result := IBErrorMessages[ErrMess]; |
622 |
|
end; |