Esempio n. 1
0
        private static object ConvertDecimalField(object value)
        {
            object convertedValue;

            if (value == DBNull.Value)
            {
                convertedValue = DBNull.Value;
            }
            else
            {
                var          decimalField = (DecimalField)value;
                var          stringValue  = decimalField.StringValue;
                OracleNumber oracleNumber;

                if (stringValue != null)
                {
                    oracleNumber = OracleNumber.Parse(stringValue);
                }
                else
                {
                    oracleNumber = new OracleNumber(decimalField.DecimalValue);
                }

                convertedValue = oracleNumber;
            }

            return(convertedValue);
        }
Esempio n. 2
0
 object ConvertToOracleNumber(Type type, string value, ref string errorMsg)
 {
     return(OracleNumber.Parse(value));
 }