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

what is the difference bw packed decimal & zoned decimal


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ipavan

New User


Joined: 12 Jun 2005
Posts: 28
Location: Hyderabad

PostPosted: Thu Sep 15, 2005 3:53 pm
Reply with quote

what is the difference between packed decimal number(PD), Zoned decimal
number(ZD) , and a number.
Back to top
View user's profile Send private message
michaelraj

New User


Joined: 01 Sep 2005
Posts: 43
Location: Bangalore

PostPosted: Thu Sep 15, 2005 6:04 pm
Reply with quote

Hi,

The number stored in COMP-3 field is called as packed decimal number.
The number stored in COMP field is called as zoned decimal number.
The number is an ordinary number.

Regards,
Mike.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Fri Sep 16, 2005 6:08 am
Reply with quote

You're half right, Mike.

A Zoned Decimal # is DISPLAY.

The ZD# +123 looks like X'F1F2C3' or X'F1F2F3' in memory. In this case the "F"s and the"C" are the Zones.

The PD# +123 looks like X'0123C' or X'0123F' in memory. In this case the Zones are dropped and the digits are "Packed" together. Only the sign zone "C" (or "F") is retained.
Back to top
View user's profile Send private message
michaelraj

New User


Joined: 01 Sep 2005
Posts: 43
Location: Bangalore

PostPosted: Fri Sep 16, 2005 12:49 pm
Reply with quote

Hi,

Thanks Jack for your information.

Regards,
Mike.
Back to top
View user's profile Send private message
badal

New User


Joined: 05 Sep 2004
Posts: 21

PostPosted: Wed Sep 21, 2005 10:27 am
Reply with quote

hai,
can tell me something about zone? when to use 'f' or 'c'.
plz clarify moew in that zone.
thanks and regards.
anjan.
Back to top
View user's profile Send private message
reshma

New User


Joined: 10 Sep 2005
Posts: 9
Location: software engineer

PostPosted: Wed Sep 21, 2005 1:02 pm
Reply with quote

hi ANJAN,

INTERNALLY THE SIGN VALUES R STORED AS ZONE BITS BY DEFAULT.DONT WORRY ABT IT.BY USING COMP3 ,IF a 'F' OR 'C' appears
then sign value is + otherwise if ur using - then it is stored as 'D'.I SUPPOSE UR LEARNING MAINFRAMES NOW.GOOD LUCK.

REGARDS,
RESHMA.
Back to top
View user's profile Send private message
badal

New User


Joined: 05 Sep 2004
Posts: 21

PostPosted: Wed Sep 21, 2005 7:56 pm
Reply with quote

hai reshma,
i am in this fiels since 3 years. don't think that i am not learning mainframe now. i am working in a CMMI-5 level company. my intention was in which situation we will be getting this type of code. it means,in what situation we will be gettijng X'F1F2C3' and in what situation we will get this X'F1F2F3' . why in 1st pont u told that X'F1F2C3' AND IN THE 2ND X'F1F2F3' THIS ONE. WHY IS THAT?

GOOD LUCK.
ANJAN.
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 -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts PD not working for unsigned packed JO... DFSORT/ICETOOL 5
No new posts Def PD not working for unsigned packe... JCL & VSAM 3
No new posts Timestamp difference and its average ... DB2 11
No new posts Need Help with Packed Decimal Signs DFSORT/ICETOOL 4
Search our Forums:

Back to Top