Reading from Active Directory in Datastage 8.1

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
dganeshm
Premium Member
Premium Member
Posts: 91
Joined: Tue Aug 11, 2009 3:26 pm

Reading from Active Directory in Datastage 8.1

Post by dganeshm »

Hi All,

Is it possible to read data from Active Directory (LDAP) and load into a table (Any Database for that matter). If yes how should I go about it. Any help is greatly appreciated.

Regards,
dganeshm
Regards,
Ganesh
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

JavaPack will do it nicely. You write your own class that reads your LDAP structure and integrates with the JavaPack api to write resulting data to a DataStage link.......DataStage invokes it from the one of the Java stages when the job is executed.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
dganeshm
Premium Member
Premium Member
Posts: 91
Joined: Tue Aug 11, 2009 3:26 pm

Post by dganeshm »

eostic wrote:JavaPack will do it nicely. You write your own class that reads your LDAP structure and integrates with the JavaPack api to write resulting data to a DataStage link.......DataStage invokes it from the one of the Java stages when the job is executed.

Ernie
Hi Ernie,

Thanks for the advice, I did write the java program and is ready to go.. now the problem i am facing is I am on a 3 tier architecture.. Websphere on 1 Box, Datastage Engine on the another. I am not sure where to put the class files and the ldap jar and set the class path, when I do a 'which java' on the Engine box it says no java.. wondering from where I should use java and how to set the classpath and java home for this one..
Regards,
Ganesh
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

....using JavaPack means more than just writing a stand alone class....sorry I wasn't more explicit. You write your class according to the api as defined for JavaPack (it's not hard to adapt an existing one). Search thru the forum here...there are a ton of threads on it...I also have a sample at my blog url listed below.

...basically, you will be adapting your class so that the DataStage Job can invoke it in a local jvm (that DataStage loads) and then "talk" to it via input and output links......

...JavaPack is very well documented also...

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Hmmm... we did this using Perl writting to standard out. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
dganeshm
Premium Member
Premium Member
Posts: 91
Joined: Tue Aug 11, 2009 3:26 pm

Post by dganeshm »

eostic wrote:....using JavaPack means more than just writing a stand alone class....sorry I wasn't more explicit. You write your class according to the api as defined for JavaPack (it's not hard to adapt an existing one). Search thru the forum here...there are a ton of threads on it...I also have a sample at my blog url listed below.

...basically, you will be adapting your class so that the DataStage Job can invoke it in a local jvm (that DataStage loads) and then "talk" to it via input and output links......

...JavaPack is very well documented also...

Ernie
Hey Ernie,

I have actually written the Java class extending the Stage class using the tr4j.jar. The issue I am facing where should I be placing the java class..so that I can invoke it in the Java Client stage..
And what should I be giving in the Options tab of the Java Client stage in the JVM options??

Regards,
Ganesh
Regards,
Ganesh
Post Reply