execute statement ignores the text of the SQL-query after a comment of the form 
"-"
-----------------------------------------------------------------------------------

                 Key: CORE-5783
                 URL: http://tracker.firebirdsql.org/browse/CORE-5783
             Project: Firebird Core
          Issue Type: Bug
            Reporter: Polesov


If the text of the SQL query executed in the execute statement contains 
comments "-", then starting with the "-" characters, all text is ignored to the 
end.

For example:

create or alter procedure STMT_ERR
returns (
    LEN integer,
    NAME varchar(100))
as
  declare variable SQL blob;
begin
  SQL =
'select RDB$FIELD_LENGTH, RDB$FIELD_NAME
  from RDB$FIELDS
 where not RDB$FIELD_NAME is null
-- comment
   and RDB$FIELD_LENGTH > 2
 order by RDB$FIELD_LENGTH
';

  for
    execute statement ( :SQL )
    into :LEN, :NAME
  do
    suspend;
end


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://tracker.firebirdsql.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Firebird-Devel mailing list, web interface at 
https://lists.sourceforge.net/lists/listinfo/firebird-devel

Reply via email to