Subject | Re: Help me for BLOB Append with any string |
---|---|
Author | robertgilland |
Post date | 2007-06-21T03:00:21Z |
Using FreeUDFLib do the following
CREATE PROCEDURE ADDTOMYBLOB( MYVARCHAR VARCHAR(100))
AS
DECLARE VARIABLE MYTEMPVARCHAR VARCHAR(30000)
BEGIN
SELECT BLOBASPCHAR(MYBLOB)
FROM BLOBTABLE
INTO MYTEMPVARCHAR;
IF( MYTEMPVARCHAR IS NULL )THEN
MYTEMPVARCHAR = MYVARCHAR;
ELSE
MYTEMPVARCHAR = MYTEMPVARCHAR || MYVARCHAR;
UPDATE BLOBTABLE
SET MYBLOB = STRBLOB(MYTEMPVARCHAR);
END
Done and dusted.
CREATE PROCEDURE ADDTOMYBLOB( MYVARCHAR VARCHAR(100))
AS
DECLARE VARIABLE MYTEMPVARCHAR VARCHAR(30000)
BEGIN
SELECT BLOBASPCHAR(MYBLOB)
FROM BLOBTABLE
INTO MYTEMPVARCHAR;
IF( MYTEMPVARCHAR IS NULL )THEN
MYTEMPVARCHAR = MYVARCHAR;
ELSE
MYTEMPVARCHAR = MYTEMPVARCHAR || MYVARCHAR;
UPDATE BLOBTABLE
SET MYBLOB = STRBLOB(MYTEMPVARCHAR);
END
Done and dusted.