getting null values in fields

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
harithay
Participant
Posts: 106
Joined: Tue Dec 14, 2004 10:51 pm

getting null values in fields

Post by harithay »

hi all,

i am getting following warning. after 50 warninngs my job is aborting



nsartable..Transformer_1.DSLink17: DSD.BCIPut call to SQLExecute failed.
SQL statement:INSERT INTO uci.dbo.nsar(nsar_id, total_net_assets, change_in_tot_assets, foreign_exposure, diversified_fund, open_end_fund, fund_name, borrowing_name, cik, as_of_date, created_dtm, created_by, last_upd_dtm, last_upd_by) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?)
SQLSTATE=23000, DBMS.CODE=515
[DataStage][SQL Client][ODBC][DataDirect][ODBC SQL Server Driver][SQL Server]Cannot insert the value NULL into column 'fund_name', table 'uci.dbo.nsar'; column does not allow nulls. INSERT fails.
SQLSTATE=01000, DBMS.CODE=3621
[DataStage][SQL Client][ODBC][DataDirect][ODBC SQL Server Driver][SQL Server]The statement has been terminated.

nsar_id = 89
total_net_assets = NULL
change_in_tot_assets = NULL
foreign_exposure = NULL
diversified_fund = NULL
open_end_fund = NULL
fund_name = NULL
borrowing_name = NULL
cik = NULL
as_of_date = NULL
created_dtm = "2005-05-18 16:04:23.000"
created_by = "dbo"
last_upd_dtm = "2005-05-18 16:04:23.000"
last_upd_by = "dbo"

i need help to rectify this error.

tahnks in advance
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

What kind of help do you need? :? The problem is spelled out in the message:
Cannot insert the value NULL into column 'fund_name', table 'uci.dbo.nsar'; column does not allow nulls.
You are trying to put a null into a field that doesn't allow it. Stop doing that. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
harithay
Participant
Posts: 106
Joined: Tue Dec 14, 2004 10:51 pm

Post by harithay »

hi craig

I am loading data from sequential fiel to odbc, when i view the data from

databrowser i can able to see the input data ,


why it is saying for evry field that is mapping from input as 'null' (warnings)

if u have any idea please let me know
thanks
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

No way for me to know without either seeing your job or getting a better explanation as to exactly what it is doing to the data as it moves it through.

Is there a hash lookup involved? Are you using values from it even if the lookup fails? Have you tried debugging the job to watch the data flow through one link at a time?
-craig

"You can never have too many knives" -- Logan Nine Fingers
MaheshKumar Sugunaraj
Participant
Posts: 84
Joined: Thu Dec 04, 2003 9:55 pm

Post by MaheshKumar Sugunaraj »

Hi,

Could you please check the Type and Setting of the Nullable colums, You might have set it as "YES" for the Nullable columns in the COLUMNS tab and so data when inserting is giving the following issue:

nsartable..Transformer_1.DSLink17: DSD.BCIPut call to SQLExecute failed.
[DataStage][SQL Client][ODBC][DataDirect][ODBC SQL Server Driver][SQL Server]Cannot insert the value NULL into column 'fund_name', table 'uci.dbo.nsar'; column does not allow nulls. INSERT fails.


So it would be better if could check that.

Regards
SMK
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

By default, a zero-length string ("") in a sequential file is interpreted as NULL. This default can be overridden on the Format tab of a Sequential File stage. This is almost certainly the source of your null values.

The job aborts after 50 warnings be default. You can override this limit when submitting a run request (the Limits tab or -warn option), or change the default in Director (Tools > Options).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply