× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




Hopefully this formats decently. This is the default mapping of SQL Data
Types to EGL variables per InfoCenter.

What does DSPFFD show for your data type? I've only dealt with PACKED and
TIMESTAMP.

When I introspect the *FILE with EGL, it auto-creates dataitems of DECIMAL
(9,0) and TIMESTAMP respectively. From this table, a NUMERIC SQL type
should be defined as DECIMAL in EGL.
|----------------------------+ --------------|
| SQL data type | EGL | |
| | variable | |
| | characteris | |
| | tics | |
|----------------------------+----------------------------+--------------|
| | Primitive | Digits/charact| Number of |
| | type | ers | bytes |
|----------------------------+------------+---------------+--------------|
| BIGINT | BIGINT | n/a | 8? |
|----------------------------+------------+---------------+--------------|
| BIT | SMALLINT | n/a | 2 |
|----------------------------+------------+---------------+--------------|
| BLOB | BLOB | n/a | n/a |
|----------------------------+------------+---------------+--------------|
| BOOLEAN | BOOLEAN | n/a | 1 |
|----------------------------+------------+---------------+--------------|
| CHAR | CHAR | 1?32767 | 1?32767 |
|----------------------------+------------+---------------+--------------|
| CLOB | CLOB | n/a | n/a |
|----------------------------+------------+---------------+--------------|
| DATE | DATE | n/a | 8 |
|----------------------------+------------+---------------+--------------|
| DECIMAL | DECIMAL | 1-18 | 1?10 |
|----------------------------+------------+---------------+--------------|
| DOUBLE | FLOAT | n/a | 8 |
|----------------------------+------------+---------------+--------------|
| FLOAT | FLOAT | n/a | 8 |
|----------------------------+------------+---------------+--------------|
| GRAPHIC | DBCHAR | 1?16383 | 2?32766 |
|----------------------------+------------+---------------+--------------|
| INTEGER | INT | n/a | 4 |
|----------------------------+------------+---------------+--------------|
| LONG VARBINARY | HEX | 65534 | 32767 |
|----------------------------+------------+---------------+--------------|
| LONG VARCHAR | CHAR | >4000 | >4000 |
|----------------------------+------------+---------------+--------------|
| LONG VARGRAPHIC | DBCHAR | >2000 | >4000 |
|----------------------------+------------+---------------+--------------|
| NUMERIC | DECIMAL | 1-18 | 1?10 |
|----------------------------+------------+---------------+--------------|
| REAL | SMALLFLOAT | n/a | 4 |
|----------------------------+------------+---------------+--------------|
| SMALLINT | SMALLINT | n/a | 2 |
|----------------------------+------------+---------------+--------------|
| TIME | TIME | n/a | 6 |
|----------------------------+------------+---------------+--------------|
| TIMESTAMP | TIMESTAMP | n/a | 14 |
|----------------------------+------------+---------------+--------------|
| VARBINARY | HEX | 2?65534 | 1?32767 |
|----------------------------+------------+---------------+--------------|
| VARCHAR | CHAR | ≤4000 | ≤4000 |
|----------------------------+------------+---------------+--------------|
| VARGRAPHIC | DBCHAR | ≤2000 | ≤4000 |
|----------------------------+------------+---------------+--------------|




----------------------------------------------------------------------

date: Thu, 2 Oct 2008 15:28:13 -0400
from: <ppetta@xxxxxxxxx>
subject: [EGL-i] Getting numeric fields

Hi, I have been having problems getting numeric fields from the as400. Its
defined as numeric on the server, and egl treats the field as a decimal. Is
this wrong? When trying to get the field by sql I get a SQLnumeric
exception.

Thanks

Steve Mervosh
THOR (Total Hardware and Order Repository)
Software Development
IBM Rochester Minnesota
spm@xxxxxxxxxx

As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.