S
Steve Hiemstra
Hi All,
I'm developing an application that needs to put 'money' (currency) values
into ANY OF Access, MS-SQL Server, and/or Oracle databases. Because they
all
have their own way of supporting 'Money' and .NET only gives us the
'System.Decimal' datatype to work with I am at a loss...
So far I've used the "System.<datatype>" compatible datatypes under .NET,
and let ADO.NET convert to the database of choice. SO, "System.Decimal" is
what I've been using for 'Money' (but each database type use something other
than 'decimal' for currency values, Access: 'Money' or 'Number', MS-SQL
Server: 'Money' or 'Decimal'...).
The problem is... I don't see how to specify the 'fractional' precision of
the Decimal value through ADO.NET.
Through ADO... how do I create the Column Schema parameters for a Decimal?
Do I set a database column up as a 'Money' or 'Number' value and set it's
internal parameters at the database-level (and let ADO use 'Decimal', hoping
it will all convert OK)?
I'm just trying to find the most compatible way to handle ADO sending
currency values to a variety of database types without getting too 'manual'
about it.
Any help is appreciated,
SteveH
I'm developing an application that needs to put 'money' (currency) values
into ANY OF Access, MS-SQL Server, and/or Oracle databases. Because they
all
have their own way of supporting 'Money' and .NET only gives us the
'System.Decimal' datatype to work with I am at a loss...
So far I've used the "System.<datatype>" compatible datatypes under .NET,
and let ADO.NET convert to the database of choice. SO, "System.Decimal" is
what I've been using for 'Money' (but each database type use something other
than 'decimal' for currency values, Access: 'Money' or 'Number', MS-SQL
Server: 'Money' or 'Decimal'...).
The problem is... I don't see how to specify the 'fractional' precision of
the Decimal value through ADO.NET.
Through ADO... how do I create the Column Schema parameters for a Decimal?
Do I set a database column up as a 'Money' or 'Number' value and set it's
internal parameters at the database-level (and let ADO use 'Decimal', hoping
it will all convert OK)?
I'm just trying to find the most compatible way to handle ADO sending
currency values to a variety of database types without getting too 'manual'
about it.
Any help is appreciated,
SteveH