Subject | Dynamic statement construction and BLOB variables in SP |
---|---|
Author | Miroslav Penchev |
Post date | 2006-07-24T10:12:13Z |
Hello,
I have a problem executing that simple SP:
CREATE PROCEDURE NEW_PROCEDURE
as
declare variable from_part blob sub_type 1 segment size 80;
declare variable temp_str blob sub_type 1 segment size 80;
begin
from_part = 'VIEW_DOCUMENT_DATA';
temp_str = 'SELECT * FROM ' || :from_part;
end
On execution of second line I get error "Column unknown.
VIEW_DOCUMENT_DATA".
I am try to assemble a complex SQL statement to execute it with EXECUTE
STATEMENT. I am missing something? If local variables are VARCHARs
everything is OK.
TIA,
--
Miroslav Penchev.
I have a problem executing that simple SP:
CREATE PROCEDURE NEW_PROCEDURE
as
declare variable from_part blob sub_type 1 segment size 80;
declare variable temp_str blob sub_type 1 segment size 80;
begin
from_part = 'VIEW_DOCUMENT_DATA';
temp_str = 'SELECT * FROM ' || :from_part;
end
On execution of second line I get error "Column unknown.
VIEW_DOCUMENT_DATA".
I am try to assemble a complex SQL statement to execute it with EXECUTE
STATEMENT. I am missing something? If local variables are VARCHARs
everything is OK.
TIA,
--
Miroslav Penchev.