Sort stage is not wrking

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
atul9806
Participant
Posts: 96
Joined: Tue Mar 06, 2012 6:12 am
Location: Pune
Contact:

Sort stage is not wrking

Post by atul9806 »

Hi guys
I am creating a server job, in which taking input from one table and applied sort stage to sort the table with a column and stor the data into other table
job is running fine, but not sorting the table

Image

I used the <column_name> <D>
for order by column name desc.

Please suggest

Thanks
Atul
Last edited by atul9806 on Wed Mar 07, 2012 2:04 am, edited 2 times in total.
kandyshandy
Participant
Posts: 597
Joined: Fri Apr 29, 2005 6:19 am
Location: Singapore

Post by kandyshandy »

You should give "Sort criteria, defining which Input Link's Column Names to sort on."
Kandy
_________________
Try and Try again…You will succeed atlast!!
atul9806
Participant
Posts: 96
Joined: Tue Mar 06, 2012 6:12 am
Location: Pune
Contact:

Post by atul9806 »

Hi there
this is my sorting criteria. I am taking the input from the user
Image

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

Post by ray.wurlod »

Sort probably is working, but the database server for your target table is storing rows in whatever order it feels like. It is a fundamental tenet of databases that storage order is under control only of the database engine.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
kandyshandy
Participant
Posts: 597
Joined: Fri Apr 29, 2005 6:19 am
Location: Singapore

Post by kandyshandy »

Atul, try giving like this

Code: Select all

#sorting#,#columnname#
Kandy
_________________
Try and Try again…You will succeed atlast!!
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

You are missing a fundamental point, the one Ray pointed out. To check your sorting, run the output to a flat file - tables have no 'sort' to them. If you want data out in a certain order, use an order by.
-craig

"You can never have too many knives" -- Logan Nine Fingers
atul9806
Participant
Posts: 96
Joined: Tue Mar 06, 2012 6:12 am
Location: Pune
Contact:

Post by atul9806 »

yes guys, you are right... I got the sorted data in a flat file
thanks again :)
Post Reply