field function

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
just4u_sharath
Premium Member
Premium Member
Posts: 236
Joined: Sun Apr 01, 2007 7:41 am
Location: Michigan

field function

Post by just4u_sharath »

Hello,
I have used fieldfuction like this
field("88/For the Home/Bathroom Furniture/Wall % Floor Cabinets/" ,"&",1)

output I got is 88/For the Home/Bathroom Furniture/Wall % Floor Cabinets/

as per manual it should have returned me "".

Thanks
jwiles
Premium Member
Premium Member
Posts: 1274
Joined: Sun Nov 14, 2004 8:50 pm
Contact:

Post by jwiles »

Where does it say that in the manual? According to the docs, it returned what you asked for (field #1).

Regards,
- james wiles


All generalizations are false, including this one - Mark Twain.
pandeesh
Premium Member
Premium Member
Posts: 1399
Joined: Sun Oct 24, 2010 5:15 am
Location: CHENNAI, TAMIL NADU

Post by pandeesh »

My suggestion is to check for & first in the input.
If & presents then use field, else "".
You can code as above.
That will suite your requirement i believe,
pandeeswaran
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

jwiles wrote:Where does it say that in the manual? According to the docs, it returned what you asked for (field #1).
I agree and you got exactly what I would have expected. Can you post the verbiage from the documention that you mentioned? Perhaps when it comes to the wording, they choose... poorly. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

pandeesh wrote:That will suite your requirement i believe
Not sure there's a "requirement" to be met here, at this point all we have is a question.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply