View previous topic :: View next topic |
Author |
Message |
v_mvs Beginner
Joined: 23 Apr 2004 Posts: 10 Topics: 5
|
Posted: Fri Sep 10, 2004 1:50 am Post subject: S9(3)V comp-3 'Vs' S9(3) comp-3 |
|
|
Is
05 W-OUTPUT PIC S9(3)V comp-3.
same as
05 W-OUTPUT PIC S9(3) comp-3. ?
Is there any significance of the first declaration over the second? |
|
Back to top |
|
|
NutCracker Beginner
Joined: 13 Dec 2002 Posts: 45 Topics: 3 Location: 3rd Block from the SUN
|
Posted: Fri Sep 10, 2004 2:27 am Post subject: |
|
|
Did you try testing the formats with sample data? |
|
Back to top |
|
|
v_mvs Beginner
Joined: 23 Apr 2004 Posts: 10 Topics: 5
|
Posted: Fri Sep 10, 2004 5:11 am Post subject: |
|
|
Nutcraker,
I tested by moving values to the both variables, but i didnt see any difference in the display. I just wanted to know is there any real significance in such declarations. |
|
Back to top |
|
|
MikeBaker Beginner
Joined: 04 May 2004 Posts: 96 Topics: 9
|
Posted: Fri Sep 10, 2004 8:17 pm Post subject: |
|
|
The 'V' is an implied decimal point. So... your first declaration is a redundant use of 'V' even though it compiles. But if modify your PICs slightly; ie: PIC S9(4) comp-3 vs PIC S9(3)V9 comp-3. Then you have got something completely different, and you will see the difference if you output it to a Report using an edit pattern which includes a decimal point. But if you examine the field contents through a debugger, then you probably cannot see any difference. |
|
Back to top |
|
|
|
|