Page 1 of 1

fatal error

Posted: Mon May 14, 2012 8:28 pm
by hargun
Hi,

i am getting the following fatal error

Job design
lookup seq file with Db2 database 1 and put ino target table


Db2 database1
.
.
seq file......................lkup......................xfm..............>db2 database


The follwing error coming from reference Db2 database 1
db2_Job_Def_Group,0: DB2 reported: SQLSTATE = 42S22: Native Error Code = -206: Msg = [IBM][CLI Driver][DB2/LINUXX8664] SQL0206N "DEFN_NUM" is not valid in the context where it is used. SQLSTATE=42703 [:0]


i have used the following query
select 1 as batchdummy,max(job_batch_gk) AS JOB_BATCH_GK_REF from AUDIT#psdaDB2_LUW_EDW.pvDBEnvironment#.JOB_BATCH where job_defn_num=#defn_num# and job_group_num=#group_num#
#def_num # and group_num# and #psdaDB2_LUW_EDW.pvDBEnvironment# and #psdafilelocation# are job parameters

I just copy the same job with all same parameters just seq file is different
i don't know why its showing where as already existing job runs fine .

Re: fatal error

Posted: Mon May 14, 2012 8:32 pm
by SURA
Did you changed the target table name?

Posted: Tue May 15, 2012 7:29 am
by hargun
hi sura,

No i didn't change the target table.

Posted: Tue May 15, 2012 10:12 am
by sreewin7
Hey,

Are you testing this job in dev or prod?

1)Dev:- Can you please double check all parameters are same as old job, some times in the administration, admin will change few parameters, due to that job may be aborted with fatal errors.

2) try to load the same data in to peek , if you are using parellel job and let me know the results.

Thanks
Sree

Posted: Tue May 15, 2012 11:04 am
by rameshrr3
Any issue with runtime column propogation being turned on or ( Off ) in the job?

I dont think its a databse table permissions change since your copy job works fine.

Can you compile & run the job in trace mode and see spurious column names or structures that dont belong in your job

Posted: Tue May 15, 2012 4:43 pm
by ray.wurlod
The error message is complaining about "DEFN_NUM". Maybe you left an underscore out of "JOB_DEFN_NUM".

Re: fatal error

Posted: Tue May 15, 2012 5:24 pm
by SURA
hargun wrote:
#def_num # and group_num# and #psdaDB2_LUW_EDW.pvDBEnvironment# and #psdafilelocation# are job parameters
If you check the above from your comments

Code: Select all

#def_num #  is good whereas #def_num # and group_num# and  is not

missing # in the group_num.

It is typo or is it how you have it in the query?