If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Export Has Weird Characters For Numeric Fields

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-03-11, 13:53
captainlaw captainlaw is offline
Registered User
 
Join Date: May 2011
Posts: 11
Export Has Weird Characters For Numeric Fields

Hello,
I'm getting weird characters returned for numberic fields.

Current Format
+000000000000001.2485

Expected Format
1.2485

Below is the export command I'm using. Can someone advise on how to format numeric fields correctly?

export to c:\test\txn2011.txt of del modified by COLDEL0x09 NOCHARDEL SELECT Partner, Profit FROM SchoolBudget;
Reply With Quote
  #2 (permalink)  
Old 05-03-11, 13:57
dav1mo dav1mo is offline
Registered User
 
Join Date: Dec 2007
Location: Richmond, VA
Posts: 782
that is the correct format. If you'd like it in a different format, you would have to change the data type on the select statement. Something like:

SELECT Partner, strip(digits(Profit),l,'0') FROM SchoolBudget

Dave
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On