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 |
|
); |
248 |
|
|
249 |
< |
function GetErrorMessage(ErrMess: TIBClientError): string; |
249 |
> |
function GetErrorMessage(ErrMess: TIBClientError): AnsiString; |
250 |
|
|
251 |
|
resourcestring |
252 |
|
{ generic strings used in code } |
268 |
|
SDatabaseFilter = 'Database Files (*.fdb; *.gdb)|*.gdb; *.fdb|All files (*.*)|*.*'; |
269 |
|
STrue = 'true'; |
270 |
|
SFalse = 'false'; |
271 |
+ |
SArray = '(array)'; |
272 |
+ |
SBlob = '(blob)'; |
273 |
|
|
274 |
|
implementation |
275 |
|
|
414 |
|
SPBIndexError = 'DPB Index out of range (%d)'; |
415 |
|
SPBParamTypeError = 'Invalid Request for DPB Param Type'; |
416 |
|
SDuplicateParamName = 'Blob or array parameter name must be unique (%s)'; |
417 |
< |
SInvalidArrayDimensions = 'Invalid number of array dimensions {%d)'; |
417 |
> |
SInvalidArrayDimensions = 'Invalid number of array dimensions (%d)'; |
418 |
|
SNotAMultiDatabaseTransaction = 'This is not a multi-database transaction'; |
419 |
|
SAttachmentListIndexError = 'Attachment List index out of range (%d)'; |
420 |
|
SNotAnArray = 'Table Column must be an array'; |
438 |
|
SInvalidParamCount = 'Invalid Parameter Count. %d expected, %d found'; |
439 |
|
SInvalidVariantType = 'Invalid variant type'; |
440 |
|
SServiceRunning = 'Cannot start a new service while an existing service is running'; |
441 |
+ |
SUniqueRelationReqd = 'All Output Fields must derived from the same table'; |
442 |
+ |
SInterfaceNotSupported = 'Interface not supported; Guid %s not found'; |
443 |
+ |
SCharacterSetExists = 'Character set "%s" is already defined'; |
444 |
+ |
SUnknownUserCharSet = 'Unknown user character set "%s"'; |
445 |
|
|
446 |
|
const |
447 |
|
IBErrorMessages: array[TIBClientError] of string = ( |
603 |
|
SParamBufferOverflow, |
604 |
|
SInvalidParamCount, |
605 |
|
SInvalidVariantType, |
606 |
< |
SServiceRunning |
606 |
> |
SServiceRunning, |
607 |
> |
SUniqueRelationReqd, |
608 |
> |
SInterfaceNotSupported, |
609 |
> |
SCharacterSetExists, |
610 |
> |
SUnknownUserCharSet |
611 |
|
); |
612 |
|
|
613 |
< |
function GetErrorMessage(ErrMess: TIBClientError): string; |
613 |
> |
function GetErrorMessage(ErrMess: TIBClientError): AnsiString; |
614 |
|
begin |
615 |
|
Result := IBErrorMessages[ErrMess]; |
616 |
|
end; |