Re: moving from MySQL to pgsql

Поиск
Список
Период
Сортировка
От F. BROUARD / SQLpro
Тема Re: moving from MySQL to pgsql
Дата
Msg-id 50766AA0.1030904@club-internet.fr
обсуждение исходный текст
Ответ на moving from MySQL to pgsql  (Vineet Deodhar <vineet.deodhar@gmail.com>)
Список pgsql-general
Le 10/10/2012 10:47, Vineet Deodhar a écrit :
> Hi !
>
> 3) Can I simulate MySQL's TINYINT data-type (using maybe the custom data
> type or something else)
>

Another way, and a good practice toot is to use SQL DOMAINs wich is a
part of the ISO SQL since 1992 that MySQL don't have...

CREATE DOMAIN TINYINT
    AS SMALLINT
    CHECK (VALUE BETWEEN 0 AND 255)

Most part of the modelling tools are able to use DOMAINs in their
modelling process, like PowerDesigner, Mega, ERwin, Rational...

A +

--
Frédéric BROUARD - expert SGBDR et SQL - MVP SQL Server - 06 11 86 40 66
Le site sur le langage SQL et les SGBDR  :  http://sqlpro.developpez.com
Enseignant Arts & Métiers PACA, ISEN Toulon et CESI/EXIA Aix en Provence
Audit, conseil, expertise, formation, modélisation, tuning, optimisation
*********************** http://www.sqlspot.com *************************



В списке pgsql-general по дате отправления:

Предыдущее
От:
Дата:
Сообщение: Storing large files in multiple schemas: BLOB or BYTEA
Следующее
От: Vineet Deodhar
Дата:
Сообщение: auto-increment field : in a simple way