This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Back in Jun 03 2009 we posted the following thread about setting the size of a decimal and was told there would be a solution in Lightspeed 3.0. Is there a solution in 3.0 for setting the size of a decimal in the db from the model? And if so, what is it? http://www.mindscape.co.nz/forums/Thread.aspx?PostID=5345 Thanks, Nick |
|
|
Yes, there is a solution, but it is not currently surfaced in the designer UI. Instead you will need to edit the .lsmodel file in a text editor such as the Visual Studio XML editor (right-click, Open With, XML Editor). Find the property and add the following attribute: <entityProperty databaseNativeType="DECIMAL(12,12)" /> We are considering how to surface this feature -- we know editing the XML is inconvenient, but we don't want to display it in the Properties grid because we don't want people to think they have to micromanage it. Please note there are some limitations around this: in particular if LightSpeed does not consider the database native type when checking for updates. So if you have a property declared as Decimal with a database native type of DECIMAL(12,12), and change the native type to DECIMAL(17,1) then this change will NOT be reflected to the database or picked up in migrations (though with migrations you can add the change by hand by editing the generated migration). |
|
|
Hi I assume that this was never implemented in the designer? Cheers |
|
|
Hi Johan, No this has not been implemented in the designer.
|
|