MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

SOC 7 ...

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Problem Determination
View previous topic :: View next topic  
Author Message
vikaspaniker79
Beginner


Joined: 01 Aug 2005
Posts: 12
Topics: 4
Location: India

PostPosted: Tue Aug 02, 2005 8:09 am    Post subject: SOC 7 ... Reply with quote

Hi All,

Let me start with putting down my requirement. In the input file to my program i have a field which is defined as
WS-A PIC S9(08)V99.

Now this field has its leading bytes as spaces in the file.

I have two operations with this field :
1. To display on a screen.
2. To compute some values using this.

The program is failing with SOC 7 at the compute point. I tried putting an inspect asking to replace leading spaces by zeros. But it corrupts the data. The reason being hex of space is '40' and for the v in S9(08)V99 the hex value is '4b'. This inspect will even covert this V.

So can anybody please suggest how can i remove the leading spaces in the field so that i can compute on it and at the same time retain the original value in it for display.
_________________
Cheers,
Vikas
Back to top
View user's profile Send private message Yahoo Messenger
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Tue Aug 02, 2005 8:15 am    Post subject: Reply with quote

Quote:

In the input file to my program i have a field which is defined as WS-A PIC S9(08)V99.


vikaspaniker79,

So how does your input file look like for this field?

Code:

+     678.11
-12345678.90


If so first read the contents with the sign into a char field and then reformat the field

Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vikaspaniker79
Beginner


Joined: 01 Aug 2005
Posts: 12
Topics: 4
Location: India

PostPosted: Fri Aug 05, 2005 12:07 am    Post subject: Reply with quote

Thanks for the reply ...
but i believe it wont work since if i move it into a char field, i can no more perform computation on it ....

Well at last i have got a solution on it ...

For the first part.. i have put a inspect for the first 7 byte i.e INSPECT
WS-A(1:8 )

For the second part ... I stringed the variable the first 7 and last two byte into the new variable ..well to mention here my computaion was to remove the '.' i.e to multiply by 100.....
_________________
Cheers,
Vikas
Back to top
View user's profile Send private message Yahoo Messenger
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Fri Aug 05, 2005 6:03 am    Post subject: Reply with quote

vikaspaniker79,

Take a look at this

http://www.mvsforums.com/helpboards/viewtopic.php?t=3540&highlight=inspect

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vivek
Beginner


Joined: 15 Jul 2004
Posts: 95
Topics: 11
Location: Edison,NJ

PostPosted: Mon Aug 15, 2005 1:35 pm    Post subject: Reply with quote

Vikas, you use sign trailing separate clause.
_________________
Vivek,NJ

Db2,IDMS
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Problem Determination All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group