How to load CLOB Column?

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
sohasaid
Premium Member
Premium Member
Posts: 115
Joined: Tue May 20, 2008 3:02 am
Location: Cairo, Egypt

How to load CLOB Column?

Post by sohasaid »

Hi,

At my project, we had to migrate CLOB data including Arabic data and we've successed. I thought of sharing my experience, it could be useful for anybody.

We've followed these steps to load CLOB:

1. Source stage is Oracle connector or DRS connector stage.
If Oracle connector stage is used, don't enable LOB references.

2. Define CLOB column at source and destination stages as LongVarChar without specifying length, also don't define it as 'Unicode'.

3. For English data, I didn't find a problem loading it using default project NLS which is 'ISO-8859-1'.

To migrate Arabic data also successfully, we had to try different NLS and it has worked with 'ISO8859-6' and 'UTF8'.
4. Array Size and Transaction Size have to set as 1 and bulk load will not work of course with CLOB or LONG data type.

Source and destination database is Oracle and NLS_CHARACTERSET for both is AL32UTF8.

I didn't try this solution with LONG datatype, but it could work.

Hope this helps.
Regards.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Thanks for posting that!
-craig

"You can never have too many knives" -- Logan Nine Fingers
sohasaid
Premium Member
Premium Member
Posts: 115
Joined: Tue May 20, 2008 3:02 am
Location: Cairo, Egypt

Post by sohasaid »

Good news for LONG as well! :)

It has worked with the same configuration except that source stage has to be Oracle connector stage because it's a MUST to 'Enable LOB references' to make it works.

Also it has loaded Arabic data with NLS of 'ISO8859-6'

Regards.
vamsi.4a6
Participant
Posts: 334
Joined: Sun Jan 22, 2012 7:06 am
Contact:

Post by vamsi.4a6 »

Could you please clarify below doubt.

Suppose If in a single Job we are using both english and Arabic data ,which NLS Settings we have to use and also could you please explain why you selected the following NLS(with 'ISO8859-6' and 'UTF8').
sohasaid
Premium Member
Premium Member
Posts: 115
Joined: Tue May 20, 2008 3:02 am
Location: Cairo, Egypt

Post by sohasaid »

vamsi.4a6 wrote: which NLS Settings we have to use?
'ISO8859-6' suppose to work fine.

For second point, I've tried multiple NLS until it has worked with 'ISO8859-6' on one schema and 'UTF8' on another one.

I think choosing the right NLS is dependent on your database's NLS character set.

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

Post by ray.wurlod »

ISO8859-x (for any x) includes "ASCII" characters.
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