Difference SQL and Oracle Number(10,0)

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
_andreas
Posts: 6
Joined: Wed 18 Mar 2009 09:53

Difference SQL and Oracle Number(10,0)

Post by _andreas » Thu 02 Apr 2009 14:13

Hello,

I try to create edm for sqlerver and oracle server.
So I created one csdl which I use for both databases and I generated the msl and ssdl foreach database.
The csdl is created from sql server and all ids are Int32 and the datatype of the column in sql server is int.
Now I generate the ssdl and the msl for the oracle database.
However, in the ssdl for oracle the datatype of the ids is Int64 while the datatype of the oracle column is Number(10,0).
So when I try to save something into the oracle database i get an error because the datatype in the ssdl is Int64 and the datatype in csdl is Int32.

Any clue to solve this problem?

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Thu 02 Apr 2009 14:27

Such mapping is used to prevent the overflow on the client side.
You can manually modify the SSDL part of the generated model using any XML Editor you like and set the type of your property
according to your needs.

_andreas
Posts: 6
Joined: Wed 18 Mar 2009 09:53

Post by _andreas » Thu 02 Apr 2009 14:57

If I change the datatype in ssdl to int32 I get the error that the datatype is not known in the namespace.

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Fri 03 Apr 2009 06:30

The correct synonym for the Int32 data type is "int".

Post Reply