Load Definitions Facility for MySQL

The Load Definitions functionality is supported for MySQL.

Functionality

The Load Definitions facility for MySQL loads tables, views, columns, and indexes. Loading is based on generated columns, also sometimes called computed columns.

It does not load relationships.

Configuration

Before loading definitions from MySQL:

  • Specify the MQL connector in the [DRIVERS] section of the IDE assignment file.
  • Define the $MQL path in the [PATHS] section of the IDE assignment file.

For more detailed instructions, see Import Data Definitions From a DBMS.

Data Type Mapping

The Load Definitions utility maps MySQL data types to Uniface data types and packing codes. The following table lists these mappings.

Load Definitions Support for MySQL Data Types

MySQL Data Type

Supported by Load Definitions

Uniface Data Type

Uniface Packing Code

Remarks

bigint

Yes

N

I8

Range -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807

int Yes N I4 Range -2,147,483,648 to 2,147,483,647
mediumint Yes N l3 Range -8,388,608 to 8,388,607

smallint

Yes

N

I2

Range -32,768 to 32,767
tinyint Yes N l1 Range 0 to 255 (negative numbers are not permitted)

char, character

Yes

S

Cn

n<=254

varchar, long varchar

Yes

S

VCn

n>=255
longtext Yes S SC*  
binary Yes R Rn  
varbinary Yes R SRn  
longblob Yes R SR*  
date

Yes

D

D

Uniface does not allow BC dates.

time

Yes

T

T

Uniface accuracy is limited to ticks.

datetime Yes E E  

decimal(p,s) and numeric(p,s)

Yes

N

N(p+1).s, N(p+1)

pis precision (total number of digits); for Uniface p must be 30 max, field is skipped with a warning if p is larger.

sis scale (number of decimal places); for Uniface s must be smaller than p, field is skipped with a warning if they are equal.

s=0 generates N(p+1), rather than N(p+1).0

A ValRep is generated to enforce the exact DBMS max/min values during data entry and store validation.

float

Yes

F

F4

Uniface allows -1e+38 to 1e+38

Uniface will read the full database range. Storing outside the Uniface range generates an error.

double, double precision

Yes

F

F8

Uniface allows -1e+38 to 1e+38

Uniface will read the full database range. Storing outside the Uniface range generates an error.

Other data types      

The following data types are skipped with a warning message TYPE_NOT_SUPPORTED:

  • blob
  • set
  • text
  • enum
  • timestamp
  • year
  • geometry
  • point
  • linestring
  • polygon
  • multipoint
  • multilinestring
  • multipolygon
  • geometrycollection
  • json

Fields with a data type that is not known in the service are skipped with a warning message: TYPE_NOT_RECOGNIZED.

Related Topics