Page 1 of 1

Surrogate Key Generator Invalid Argument

Posted: Wed Oct 01, 2008 8:08 am
by mrloboda
Hello,

I am trying to initialize a state file through the surrogate key generator stage. However, I'm receiving the following error message from DataStage for my provided input into the surrogate key generator stage:

Surrogate_Key_Generator_3,0: Unable to write to state file /usr/local/dpbmdss/data/whs_pbmdss_dss20_dev/keymgmt/mrl_batch_extract_detail_skey.sf: Invalid argument.

The state file has been successfully created through a separate job and the input into this initialization is a dump of a table's surrogate keys. For the sake of testing, I dumped the surrogate keys into an input sequential file. The state file initialization job design is as follows:

SEQ_File -> Surrogate_Key_Gen

I've noticed that with an input of the following, I receive the error described above:
2011
2015
2019
2023
2027
2031
2035
3001
4005
5004
12001
14002
14006
19002
23002
29001
32004

However, if I divide this test data into 2 distinct subsets and reinitialize the state file with each subset separately, the job runs fine. I am confused on why the state file cannot be initialized with the above input, but yet works with subsets of the same data. Any thoughts on this matter would be greatly appreciated.

Posted: Wed Oct 01, 2008 3:13 pm
by ray.wurlod
Why would you have more than one value in the state file?

The state file is intended to "deliver the next surrogate key value".