Introduction MTB Statements File System Compiler Applications Reference Guide Index

Language Structure Data Division I/O Format Division Procedure Division Mnemonics

Overview FORMAT statement Format objects Video formatting Printer formatting

Overview Format item Length override Position Edit mask Modifier

Additional edit mask examples

  Edit mask         Value          Displayed as
  =============================================
  ######.##-              .01              1
                          .12             12
                         1.23           1.23
                        12.34          12.34
                       123.45         123.45
                      1234.56        1234.56
                     12345.67       12345.67
                    123456.78      123456.78
                    123456.78-     123456.78-

  #####0.00-              .01            .01
                          .12            .12
                         1.23           1.23
                        12.34          12.34
                       123.45         123.45
                      1234.56        1234.56
                     12345.67       12345.67
                    123456.78      123456.78
                    123456.78-     123456.78-

  ###,##0.00-             .01             .01
                          .12             .12
                         1.23            1.23
                        12.34           12.34
                       123.45          123.45
                      1234.56        1,234.56
                     12345.67       12,345.67
                    123456.78      123,456.78
                    123456.78-     123,456.78-

  000000.00-              .01      000000.01
                          .12      000000.12
                         1.23      000001.23
                        12.34      000012.34
                       123.45      000123.45
                      1234.56      001234.56
                     12345.67      012345.67
                    123456.78      123456.78
                    123456.78-     123456.78-

  *#####.##-              .01      ********1
                          .12      *******12
                         1.23      *****1.23
                        12.34      ****12.34
                       123.45      ***123.45
                      1234.56      **1234.56
                     12345.67      *12345.67
                    123456.78      123456.78
                    123456.78-     123456.78-

  *####0.00-              .01      ******.01
                          .12      ******.12
                         1.23      *****1.23
                        12.34      ****12.34
                       123.45      ***123.45
                      1234.56      **1234.56
                     12345.67      *12345.67
                    123456.78      123456.78
                    123456.78-     123456.78-

  *##,##0.00-             .01      *******.01
                          .12      *******.12
                         1.23      ******1.23
                        12.34      *****12.34
                       123.45      ****123.45
                      1234.56      **1,234.56
                     12345.67      *12,345.67
                    123456.78      123,456.78
                    123456.78-     123,456.78-

  *##.##0,00-             .01      *******,01     (European format)
                          .12      *******,12
                         1.23      ******1,23
                        12.34      *****12,34
                       123.45      ****123,45
                      1234.56      **1.234,56
                     12345.67      *12.345,67
                    123456.78      123.456,78
                    123456.78-     123.456,78-

  ###,##0.00+             .01             .01+
                          .12             .12+
                         1.23            1.23+
                         1.23-           1.23-
                        12.34           12.34+
                       123.45          123.45+
                      1234.56        1,234.56+
                     12345.67       12,345.67+
                    123456.78      123,456.78+
                    123456.78-     123,456.78-

  ###,##0.00CR            .01             .01
                          .12             .12
                         1.23            1.23
                         1.23-           1.23CR
                        12.34           12.34
                       123.45          123.45
                      1234.56        1,234.56
                     12345.67       12,345.67
                    123456.78      123,456.78
                    123456.78-     123,456.78CR

  ###,##0.00DR            .01             .01DR
                          .12             .12DR
                         1.23            1.23DR
                         1.23-           1.23CR
                        12.34           12.34DR
                       123.45          123.45DR
                      1234.56        1,234.56DR
                     12345.67       12,345.67DR
                    123456.78      123,456.78DR
                    123456.78-     123,456.78CR

  (###,##0.00)            .01              .01
                          .12              .12
                         1.23             1.23
                         1.23-           (1.23)
                        12.34            12.34
                       123.45           123.45
                      1234.56         1,234.56
                     12345.67        12,345.67
                    123456.78       123,456.78
                    123456.78-     (123,456.78)