2009-02-25 81 views
-1

有没有人使用查询语言来提取从Web服务返回的数据。从Web服务返回的数据集中提取数据

我写了一个web服务返回的数据集,

[WebService(Namespace = "http://tempuri.org/")] 
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)] 
[ToolboxItem(false)] 
// To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
// [System.Web.Script.Services.ScriptService] 
public class Service1 : System.Web.Services.WebService 
{ 

    [WebMethod] 
    public DataSet GetData() 
    { 
     AWDS ds = new AWDS();//AWDS is my dataset class name 
     SalesPersonTableAdapter ta = new SalesPersonTableAdapter(); 
     ta.Fill(ds.SalesPerson); 
     return ds; 
    } 
} 

我用这个查询我的资源

<Query> 
<Method Namespace="http://tempuri.org/" Name="GetData"> 
</Method> 
<SoapAction>http://tempuri.org/GetData</SoapAction> 
</Query> 

“什么此查询语言名为”

,但我得到发现数据集的架构(我的表列显示为记录)。

我想了解更多如何获取某个表的模式。

谢谢

回答

-1

请尝试更清楚您的要求。我不知道你发布的这个“查询”XML是什么。它根本不是查询语言。

另外,您应该避免从Web服务返回DataSet。它不能与非.NET平台进行互操作,有时也不能与.NET进行互操作。


我在MSDN上的xmlDP上发现了一些资源。见xmldp query syntax

我希望有帮助。

+0

好吧,这是一个名为xmlDP查询语言用于航行通过从Web服务返回WXL,我遇到一个缺乏的资源 – netseng 2009-02-25 12:13:05

0

转到您的Web服务的URL并在其末尾添加?wsdl。

查找wsdl:定义并查看targetNamespace属性。此值是方法命名空间属性应设置为您的查询。

找到WSDL:操作元素,其属性等于要使用,并期待在肥皂的方法:操作下方。看看soapAction属性的值。这个值就是你在查询中将要放置在SoapAction元素中的值。

另外,请参见以下内容:

Reporting Services: Using XML and Web Service Data Sources

XML Query Syntax for Specifying XML Report Data (SSRS)

相关问题