TechTip: Easier Detection of SQL Syntax Errors with iSeries Navigator

SQL
Typography
  • Smaller Small Medium Big Bigger
  • Default Helvetica Segoe Georgia Times
As with syntax errors in any language, SQL syntax errors can be hard to chase down, and programmers count on development tools to help them. For example, the RUNSQLSTM CL command produces a spool file that lists the line number and character position of the keyword causing the SQL syntax error. Until recently, the SQL Script window in iSeries Navigator did not provide this level of error detection. In the past, iSeries Navigator would highlight the entire SQL statement.

With V5R2 (and V5R1 via PTF), iSeries Navigator has been enhanced to point to the exact SQL keyword causing the syntax error. In the example shown below, note that only the "SQLC" keyword is highlighted, rather than the entire CREATE PROCEDURE statement.

http://www.mcpressonline.com/articles/images/2002/Detect%20SQL%20Syntax%20Errors%20with%20iSeries%20NavigatorV400.png
(Click image to enlarge.)
 

The V5R1 version of this enhancement can be obtained by loading the iSeries Access (formerly Client Access) V5R1 Service Pack released in December 2002.

Kent Milligan is DB2 UDB Technology Specialist on IBM's eServer Solutions Enablement team. He spent the first seven years at IBM as a member of the DB2 development team in Rochester. He can be reached at This email address is being protected from spambots. You need JavaScript enabled to view it..

BLOG COMMENTS POWERED BY DISQUS

LATEST COMMENTS

Support MC Press Online

$0.00 Raised:
$