We can precompile the DB2 program succesfully without declaring the table.According to the theory precompile will check the syntax of the SQL statements refering the table declaration in the DECLGEN.But without that also it is precompiling successfully.Please let me explain what exactly the process of precompilation.
Joined: 22 Nov 2005 Posts: 700 Location: Troy, Michigan USA
Yes, you can per compile a program without including the declgen if you do not use the cobol declgen copybook as host variables. The pre compiler will check syntax but cannot check valid columns. And the pre compiler will generate many warning messages for you for anything it cannot reconcile. Any un-reconcilable statements will cause an error in the bind.