Forum

Postgresql data typ...
 
Notifications
Retirer tout

Postgresql data types

2 Posts
2 Utilisateurs
0 Reactions
3,016 Vu
(@aorta)
Posts: 1
New Member
Début du sujet
 
[#2642]

Postgresql data types are strict. So a numeric type can only accept literal numbers. This means a numeric will accept 1 but not '1' since the latter is a character or string type. Moreover it is incorrect to use a numeric type (1,0) when a boolean is the real intention. The boolean can accept:
TRUE
't'
'true'
'y'
'yes'
'on'
'1'
For the "false" state, the following values can be used:
FALSE
'f'
'false'
'n'
'no'
'off'
'0'
http://www.postgresql.org/docs/9.4/static/datatype-boolean.html


 
Posté : 8 Oct PM 15:1010
(@babynus)
Posts: 14952
Membre Admin
 

and ?


 
Posté : 9 Oct AM 11:1010
Share:
Retour en haut