Page 1 of 2

Number of rows in a data set

Posted: Tue Dec 12, 2006 4:36 pm
by abc123
How do I know I many rows are ther in a dataset? I do find it out?

Posted: Tue Dec 12, 2006 4:45 pm
by DSguru2B
By the command dsrecords mydataset.ds. For more info check this post.

Posted: Tue Dec 12, 2006 5:08 pm
by abc123
When I do:
dsrecords mydataset.ds
I get "command not found".

Posted: Tue Dec 12, 2006 5:41 pm
by ray.wurlod
It's a DataStage command, so it's in one of the DataStage bin directories.

$APT_ORCHHOME/bin/dsrecords

You can also use the Data Set Management utility in the Manager client.

Posted: Tue Dec 12, 2006 6:34 pm
by abc123
ray, thank you for your response. When I do:

$APT_ORCHHOME/bin/dsrecords Myfile.ds

I get the following:

/home/dsadm/Ascential/DataStage/PXEngine/bin/dsrecords: error while loading shared libraries: liborchi686.so: cannot open shared object file: No such file or directory

May be I don't have the library installed?

Posted: Tue Dec 12, 2006 6:55 pm
by jhmckeever
You need to make sure your $APT_ORCHHOME/lib directory is in your library search path. This path is defined by the environment variable SHLIB_PATH, LIBPATH, or LD_LIBRARY_PATH, depending upon your system.

E.g.

Code: Select all

SHLIB_PATH=$APT_ORCHHOME/lib:$SHLIB_PATH;export SHLIB_PATH
HTH,
J.

Posted: Tue Dec 12, 2006 7:18 pm
by ray.wurlod
You didn't execute the dsenv script.

Posted: Tue Dec 12, 2006 10:22 pm
by abc123
How do I execute the dsenv script?

I went through the posts in this forum and found some responses. Some of them have lines which probably should be in the environment script but I am not sure. Also, I log in to the UNIX box using my own ID. If I execute the dsenv script, is that going to be for me or for all users?

Thanks.

Posted: Tue Dec 12, 2006 10:28 pm
by DSguru2B
It will only be for your id for that particular terminal only. Do this

Code: Select all

cd $DSHOME 
. ./dsenv

Posted: Tue Dec 12, 2006 10:32 pm
by kumar_s
Or include this in your .profile so that it can be maintained for all the sessions for that user id. You can prescribe the same for other users as well.

Posted: Wed Dec 13, 2006 11:36 am
by Nageshsunkoji
If you are not able to do, whatever mentioned by our DSxians....
Just go to the Dataset Management tool in Designer/Manager. Just select your file it will shoe number of rows in each node. Is it ok for you ?

Posted: Wed Dec 13, 2006 1:10 pm
by splayer
DSGuru2B, I did:

cd $DSHOME
. ./dsenv

Both seemed to have worked. However, I still get the same error. No change at all.

Posted: Wed Dec 13, 2006 1:12 pm
by DSguru2B
ok then try this

Code: Select all

cd $DSHOME
sh dsenv

Posted: Wed Dec 13, 2006 1:30 pm
by abc123
Still the same problem. It is kind of strange. It works for everyone else. I must be missing something.

Posted: Wed Dec 13, 2006 1:45 pm
by DSguru2B
The id you are using to log into unix, is that the same id you use to log into datastage?