Hello.
I have a problem with rails.
I have a filed in a table that is of double type. When I show the view,
a default value is shown, but there is no default value in the database.
How can I override this?
Thanks
Hello.
I have a problem with rails.
I have a filed in a table that is of double type. When I show the view,
a default value is shown, but there is no default value in the database.
How can I override this?
Thanks
Hi Pedro C.,
This problem is surely interesting, but it would be very helpful if
you could some info. about your migration/ model. I didn’t observe
this behavior in my application, which also had a ‘double’ field.
– askme
On Mar 23, 10:27 am, Pedro C. [email protected]
The model definition/ migration definition can shed some light on the
problem.
– askme
On Mar 23, 12:05 pm, Pedro C. [email protected]
askme wrote:
The model definition/ migration definition can shed some light on the
problem.– askme
On Mar 23, 12:05 pm, Pedro C. [email protected]
This is the line from the DDL that maters
[…] global_cost double(100,10) NOT NULL,[…]
Everything else is pure Rails
askme wrote:
Hi Pedro C.,
This problem is surely interesting, but it would be very helpful if
you could some info. about your migration/ model. I didn’t observe
this behavior in my application, which also had a ‘double’ field.– askme
On Mar 23, 10:27 am, Pedro C. [email protected]
What kind of info do you need?
BTW: I solve it making it equal to null before I render the view
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs