IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to add a space after each field value in SQL query job


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
maxsubrat

Active User


Joined: 27 Feb 2008
Posts: 110
Location: india

PostPosted: Thu Mar 01, 2012 11:45 am
Reply with quote

Hi,

I have to fetch 3 column fields in a SQL and I want to put a space after each value. For ex:

SELECT A.EMPT, B.REC, B.DATE
FROM EMP A, STDC B

If I wish to run the above query in a IKJEFT job (not in SPUFI) and send the data to a file, the records are coming without any space after each value.. Like
INS120203866ACFBSMNS2012-01-21-13.21.35.042100

So I want to put a space in between. Like:
INS120203866 ACFBSMNS 2012-01-21-13.21.35.042100

Thanks
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Mar 01, 2012 11:54 am
Reply with quote

GHU!

how about:

SELECT A.EMPT,' ', B.REC, ' '.B.DATE
FROM EMP A, STDC B
Back to top
View user's profile Send private message
maxsubrat

Active User


Joined: 27 Feb 2008
Posts: 110
Location: india

PostPosted: Thu Mar 01, 2012 12:02 pm
Reply with quote

got it ! Thanks
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
No new posts RC query -Time column CA Products 3
No new posts Dynamically pass table name to a sele... DB2 2
No new posts Query on edit primary command CLIST & REXX 5
Search our Forums:

Back to Top