Progress
Language Reference


Data Types

Interfaces
OS
SpeedScript
All
All
Yes

The data type of a field defines what kind of data the field can store. All data types other than the MEMPTR data type are limited in size to 32K. MEMPTR variables can be any size.

Table 8 lists the twelve data types supported by the Progress 4GL:

Table 8: Progress Data Types
Data Type
Description
CHARACTER
CHARACTER data consists of numbers, letters, and special characters.
COM-HANDLE
A COM-HANDLE is a handle to a COM object (ActiveX Automation object or ActiveX Control).
DATE
DATE fields contain dates.
DECIMAL
DECIMAL data consists of decimal numbers up to 50 digits in length including up to 10 digits to the right of the decimal point.
HANDLE
A HANDLE is a pointer to a Progress object.
NOTE: HANDLE and WIDGET-HANDLE can be assigned to each other and used interchangeably.
INTEGER
INTEGER data consists of whole numbers.
LOGICAL
LOGICAL data evaluates to TRUE or FALSE (or YES or NO).
MEMPTR
A MEMPTR contains the handle of a memory location.
RAW
RAW data can be any kind of data, even data from non-Progress databases. It is not converted in any way.
RECID
A RECID is an unique internal identifier of the current database record.
NOTE: RECID is supported mainly for backward compatibility. For most applications, use ROWID instead.
ROWID
A ROWID is an unique internal identifier of the current database record.
WIDGET-HANDLE
A WIDGET-HANDLE is a pointer to a Progress widget.
NOTE: HANDLE and WIDGET-HANDLE can be assigned to each other and used interchangeably.

Table 9 lists the default data formats for the data types.

Table 9: Default Display Formats
Data Type
Default Initial Value
Default Display Format
CHARACTER
"" (an empty string)
X(8)
COM-HANDLE
? (unknown value)
>>>>>>9
DATE
? (unknown value -
displays as blanks)
99/99/99
DECIMAL
0
->>,>>9.99
HANDLE
? (unknown value)
>>>>>>9
INTEGER
0
->,>>>,>>9
LOGICAL
no
yes/no
MEMPTR1
A zero-length sequence of bytes
See the footnote at the bottom of this table.
RAW1
A zero-length sequence of bytes
See the footnote at the bottom of this table.
RECID
? (unknown value)
>>>>>>9
ROWID1
A zero-length sequence of bytes
See the footnote at the bottom of this table.
WIDGET-HANDLE
? (unknown value)
>>>>>>9
  1. You cannot display a MEMPTR, RAW, or ROWID value directly. However, you can convert it to a character string representation using the STRING function and display the result. A ROWID value converts to a hexadecimal string, “0xhexdigits,” where hexdigits is any number of characters “0" through “9" and “A” through “F”. A MEMPTR or RAW value converts to decimal integer string.

For more information on using the different data types, see the Progress Programming Handbook and the Progress External Program Interfaces manual.

NOTES

SEE ALSO

= Assignment Operator, ASSIGN Statement


Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095