Hi Chuck,

I believe you are encountering the SQL data type codes.

In the SQL implementation, there is "DATA_TYPE" and "OLD_DATA_TYPE".

For a chart, see tech note "System table column OLD_DATA_TYPE" at:
http://kb.4d.com/assetid=76350

The SQL table "_USER_COLUMNS" reports both the SQL data type and the 4D data 
type.

The SQL data type appears in the column "DATA_TYPE".

The 4D data type appears in the column "OLD_DATA_TYPE".

And oddly, when you export the 4D structure (using the 4D command EXPORT 
STRUCTURE), the SQL data codes are used instead of the 4D data type codes for 
the “type” attribute in the “field” tab.

Hope this helps.

Jeremy French

> On Jun 11, 2018, at 4:33 PM, Chuck Miller via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> Given the following code
> select 
> COLUMN_NAME, 
> DATA_TYPE, 
> DATA_LENGTH, 
> COLUMN_ID 
> from
> _USER_COLUMNS
> where
> TABLE_ID = :$TableNumber_L
> into
> :$Cname_atxt, :$DataType_aL, :$DataLength_aL,  :$ColumnID_aL;
> 
> What values can be returned in $DataType_aL It seems that they do not equal 
> 4D data types (I did not expect it to) Is there a chart I can not find that 
> lists them?

**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**********************************************************************

Reply via email to