Quantcast
Channel: WCF Data Services forum
Viewing all articles
Browse latest Browse all 877

Error when creating service reference to WCF 5.1 data service

$
0
0

I have an application that is built using an Entity Framework model generated from the database and then exposed using WCF Data Services 5.1. The main reason for using 5.1 is the support for DateTimeOffset, but I have run into an error. The service seems to be working properly as I'm able to access data using a browser but if I when I try to create a service reference for a client app, it fails with the following error:

"The custom tool 'DataServicescoreClientGenerator' failed. Data service client code-generation failed: Schema specified is not valid. Errors: (0,0): error 0063: Precision facet isn't allowed for properties of type String." (The last part repeats for all the DataTimeOffset columns in the model.)

I can recreate the problem as follows:

  1. Generate a Entity Data Model from a single table with a DateTimeOffset column.
  2. Create a WCF Data Service 5.1 and select the entities from step 1.
  3. In a separate (WPF) project select "Add Service Reference", click "Discover" and select the service created in step 2. At this point, code generation fails with the error shown above.

Does anyone have a workaround? I need for other team members to be able to access the service, and I need WCF 5.1 (or 5.0 I guess) to support numerous DateTimeOffset columns in the data.


Viewing all articles
Browse latest Browse all 877

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>