[db2 710/zOS1.4]: Newbie Help??: Why do I get those precompiler errors???

Francis ANDRE

[db2 710/zOS1.4]: Newbie Help??: Why do I get those precompiler errors???
Hi Listeners

Why do I get such error UNACCEPTABLE SQL STATEMENT (line 45, 47) when
declaring the host variable NUI-SYS-LANGUAGE

TIA for your help

Regards

FA

-----------------------------------------------------------
DB2 SQL PRECOMPILER VERSION 7 REL. 1.0
OPTIONS SPECIFIED: HOST(IBMCOB),SOURCE
OPTIONS USED - SPECIFIED OR DEFAULTED
ATTACH(TSO)
CONNECT(2)
DEC(15)
FLAG(I)
HOST(IBMCOB)
NOT KATAKANA
LINECOUNT(60)
MARGINS(8,72)
ONEPASS
OPTIONS
PERIOD
QUOTE
QUOTESQL
SOURCE
STDSQL(NO)
SQL(DB2)
NOXREF
DB2 SQL PRECOMPILER VERSION 7 REL. 1.0
1 IDENTIFICATION DIVISION.
2 PROGRAM-ID. UIMODULE.
...
...
40 03 NUI-SYS-CURS-COL PICTURE S9(03).
41 03 NUI-SYS-CURS-LINE PICTURE S9(03).
42 03 NUI-SYS-CURS-FIELD PICTURE S9(10).
43 03 NUI-SYS-CURSOR PICTURE S9(06).
44 03 NUI-SYS-DATA PICTURE S9(03).
45 EXEC SQL BEGIN DECLARE SECTION END-EXEC
46 03 NUI-SYS-LANGUAGE PICTURE S9(03).
47 EXEC SQL END DECLARE SECTION END-EXEC
48 03 NUI-SYS-LINE-COUNT PICTURE S9(05) OCCURS 32
TIMES.
49 03 NUI-SYS-LOG-LS PICTURE S9(03).
50 03 NUI-SYS-LOG-PS PICTURE S9(03).
51 03 NUI-SYS-PAGESIZE PICTURE S9(07).



DB2 SQL PRECOMPILER MESSAGES
DSNH312I E DSNHSMUD LINE 145 COL 23 UNDEFINED OR UNUSABLE HOST VARIABLE
"UNUSABLE HOST VARIABLE "ABX--INPUT-MSG-TEXT"
DSNH312I E DSNHSMUD LINE 148 COL 36 UNDEFINED OR UNUSABLE HOST VARIABLE
"NUI-SYS-LANGUAGE"
DSNH312I E DSNHSMUD LINE 149 COL 39 UNDEFINED OR UNUSABLE HOST VARIABLE
"ABX--INPUT-MSG-NR"
DSNH084I W DSNHLEXC LINE 45 COL 21 UNACCEPTABLE SQL STATEMENT
DSNH084I W DSNHLEXC LINE 47 COL 21 UNACCEPTABLE SQL STATEMENT
DSNH084I W DSNHLEXC LINE 61 COL 21 UNACCEPTABLE SQL STATEMENT
DSNH084I W DSNHLEXC LINE 63 COL 21 UNACCEPTABLE SQL STATEMENT
DB2 SQL PRECOMPILER STATISTICS
SOURCE STATISTICS
SOURCE LINES READ: 153
NUMBER OF SYMBOLS: 51
SYMBOL TABLE BYTES EXCLUDING ATTRIBUTES: 3912
THERE WERE 7 MESSAGES FOR THIS PROGRAM.
THERE WERE 0 MESSAGES SUPPRESSED BY THE FLAG OPTION.
153248 BYTES OF STORAGE WERE USED BY THE PRECOMPILER.



--------------------------------------------------------------------------------- Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". The IDUG DB2-L FAQ is at http://www.idugdb2-l.org. The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". The IDUG DB2-L FAQ is at http://www.idugdb2-l.org. The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm

Roger Miller

Re: [db2 710/zOS1.4]: Newbie Help??: Why do I get those precompiler errors???
(in response to Francis ANDRE)
Those error messages are on the EXEC SQL BEGIN and END DECLARE section,
which are not usually needed, so suggestion 1 is to remove them.
Suggestion 2 would be to use the BEGIN and END around the full structure,
rather than within a structure.

Roger Miller

