1. I'm trying to use the money data type in a table. Just playing around
with this stuff. I have a table with two fields defined, a varchar field
for an identifier, and a single money field. Using pgadmin, I am unable
to enter any reasonable value in the money field. pgadmin will not allow
me to include the "$" character. And it bitches about not being able to
cast and INT to type money if I just put a plain number in.
How do I put a monetary value in this field?
2. When building a new table, if I create a field that is technically
incorrect (e.g., a money field with a default value of "0"), pgadmin
doesn't say anything about it until I try to save the new table. Then it
errors. But I cannot then edit the broken field. I have to delete the
field and try again.
I am trying very hard to move from MySQL to PostgreSQL, for many
reasons. But pgadmin is being a huge pain in the a.s.
> 1. I'm trying to use the money data type in a table. Just playing around
> with this stuff. I have a table with two fields defined, a varchar field
[quoted text clipped - 4 lines]
>
> How do I put a monetary value in this field?
Scratch that one ... I just saw I should be using numeric or decimal.
But even that is a problem ... the docs talk about precision and scale.
The pgadmin interface, for numeric type, has length and precision. Is
length supposed to be scale? The wording sucks.
> 2. When building a new table, if I create a field that is technically
> incorrect (e.g., a money field with a default value of "0"), pgadmin
[quoted text clipped - 4 lines]
> I am trying very hard to move from MySQL to PostgreSQL, for many
> reasons. But pgadmin is being a huge pain in the a.s.
Mark Drummond - 04 Nov 2006 21:33 GMT
>> 1. I'm trying to use the money data type in a table. Just playing
>> around with this stuff. I have a table with two fields defined, a
[quoted text clipped - 10 lines]
> The pgadmin interface, for numeric type, has length and precision. Is
> length supposed to be scale? The wording sucks.
I'm sure this is common knowledge, but what pgadmin calls the "length"
of a numeric is what the docs call the "precision" and what pgadmin
calls the "precision" is what the docs call the scale.
>> 2. When building a new table, if I create a field that is technically
>> incorrect (e.g., a money field with a default value of "0"), pgadmin
[quoted text clipped - 4 lines]
>> I am trying very hard to move from MySQL to PostgreSQL, for many
>> reasons. But pgadmin is being a huge pain in the a.s.