Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Services > Repost - Typed dataset returned from webservice incorrectly defined in proxy - null value problem

Reply
Thread Tools

Repost - Typed dataset returned from webservice incorrectly defined in proxy - null value problem

 
 
Randy Hayes
Guest
Posts: n/a
 
      01-20-2004
Repost...didn't get any responses on the first try...

I have a web service that has a xsd defined for a dataset. The xsd has all
of the proper tables/elements, constraints, relations, etc. and works fine
from the webservice standpoint. I have also defined certain elements in the
xsd to return empty when null.

Now I realize that this puts in some msprop attributes on those elements as
well as some codgen attributes all in place to help out the generation of
the typed dataset. And when looking at the dataset generated in the
webservice...it has the logic for the null values. All is well!

BUT, when referencing the webservice from an app, the proxy generated typed
dataset is not the same. It has no logic for the null values.

I noticed that when going to the webservice directly and requesting the
schema (webservice.asmx?schema=xxxx) the resulting schema DOES NOT include
all of the namespace information for the dataset generation. In other
words, not only is the namespace declaration missing, but all of the
attributes for the elements that were defined as returning "emtpy" when null
are missing. This explained why the proxy generated typed dataset was the
way it was.

My question...how (if at all possible) can this information be included in
the schema that is returned from the web service and thus returned to the
proxy generation?

Randy



 
Reply With Quote
 
 
 
 
MSFT
Guest
Posts: n/a
 
      01-21-2004
Hi Randy,

I have replied your previous post and stated this is a limitation in .NET
Web service proxy. For some reason, you may not see my reply. I repost it
here. If you have any further question, please feel free to post in the
newgroup.

From: (MSFT)
Date: Tue, 20 Jan 2004 02:51:32 GMT
Subject: RE: Typed dataset returned from webservice incorrectly defined in
proxy - null value problem
Newsgroups: microsoft.public.dotnet.framework.aspnet.webservic es

Hi Randy,

Thank you for using MSDN Newsgroup. I am Luke and I am review this issue
currently. As I understand, your web service has a typed Dataset. When you
get the schema from proxy or "webservice.asmx?schema=xxxx", your found the
schema in result missed some attributes and namespace.

In fact, the support for XML schema is very limited here. The typical name
space are like:

<xs:schema id="DataSet1"
targetNamespace="http://www.tempuri.org/DataSet1.xsd"
xmlns:mstns="http://www.tempuri.org/DataSet1.xsd"
xmlns="http://www.tempuri.org/DataSet1.xsd"
xmlnss="http://www.w3.org/2001/XMLSchema"
xmlns:msdata="urn:schemas-microsoft-comml-msdata"
attributeFormDefault="qualified" elementFormDefault="qualified" >

Any other namespace will be ignored in the generated proxy. The attribute
in the other namespace is also ignored. This design is based on considering
of compatibility.

I think the work around is to import the xsd file in client project so that
we can get same definition for the type dataset.

Hope this help,

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Typed dataset problem - VS2005 web proxy ref ev ASP .Net Web Services 0 02-08-2006 10:06 AM
he expression is typed incorrectly or it is too complex to be evaluated ASP General 39 01-22-2004 09:41 PM
Typed dataset returned from webservice incorrectly defined in proxy - null value problem Randy Hayes ASP .Net Web Services 1 01-20-2004 02:51 AM
Typed dataset returned from webservice incorrectly defined in proxy - null value problem Randy Hayes ASP .Net Web Services 0 12-21-2003 04:59 PM
Repost: Problem Retrieving DataSet Returned By A WebService Programatix ASP .Net 1 07-17-2003 01:47 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57