as400下采用pcomm连接db2,怎么查看支持的数据类型

as400下采用pcomm连接db2,怎么查看支持的数据类型,就是怎么调出下图:显示全部

as400下采用pcomm连接db2,怎么查看支持的数据类型,就是怎么调出下图:

QQ图片20151123203732.png


收起
参与4

返回Xiao Qing的回答

Xiao QingXiao Qing系统工程师浪潮商用机器有限公司

上面的这个画面是从STRSQL命令中导出来的,具体的步骤如下:
1.在AS/400的命令行上如数STRSQL
2.CREATE TABLE, 按F4功能键。
3.在“Type”的位置按F1功能键,就会弹出您所需的这个界面了。

这是AS/400数据库所支持的所有数据类型。
5770SS1 V7R2M0 140418 HELP 09/08/20 19:53:03 Page 1
Type - Help
Select the type of data. The possible choices are:
INTEGER (INT)
A large integer. If INTEGER is selected, do not
specify Length and Scale.
SMALLINT
A small integer. If SMALLINT is selected, do not
specify Length and Scale.
BIGINT
A big integer. If BIGINT is selected, do not specify
Length and Scale.
FLOAT
A floating-point number. If FLOAT is selected,
precision ( Length ) should be specified but not
Scale. If Length is between 1 and 24 inclusive, the
format is that of single precision floating-point.
If Length is between 25 and 53 inclusive, the format
is that of a double precision floating-point. If
Length is not specified, the default is 52. If a
single precision floating-point (REAL) or a double
precision floating-point (DOUBLE PRECISION) is
specified, do not specify Length and Scale.
DECFLOAT
A decimal floating-point number. If DECFLOAT is
selected, precision ( Length ) should be specified
but not Scale. Length of 16 or 34 is allowed and if
it is not specified, then the default is 34.
NUMERIC
A zoned decimal number. The first integer is the
precision of the number (total number of digits)
which can range from 1 to 63. The second integer is
the scale of the number (number of digits to the
right of the decimal point) which can range from 0 to
the precision. If NUMERIC is selected, precision (
Length ) and Scale should be specified. If you
specify Length, but not Scale, the default for Scale
is 0. If you omit both Length and Scale, the default
for Length is 5 and the default for Scale is 0.
DECIMAL (DEC)
A decimal number. The first integer is the precision
of the number (the total number of digits) which can
range from 1 to 63. The second integer is the scale
of the number (the number of digits to the right of
the decimal point) which can range from 0 to the
precision. If DECIMAL is selected, precision (
Length ) and Scale is specified. If you specify
Length, but not Scale, the default for Scale is 0.
If you omit both Length and Scale, the default for
Length is 5 and the default for Scale is 0.
CHARACTER (CHAR)
Page 2
A fixed-length character string. The length
(specified by an integer) can range from 1 to 32766
(32765 if null capable). For mixed-data, the range
is 4 to 32766 (32765 if null capable). If precision
( Length ) is omitted, 1 character is the default.
If CHAR is selected, Length can be specified but not
Scale.
VARCHAR (CHARACTER VARYING, CHAR VARYING)
A variable-length character string. All values of
the string have the same maximum length, determined
by the length attribute of the column. The length
must be specified as an integer. Length can be from
1 to 32740 (32739 if null capable).
LONG VARCHAR (not valid for DECLARE PROCEDURE)
A variable-length character string whose maximum
length is determined by the amount of space available
in the row.
BINARY
A fixed-length binary string. The length (specified
by an integer) can range from 1 to 32766 (32765 if
null capable). If precision ( Length ) is omitted, a
length of 1 is the default. If BINARY is selected,
Length can be specified but not Scale.
VARBINARY (BINARY VARYING)
A variable-length binary string. All values of the
string have the same maximum length, determined by
the length attribute of the column. The length must
be specified as an integer. Length can be from 1 to
32740 (32739 if null capable).
DATE
A three-part value (year, month, day) designating a
point in time under the Gregorian calendar. The
range of the year part is 1 to 9999, beginning with
the year 1 A.D. The range of the month part is 1 to

  1. The range of the day part is 1 to 28, 29, 30, or
    31, depending on the month. Length and Scale cannot
    be specified.
    TIME
    A three-part value (hour, minute, second) designating
    a time of day under a 24-hour clock. The range of
    the hour part is 0 to 24; the range of the other two
    parts is 0 to 59. If the hour is 24, the minute and
    second parts are both 0. Length and Scale cannot be
    specified.
    TIMESTAMP
    A seven-part value that designates a date and time
    under the Gregorian calendar. The seven parts are:
    Year - range is 1 to 9999
    Month - range is 1 to 12
    Page 3
    Day - range is 1 to 28, 29, 30, or 31, depending
    on the month
    Hour - range is 1 to 24
    Minute - range is 0 to 59
    Second - range is 0 to 59
    Microsecond - range is 0 to 999999
    Length and Scale cannot be specified.
    GRAPHIC
    A graphic data type is used. If you do not specify a
    length, the default of 1 is used. The range is 1 to
  2. (16382 if null capable). Length can be
    specified. Scale cannot be specified.
    VARGRAPHIC (GRAPHIC VARYING)
    A variable-length graphic data type is used. You
    must specify a length. The range is 1 to 16370
    (16369 if null capable). Scale cannot be specified.
    LONG VARGRAPHIC (not valid for DECLARE PROCEDURE)
    A variable-length graphic string whose maximum length
    is determined by the amount of space available in the
    row.
    REAL
    For single precision floating-point. Length and
    Scale cannot be specified.
    DOUBLE PRECISION (DOUBLE)
    For double precision floating-point. Length and
    Scale cannot be specified.
    CLOB (CHARACTER LARGE OBJECT or CHAR LARGE OBJECT)
    A variable-length character string in the range of 1
    through 2 gigabytes (2,147,483,647). The length can
    be specified as integer, integer K (Kilobyte),
    integer M (Megabyte), or integer G (Gigabyte). Scale
    cannot be specified.
    BLOB (BINARY LARGE OBJECT)
    A variable-length binary string in the range of 1
    through 2 gigabytes (2,147,483,647). The length can
    be specified as integer, integer K (Kilobyte),
    integer M (Megabyte), or integer G (Gigabyte). Scale
    cannot be specified.
    DBCLOB
    A variable-length double-byte character string in the
    range of 1 through 1 gigabytes (1,073,741,823). The
    length can be specified as integer, integer K
    (Kilobyte), integer M (Megabyte), or integer G
    (Gigabyte). Scale cannot be specified.
    DATALINK
    Page 4
    A variable-length string which contains a Uniform
    Resource Locator (URL). Length can be from 1 to
  3. (32717 if nullable). Scale cannot be
    specified.
    distinct type
    The name of an object that exists on the system, type
    *SQLUDT, which contains type information. This can
    be library qualified. Length and Scale cannot be
    specified.
    ROWID
    A value that uniquely identifies a row in a table.
    Only one ROWID column is allowed in a table. Scale
    cannot be specified.
          • E N D O F L I S T I N G *

仅供参考。

系统集成 · 2020-09-14
浏览1135

回答者

Xiao Qing
系统工程师浪潮商用机器有限公司
擅长领域: 服务器新核心系统存储

Xiao Qing 最近回答过的问题

回答状态

  • 发布时间:2020-09-14
  • 关注会员:2 人
  • 回答浏览:1135
  • X社区推广