I just faced a situation that doesn’t have a very good impact on my database.
I just come from 3.5.8 and I use JSColumn.getLength() function.
In 3.5.8 when I have a database field of the type numeric(18,2), this method returned the number of decimals, so it returned 2
But now I migrated to 4.1.3 and I see that this same function returns 18. And because I use this function to change database types - from float to numeric(18,2) - I need to determine the exact number of decimals.
I guess this has something to do with the change that was made in 3.5.9 where also the length was ignored when entering a length in the dataprovider.
Now I can’t determine the exact size of my column. So there are 3 solutions:
- JSColumn.getLength() returns the number of decimals again like in 3.5.8 (in this case 2)
- JSColumn.getLength() returns no longer a number, but a string (in this case 18,2)
- JSColumn.getDecimals() is a new method that returns the number of decimals (in that case JSColumn.getLength() can return 18 and JSColumn.getDecimals() can return 2)
Servoy guys, please confirm that you can reproduce the above and please give me as soon as possible a solution.
Martin