On Thu, 8 Dec 2005 09:09:50 +0100, Francis ANDRE
<[login to unmask email]> wrote:

>Hi Listeners
>
>Why do I get such error UNACCEPTABLE SQL STATEMENT (line 45, 47) when
>declaring the host variable NUI-SYS-LANGUAGE
>
>TIA for your help
>
>Regards
>
>FA
>
>-----------------------------------------------------------
>DB2 SQL PRECOMPILER VERSION 7 REL. 1.0
>OPTIONS SPECIFIED: HOST(IBMCOB),SOURCE
>OPTIONS USED - SPECIFIED OR DEFAULTED
> ATTACH(TSO)
> CONNECT(2)
> DEC(15)
> FLAG(I)
> HOST(IBMCOB)
> NOT KATAKANA
> LINECOUNT(60)
> MARGINS(8,72)
> ONEPASS
> OPTIONS
> PERIOD
> QUOTE
> QUOTESQL
> SOURCE
> STDSQL(NO)
> SQL(DB2)
> NOXREF
>DB2 SQL PRECOMPILER VERSION 7 REL. 1.0
> 1 IDENTIFICATION DIVISION.
> 2 PROGRAM-ID. UIMODULE.
>...
>...
> 40 03 NUI-SYS-CURS-COL PICTURE S9(03).
> 41 03 NUI-SYS-CURS-LINE PICTURE S9(03).
> 42 03 NUI-SYS-CURS-FIELD PICTURE S9(10).
> 43 03 NUI-SYS-CURSOR PICTURE S9(06).
> 44 03 NUI-SYS-DATA PICTURE S9(03).
> 45 EXEC SQL BEGIN DECLARE SECTION END-EXEC
> 46 03 NUI-SYS-LANGUAGE PICTURE S9(03).
> 47 EXEC SQL END DECLARE SECTION END-EXEC
> 48 03 NUI-SYS-LINE-COUNT PICTURE S9(05) OCCURS 32
>TIMES.
> 49 03 NUI-SYS-LOG-LS PICTURE S9(03).
> 50 03 NUI-SYS-LOG-PS PICTURE S9(03).
> 51 03 NUI-SYS-PAGESIZE PICTURE S9(07).
>
>
>
>DB2 SQL PRECOMPILER MESSAGES
>DSNH312I E DSNHSMUD LINE 145 COL 23 UNDEFINED OR UNUSABLE HOST
VARIABLE
>"UNUSABLE HOST VARIABLE "ABX--INPUT-MSG-TEXT"
>DSNH312I E DSNHSMUD LINE 148 COL 36 UNDEFINED OR UNUSABLE HOST
VARIABLE
>"NUI-SYS-LANGUAGE"
>DSNH312I E DSNHSMUD LINE 149 COL 39 UNDEFINED OR UNUSABLE HOST
VARIABLE
>"ABX--INPUT-MSG-NR"
>DSNH084I W DSNHLEXC LINE 45 COL 21 UNACCEPTABLE SQL STATEMENT
>DSNH084I W DSNHLEXC LINE 47 COL 21 UNACCEPTABLE SQL STATEMENT
>DSNH084I W DSNHLEXC LINE 61 COL 21 UNACCEPTABLE SQL STATEMENT
>DSNH084I W DSNHLEXC LINE 63 COL 21 UNACCEPTABLE SQL STATEMENT
>DB2 SQL PRECOMPILER STATISTICS
>SOURCE STATISTICS
> SOURCE LINES READ: 153
> NUMBER OF SYMBOLS: 51
> SYMBOL TABLE BYTES EXCLUDING ATTRIBUTES: 3912
>THERE WERE 7 MESSAGES FOR THIS PROGRAM.
>THERE WERE 0 MESSAGES SUPPRESSED BY THE FLAG OPTION.
>153248 BYTES OF STORAGE WERE USED BY THE PRECOMPILER.
>
>

---------------------------------------------------------------------------------
Welcome to the IDUG DB2-L list. To unsubscribe, go to the archives and home page at http://www.idugdb2-l.org/archives/db2-l.html. From that page select "Join or Leave the list". The IDUG DB2-L FAQ is at http://www.idugdb2-l.org. The IDUG List Admins can be reached at [login to unmask email] Find out the latest on IDUG conferences at http://conferences.idug.org/index.cfm