 |
SoftTree Technologies
Technical Support Forums
|
|
Author |
Message |
michalk
Joined: 29 Aug 2014 Posts: 211
|
|
[SA 7.2.338 Pro] Postgresql - boolean |
|
Boolean values are represented by integers values (0 and 1) in data preview grid. I would expect true/false or t/f etc
Speaking about data grids, I suggest to add datatype name to column headers
with regards
|
|
Wed Jun 10, 2015 4:55 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7948
|
|
|
|
Boolean values are internally represented as you say t/f or as a number of other databases as 1/0 and bit data types. SQL Assistant currently uses 1/0 as a presentation method for such values across all database types.
Regarding data types. Please mouse over column headers. You will see their data types and nullability attributes in the mouse-over hints.
|
|
Wed Jun 10, 2015 11:31 pm |
|
 |
michalk
Joined: 29 Aug 2014 Posts: 211
|
|
|
|
I would like to see an option to change representation of boolean then.
with regards
|
|
Thu Jun 11, 2015 9:33 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7948
|
|
|
|
That seems to be a PG only proprietary option. In all database server types the internal value for Boolean data values is either a BIT or TINYINT data type represented by 1/0 values. PG does internally the same thing, but in the SQL code it allows aliasing it to a bunch of values: TRUE, 't', 'true', 'y', 'yes', 'on' '1' - all of which are the same as 1, meaning a "true" state, while any of the following values are the same as 0, meaning a "false" state: FALSE, 'f', 'false', 'n', 'no', 'off', '0'
I can submit an enhancement request to allow alternative display of BIT / BOOL / BOOLEAN values.
|
|
Thu Jun 11, 2015 10:03 am |
|
 |
michalk
Joined: 29 Aug 2014 Posts: 211
|
|
|
|
Yeah, I would be grateful for that.
Point is, that looking at result grid, true/false value makes automatically obvious that the column cannot have other values.
If you look at column with 0 and 1 values, you can assume that there can be another numbers. So, showing boolean with true/false values is a way to improve user experience.
thank you.
|
|
Thu Jun 11, 2015 10:18 am |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|