Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How Do I Insert Blanks?

Status
Not open for further replies.

LadyPeeper

Programmer
Sep 8, 2000
8
US
I've got a salary field with a PIC 9(5)v99.
On my printout the salary shows up okay.
However, if I don't want to reveal the salary how do I put make it blank. I don't want zeroes.....I want nothing showing.
FYI, I have names and positions that also print out with the salaries. I want the salaries to print nothing on some positions.

Sound easy? To you, perhaps, but to a newbie I'm lost. Help!!

Thanks,
Cynde :)
 
Cynde,
There are a couple of ways to do this.
1.Define the print field as an edit mask zz,zzz.zz then move 0 (zero) to the field if you dont want to show it.
2.Move spaces to the entire print line before you move any
fields, and then dont move in that salary amount.
Hope this helps
 
If the all Z picture doesn't suit your needs, you can add the phrase BLANK WHEN ZERO after the PIC clause, allowing you to use whatever picture string you want. Then you can move zeros to the field as mrregan suggests. Betty Scherber
Brainbench MVP for COBOL II
 
Thanks all.

I'll try those techniques and see if a blank comes out instead of zeroes.

:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top