double quotes for the numbers

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
kirankota79
Premium Member
Premium Member
Posts: 315
Joined: Tue Oct 31, 2006 3:38 pm

double quotes for the numbers

Post by kirankota79 »

I am taking a table from db2 database into a sequential file. In the db2 table there are two double (data type) columns. The data looks like follow:

3.87675610000000006E+01 for both the columns.

When i set the format as double quote (") for sequential file, iam getting the doublequotes for all the columns except these two. and i cannot see the rows containing this type of data from datastage view. can anybody please tell me how i will get the doublequotes for these columns!
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

If you must, select them as VarChar, possibly using a CAST function in the column derivation in the DB2 stage. But why do you think you need double quotes? It's a numeric value - the "rules" for CSV files specify quotes for character string data.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
kirankota79
Premium Member
Premium Member
Posts: 315
Joined: Tue Oct 31, 2006 3:38 pm

Post by kirankota79 »

can u tell me the rules for CSV for numeric values?
I_Server_Whale
Premium Member
Premium Member
Posts: 1255
Joined: Wed Feb 02, 2005 11:54 am
Location: United States of America

Post by I_Server_Whale »

No quotes for Numeric values. :wink:
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Seeing as how quotes are only for character strings, numeric values would fall into the "no quotes" camp.
-craig

"You can never have too many knives" -- Logan Nine Fingers
kirankota79
Premium Member
Premium Member
Posts: 315
Joined: Tue Oct 31, 2006 3:38 pm

Post by kirankota79 »

I have a mix of columns with character and numeric. How can i proceed then?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

With impunity.

Set the format for Quote character to match the quotes on your character strings. Numeric files will be expected not to be quoted.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply