View Issue Details

IDProjectCategoryView StatusLast Update
0026571FPCDatabasepublic2015-08-29 23:03
ReporterBigChimpAssigned ToMichael Van Canneyt 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Platformx64 (with x86 compiler)OSWindowsOS VersionWindows 7
Product Version2.7.1Product Build28336 
Target Version3.0.0Fixed in Version3.0.0 
Summary0026571: TSQLScript fails if there are comments in stored procedure creation scripts
DescriptionStored procedures creation statements with comments in them are not processed correctly.

Example:
SET TERM ^ ;

CREATE PROCEDURE givetheanswer
RETURNS (ANSWER INTEGER)
AS
BEGIN
  -- bigger procedures often need comments.
  FOR
    select 42 from rdb$database into :ANSWER
  DO
    SUSPEND;
END^

SET TERM ; ^

Result: error:
 FBScript.execute failed: GDS error 335544569( : PrepareStatement :
  -Dynamic SQL Error
  -SQL error code = -104
  -Token unknown - line 8, column 3
  -DO)

Workaround is setting CommentsInSQL to false but that removes comments that may be needed for clarity in complicated scripts.

See test application
Tagssqlscript
Fixed in Revision30306
FPCOldBugId0
FPCTarget
Attached Files

Activities

Reinier Olislagers

2014-08-08 11:29

developer  

sqlscriptbug_storedproc.zip (2,303 bytes)

Issue History

Date Modified Username Field Change
2014-08-08 11:29 Reinier Olislagers New Issue
2014-08-08 11:29 Reinier Olislagers File Added: sqlscriptbug_storedproc.zip
2014-08-08 13:14 Reinier Olislagers Tag Attached: sqlscript
2014-09-03 14:48 Reinier Olislagers Assigned To => Michael Van Canneyt
2014-09-03 14:48 Reinier Olislagers Status new => assigned
2015-03-24 14:10 Michael Van Canneyt Fixed in Revision => 30306
2015-03-24 14:10 Michael Van Canneyt Status assigned => resolved
2015-03-24 14:10 Michael Van Canneyt Fixed in Version => 3.1.1
2015-03-24 14:10 Michael Van Canneyt Resolution open => fixed
2015-03-24 14:10 Michael Van Canneyt Target Version => 3.0.0
2015-08-29 23:03 Joost van der Sluis Fixed in Version 3.1.1 => 3.0.1