From: Klaus M. <km...@1a...> - 2008-07-09 14:34:11
|
Hi, I am using a UDF library with VS2008 and FirebirdSql.Data.FirebirdClient version v2.0.50727 I have done the UDF library with Delphi 2005 There is a function to get a file from the server: procedure GETFILE(FileName : PChar; Blob : PBlob); cdecl ; export; DECLARE EXTERNAL FUNCTION F_GETFILE CSTRING(255) CHARACTER SET NONE RETURNS BLOB FREE_IT ENTRY_POINT 'GETFILE' MODULE_NAME 'mydll.dll'; select F_GETFILE(''c:\test.txt'') from rdb$database this works fine. I get a query with the blob in first column. Now I need to send the file back to the server: procedure SETFILE(FileName : PChar; Blob : PBlob; var ReturnCode : integer); cdecl ; export; DECLARE EXTERNAL FUNCTION F_SETFILE CSTRING(255) CHARACTER SET NONE, BLOB RETURNS INTEGER FREE_IT ENTRY_POINT 'SETFILE' MODULE_NAME 'mydll.dll'; How does the SQL statement look like to get the blob to the function? Many thanks in advance Klaus |