Kbase P71779: How the SQL-WIDTH is calculated for an extent field?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  15/09/2008 |
|
Status: Verified
GOAL:
How the SQL-WIDTH is calculated for an extent field?
GOAL:
How the SQL-WIDTH is calculated for each extent of an extent field?
FACT(s) (Environment):
All Supported Operating Systems
Progress 9.x
OpenEdge 10.x
FIX:
The SQL-WIDTH can be viewed in the *Options* menu of Data Dictionary.
For Progress 9.1x, it is in Options > SQL Properties... > Adjust Field Width.
For OpenEdge 10.0x, it is in Options > Adjust Field Width
The SQL-WIDTH for an extent field is calculated differently then a regular progress character field. Here is how total SQL-WIDTH for an extent field is calculated:
TOTAL SQL-WIDTH = [{(<Display format> * 2) + 2} * <Total # of extents>]
To demonstrate the formula above, let's take a field that has extent of 5 with a display format of x(8).
[{(8*2) + 2} * 5]= 90
Here is how the SQL-WIDTH length is calculated for each extent:
SQL-WIDTH for a field with extent 5 with display format X(8) is 90 as calculated above.
Let's take the above example to calculate the SQL-WIDTH for each extent:
SQL-WIDTH for each extent =
{<SQL-WIDTH of the field> - (<total # of extent>*2)}/ (<total # of extent>)
{90-(5*2)} / 5 = 16
Therefore, SQL-WIDTH of each extent will be 16 which is, as usual, the double the display format.