Difference between a Filter stage and Switch Stage

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
sshettar
Premium Member
Premium Member
Posts: 264
Joined: Thu Nov 30, 2006 10:37 am

Difference between a Filter stage and Switch Stage

Post by sshettar »

Hi all,

Just wanted to know what is the difference between a filter stage and switch stage .
as far as i know both do the same job.

correct me if i'm wrong and could some one explain the same

Thanks in advance
narasimha
Charter Member
Charter Member
Posts: 1236
Joined: Fri Oct 22, 2004 8:59 am
Location: Staten Island, NY

Post by narasimha »

Here is post with which gives you a few.
Narasimha Kade

Finding answers is simple, all you need to do is come up with the correct questions.
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

A few major differences:
  • -Filter stage can have any number of output links where as Switch stage is limited to a max of 128 links.
    -Filter stage can optionally have a reject link. Switch stage requires a reject link.
    -A switch stage is like the C swtich function. It goes through all the cases and if no cases are met, it goes for the default value, which is specified by the reject link.
Thats just to name a few. More can be found by reading the manual.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

THE major difference is that the Switch stage operates on values, while the Filter stage operates on WHERE expressions, to determine which rows are sent along each output link.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
vijayrc
Participant
Posts: 197
Joined: Sun Apr 02, 2006 10:31 am
Location: NJ

Re: Difference between a Filter stage and Switch Stage

Post by vijayrc »

sshettar wrote:Hi all,

Just wanted to know what is the difference between a filter stage and switch stage .
as far as i know both do the same job.

correct me if i'm wrong and could some one explain the same

Thanks in advance
In Filter, a single Input record can pass thru one or many output links aslong as each link satisfies a certain criteria
In Switch, a single INput record can ONLY pass thru one of the many output links.
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Vijayrc said whatever Ray said, just in different words. That is infact, one of the major differences.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
Post Reply