Showing posts with label connection. Show all posts
Showing posts with label connection. Show all posts

Friday, March 30, 2012

Preferable way to use two servers

I use data from two SQL servers to make up a webpage. What is the preferable
way to fetch the data.
- Make two connection objects and connect to both servers. or
- Fetch data throug one connection by means of a linked server?mike,
From a security point of view, and probably also performance, two
connections from the web server.
--
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
mike wrote:
> I use data from two SQL servers to make up a webpage. What is the preferab
le way to fetch the data.
> - Make two connection objects and connect to both servers. or
> - Fetch data throug one connection by means of a linked server?

Preferable way to use two servers

I use data from two SQL servers to make up a webpage. What is the preferable way to fetch the data.
- Make two connection objects and connect to both servers. or
- Fetch data throug one connection by means of a linked server?
mike,
From a security point of view, and probably also performance, two
connections from the web server.
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
mike wrote:
> I use data from two SQL servers to make up a webpage. What is the preferable way to fetch the data.
> - Make two connection objects and connect to both servers. or
> - Fetch data throug one connection by means of a linked server?
sql

Preferable way to use two servers

I use data from two SQL servers to make up a webpage. What is the preferable way to fetch the data.
- Make two connection objects and connect to both servers. or
- Fetch data throug one connection by means of a linked server?mike,
From a security point of view, and probably also performance, two
connections from the web server.
--
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
mike wrote:
> I use data from two SQL servers to make up a webpage. What is the preferable way to fetch the data.
> - Make two connection objects and connect to both servers. or
> - Fetch data throug one connection by means of a linked server?

Friday, March 23, 2012

Powerbuilder 10.5.1.6662 Connection to SQL Server 2005

Recently, an application has been migrated from Powerbuilder 9.0 to
Powerbuilder 10.5 Build 6662. This application uses an .INI file
located in the Windows folder. The connection to the database, which
has also been migrated from SQL 2000 to SQL 2005 is as follows:
[database]
DBMS=OLE DB
Database=db_lps_prd_01
ServerName=USDANS402
dbParm=Connectstring=PROVIDER='SQLOLEDB',DATASOURC E='USDANS402',INTEGRATEDSX
ECURITY='SSPI',DATABASE=db_lps_prd_01
yet when a user tries to connect to this database, using an embedded
DECLARE and EXECUTE statement, and has access to other databases,
through Active Directory, the Powerbuilder application issues an
error: "you do not have the security credentials necessary to run the
application" Even if you fully qualify the procedure name SQL 2005
throw error 2812, which is equilavent to the application error. If
you remove the user from other databases, then the user can access
the
database in question. Now access to this database has 4 different
security levels in which users are assigned, and those security
levels
are Active Directory access accounts. The gist of it all seems to
be; between Powerbuilder 10.5.1 Build 6662 and SQL Server 2005, when
using the connectivity string defined in the .INI file, apparently
the
user is connecting to some other database trying to execute the
embedded procedure. Can anyone offer insight to this situation?
PowerBuilder? Really? I had not heard that there were any of those systems
still around. Good luck with that...
I think you're on the right track... check if the SQL Server has any links
established. Make sure the registered credentials are correct.
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant, Dad, Grandpa
Microsoft MVP
INETA Speaker
www.betav.com
www.betav.com/blog/billva
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
Visit www.hitchhikerguides.net to get more information on my latest book:
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
and Hitchhiker's Guide to SQL Server 2005 Compact Edition (EBook)
------
"dmmcgrue" <Donna.McGrue@.amgreetings.com> wrote in message
news:1186146671.268576.31950@.z24g2000prh.googlegro ups.com...
Recently, an application has been migrated from Powerbuilder 9.0 to
Powerbuilder 10.5 Build 6662. This application uses an .INI file
located in the Windows folder. The connection to the database, which
has also been migrated from SQL 2000 to SQL 2005 is as follows:
[database]
DBMS=OLE DB
Database=db_lps_prd_01
ServerName=USDANS402
dbParm=Connectstring=PROVIDER='SQLOLEDB',DATASOURC E='USDANS402',INTEGRATEDSX
ECURITY='SSPI',DATABASE=db_lps_prd_01
yet when a user tries to connect to this database, using an embedded
DECLARE and EXECUTE statement, and has access to other databases,
through Active Directory, the Powerbuilder application issues an
error: "you do not have the security credentials necessary to run the
application" Even if you fully qualify the procedure name SQL 2005
throw error 2812, which is equilavent to the application error. If
you remove the user from other databases, then the user can access
the
database in question. Now access to this database has 4 different
security levels in which users are assigned, and those security
levels
are Active Directory access accounts. The gist of it all seems to
be; between Powerbuilder 10.5.1 Build 6662 and SQL Server 2005, when
using the connectivity string defined in the .INI file, apparently
the
user is connecting to some other database trying to execute the
embedded procedure. Can anyone offer insight to this situation?

Powerbuilder 10.5.1.6662 Connection to SQL Server 2005

Recently, an application has been migrated from Powerbuilder 9.0 to
Powerbuilder 10.5 Build 6662. This application uses an .INI file
located in the Windows folder. The connection to the database, which
has also been migrated from SQL 2000 to SQL 2005 is as follows:
[database]
DBMS=3DOLE DB
Database=3Ddb_lps_prd_01
ServerName=3DUSDANS402
dbParm=3DConnectstring=3DPROVIDER=3D'SQL
OLEDB',DATASOURCE=3D'USDANS402',INT=
EGRATEDS=AD
ECURITY=3D'SSPI',DATABASE=3Ddb_lps_prd_0
1
yet when a user tries to connect to this database, using an embedded
DECLARE and EXECUTE statement, and has access to other databases,
through Active Directory, the Powerbuilder application issues an
error: "you do not have the security credentials necessary to run the
application" Even if you fully qualify the procedure name SQL 2005
throw error 2812, which is equilavent to the application error. If
you remove the user from other databases, then the user can access
the
database in question. Now access to this database has 4 different
security levels in which users are assigned, and those security
levels
are Active Directory access accounts. The gist of it all seems to
be; between Powerbuilder 10.5.1 Build 6662 and SQL Server 2005, when
using the connectivity string defined in the .INI file, apparently
the
user is connecting to some other database trying to execute the
embedded procedure. Can anyone offer insight to this situation?PowerBuilder? Really? I had not heard that there were any of those systems
still around. Good luck with that...
I think you're on the right track... check if the SQL Server has any links
established. Make sure the registered credentials are correct.
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant, Dad, Grandpa
Microsoft MVP
INETA Speaker
www.betav.com
www.betav.com/blog/billva
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
Visit www.hitchhikerguides.net to get more information on my latest book:
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
and Hitchhiker's Guide to SQL Server 2005 Compact Edition (EBook)
----
---
"dmmcgrue" <Donna.McGrue@.amgreetings.com> wrote in message
news:1186146671.268576.31950@.z24g2000prh.googlegroups.com...
Recently, an application has been migrated from Powerbuilder 9.0 to
Powerbuilder 10.5 Build 6662. This application uses an .INI file
located in the Windows folder. The connection to the database, which
has also been migrated from SQL 2000 to SQL 2005 is as follows:
[database]
DBMS=OLE DB
Database=db_lps_prd_01
ServerName=USDANS402
dbParm=Connectstring=PROVIDER='SQLOLEDB'
,DATASOURCE='USDANS402',INTEGRATEDS_
ECURITY='SSPI',DATABASE=db_lps_prd_01
yet when a user tries to connect to this database, using an embedded
DECLARE and EXECUTE statement, and has access to other databases,
through Active Directory, the Powerbuilder application issues an
error: "you do not have the security credentials necessary to run the
application" Even if you fully qualify the procedure name SQL 2005
throw error 2812, which is equilavent to the application error. If
you remove the user from other databases, then the user can access
the
database in question. Now access to this database has 4 different
security levels in which users are assigned, and those security
levels
are Active Directory access accounts. The gist of it all seems to
be; between Powerbuilder 10.5.1 Build 6662 and SQL Server 2005, when
using the connectivity string defined in the .INI file, apparently
the
user is connecting to some other database trying to execute the
embedded procedure. Can anyone offer insight to this situation?

Monday, March 12, 2012

Possible to use a Sharepoint List as a Datasource?

In Reporting Services 2005, is it possible to create a data connection to a sharepoint list? If so, what connection type and connection string do i use for this?It is possible using the Xml Data processing extension. Sharepoint exposes a Lists.asmx webservice, which can be queried using the Xml data processing extension.

Connection String:
http://<YourServerName>/sites/sitename/_vti_bin/Lists.asmx

Xml Query:

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetList">
</Method>
<ElementPath IgnoreNamspaces="true">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Dataset Parameter:
Name: listName, Value: The name of the list you want from the site.

Notes:
You may need to play with the ElementPath to get what you need. See this page for more information: http://msdn2.microsoft.com/en-us/library/ms365158.aspx|||

This is good as I have this exact requirement, but get

TITLE: Microsoft Report Designer

An error occurred while executing the query.
Failed to execute web request for the specified URL.


ADDITIONAL INFORMATION:

Failed to execute web request for the specified URL. (Microsoft.ReportingServices.DataExtensions)

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>Exception of type Microsoft.SharePoint.SoapServer.SoapServerException was thrown.</faultstring>
<detail>
<errorstring xmlns="http://schemas.microsoft.com/sharepoint/soap/">Value cannot be null.</errorstring>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>


BUTTONS:

OK

Any ideas

|||

I would suggest that you use the informations provided by Teun Duynstee in this link:

http://www.teuntostring.net/blog/2005/09/reporting-over-sharepoint-lists-with.html

Cheers
Markus

|||The error that you are getting for the GetList method is most likely caused by not using the correct name of the list. The listName must be either the title or the GUID for the list.

For more info on this method http://msdn.microsoft.com/library/default.asp?url=/library/en-us/spptsdk/html/soapmListsGetList_SV01034346.asp

|||

Hi,

In case you are interested we are selling a reporting services (both 2000 and 2005 version) data extension for sharepoint.

This extension makes it possible to build report using sharepoint lists (including libraries).

Several lists may be joined using SQL-like operators.

Reports parameters may be used with the query string.

An evaluation version is available on our site at http://www.enesyssoftware.com/Default.aspx?tabid=56

If you prefer to do it by yourself, the article from Teun Duynstee is the way to go.

Frdric LATOUR

http://www.enesyssoftware.com

|||

Hi,

I have the same requirement of getting the data from List in SharePoint 2007. It exposed the method GetList(). I am using the same code which you have mentioned. But is not working.

Reporting Service SP 2 provide XML DataSource

Can you please rectify where i am going wrong. I have a List by name say: Announcements

How to Specify List Name and Where? I am unable to undertand your Dataset Parameter.

Dataset Parameter:
Name: listName, Value: The name of the list you want from the site.

I tried few combinations.

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/Announcements</ElementPath>
</Query>

Please help. As this will save me from writing DATA Extensions for my reports integration with sharepoint 2007

|||There are two ways to specify parameters for an Xml Data Processing Extension query.

1. Use the Reporting Services Dataset query parameters collection.

Add a query parameter to the dataset with the name 'listName' and value 'Announcements'.

2. Add the parameters directly to the Xmlk query, using the Parameters Xml element, which is a child of the Method element.

Add the following Xml as the child element to the Method element in the query above.

<Parameters>
<Parameter Name="listName">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>

Ian|||

Hi,

I tried as you said now my query is. Previoisly i was not in sharepoint integration mode. so i was giving another error. Now i am getting the error as "Error While reading XML reponse"

My Data Source is:
http://localhost/Docs/vti_bin/Lists.asmx

My Query is :
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName" Type="String">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath>GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

My Web Service is :

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
<soap12:Body>
<GetListResponse xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<GetListResult>
<xsd:schema>schema</xsd:schema>xml</GetListResult>
</GetListResponse>
</soap12:Body>
</soap12:Envelope>

I have tried all combinations. 1) Isn't there any tool where i can construct this query 2) I am not able to view the dataset result in XML, so that i can map it with <ElementPath>. I am not able to test webservice with this "http://localhost/Docs/_vti_bin/Lists.asmx?op=GetList" URL, to view the dataset result.

|||
The exception you see being thrown is usually a wrapped exception that occurs in the call in the request/response phase, most likely a permissions issue. Check the log files for more information about this exception.

Also, regarding the ElementPath:

Try setting the IgnoreNamespaces attribute to true on the ElementPath element:

<ElementPath IgnoreNamespaces="true">

Answers to your questions:

1. Unfortunately, no, there is no tool at this time.
2. After you set the attribute mentioned above, try making the ElementPath less restrictive and to return the Xml as is. For example, this will return one field containing the raw Xml of the GetListResult element. You can use this to information see what the elements are in the GetListResult.

<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>

Ian|||

Hi,

This time i tried all below combionations bit its still not working. I have wasted lot of effots on this and this is very important for me to get it solved.

ERROR its Gives in Log is
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><soap:Fault><faultcode>soap:Server</faultcode><faultstring>Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown.</faultstring><detail><errorstring xmlns="http://schemas.microsoft.com/sharepoint/soap/">Value cannot be null.</errorstring></detail></soap:Fault></soap:Body></soap:Envelope>

http://localhost/_vti_bin/Lists.asmx

GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Name="GetList" Namespace= "http://schemas.microsoft.com/sharepoint/soap">
<Parameters>
<Parameter Name="listName">
<DefaultValue>21CF03AF-3A7E-479C-98E0-CBE0F16A594A</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>
</Query>

WithOut GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Name="GetList" Namespace= "http://schemas.microsoft.com/sharepoint/soap">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Contacts</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>
</Query>

GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>21CF03AF-3A7E-479C-98E0-CBE0F16A594A</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>


WithOut GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Contacts</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Please Help!!!

|||Ok, I tracked down the culprit. The Method element in your tests and the example I provided above differ very slightly. The namespace for the web service ends with a '/', which was mssing from in your query. This caused the method portion of the soap request sent to the server to exist in a different namespace than was expected, which caused it to be interpreted as null.

To reslove this issue, append a '/' to end of the Namespace attribute value in the Method element.

Ian|||

Thanks a lot it worked.

Working Query is

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Possible to use a Sharepoint List as a Datasource?

In Reporting Services 2005, is it possible to create a data connection to a sharepoint list? If so, what connection type and connection string do i use for this?It is possible using the Xml Data processing extension. Sharepoint exposes a Lists.asmx webservice, which can be queried using the Xml data processing extension.

Connection String:
http://<YourServerName>/sites/sitename/_vti_bin/Lists.asmx

Xml Query:

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetList">
</Method>
<ElementPath IgnoreNamspaces="true">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Dataset Parameter:
Name: listName, Value: The name of the list you want from the site.

Notes:
You may need to play with the ElementPath to get what you need. See this page for more information: http://msdn2.microsoft.com/en-us/library/ms365158.aspx|||

This is good as I have this exact requirement, but get

TITLE: Microsoft Report Designer

An error occurred while executing the query.
Failed to execute web request for the specified URL.


ADDITIONAL INFORMATION:

Failed to execute web request for the specified URL. (Microsoft.ReportingServices.DataExtensions)

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>Exception of type Microsoft.SharePoint.SoapServer.SoapServerException was thrown.</faultstring>
<detail>
<errorstring xmlns="http://schemas.microsoft.com/sharepoint/soap/">Value cannot be null.</errorstring>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>


BUTTONS:

OK

Any ideas

|||

I would suggest that you use the informations provided by Teun Duynstee in this link:

http://www.teuntostring.net/blog/2005/09/reporting-over-sharepoint-lists-with.html

Cheers
Markus

|||The

error that you are getting for the GetList method is most likely caused

by not using the correct name of the list. The listName must be either the

title or the GUID for the list.

For more info on this method http://msdn.microsoft.com/library/default.asp?url=/library/en-us/spptsdk/html/soapmListsGetList_SV01034346.asp

|||

Hi,

In case you are interested we are selling a reporting services (both 2000 and 2005 version) data extension for sharepoint.

This extension makes it possible to build report using sharepoint lists (including libraries).

Several lists may be joined using SQL-like operators.

Reports parameters may be used with the query string.

An evaluation version is available on our site at http://www.enesyssoftware.com/Default.aspx?tabid=56

If you prefer to do it by yourself, the article from Teun Duynstee is the way to go.

Frdric LATOUR

http://www.enesyssoftware.com

|||

Hi,

I have the same requirement of getting the data from List in SharePoint 2007. It exposed the method GetList(). I am using the same code which you have mentioned. But is not working.

Reporting Service SP 2 provide XML DataSource

Can you please rectify where i am going wrong. I have a List by name say: Announcements

How to Specify List Name and Where? I am unable to undertand your Dataset Parameter.

Dataset Parameter:
Name: listName, Value: The name of the list you want from the site.

I tried few combinations.

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/Announcements</ElementPath>
</Query>

Please help. As this will save me from writing DATA Extensions for my reports integration with sharepoint 2007

|||There are two ways to specify parameters for an Xml Data Processing Extension query.

1. Use the Reporting Services Dataset query parameters collection.

Add a query parameter to the dataset with the name 'listName' and value 'Announcements'.

2. Add the parameters directly to the Xmlk query, using the Parameters Xml element, which is a child of the Method element.

Add the following Xml as the child element to the Method element in the query above.

<Parameters>
<Parameter Name="listName">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>

Ian|||

Hi,

I tried as you said now my query is. Previoisly i was not in sharepoint integration mode. so i was giving another error. Now i am getting the error as "Error While reading XML reponse"

My Data Source is:
http://localhost/Docs/vti_bin/Lists.asmx

My Query is :
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName" Type="String">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath>GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

My Web Service is :

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
<soap12:Body>
<GetListResponse xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<GetListResult>
<xsd:schema>schema</xsd:schema>xml</GetListResult>
</GetListResponse>
</soap12:Body>
</soap12:Envelope>

I have tried all combinations. 1) Isn't there any tool where i can construct this query 2) I am not able to view the dataset result in XML, so that i can map it with <ElementPath>. I am not able to test webservice with this "http://localhost/Docs/_vti_bin/Lists.asmx?op=GetList" URL, to view the dataset result.

|||
The exception you see being thrown is usually a wrapped exception that occurs in the call in the request/response phase, most likely a permissions issue. Check the log files for more information about this exception.

Also, regarding the ElementPath:

Try setting the IgnoreNamespaces attribute to true on the ElementPath element:

<ElementPath IgnoreNamespaces="true">

Answers to your questions:

1. Unfortunately, no, there is no tool at this time.
2. After you set the attribute mentioned above, try making the ElementPath less restrictive and to return the Xml as is. For example, this will return one field containing the raw Xml of the GetListResult element. You can use this to information see what the elements are in the GetListResult.

<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>

Ian|||

Hi,

This time i tried all below combionations bit its still not working. I have wasted lot of effots on this and this is very important for me to get it solved.

ERROR its Gives in Log is
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><soap:Fault><faultcode>soap:Server</faultcode><faultstring>Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown.</faultstring><detail><errorstring xmlns="http://schemas.microsoft.com/sharepoint/soap/">Value cannot be null.</errorstring></detail></soap:Fault></soap:Body></soap:Envelope>

http://localhost/_vti_bin/Lists.asmx

GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Name="GetList" Namespace= "http://schemas.microsoft.com/sharepoint/soap">
<Parameters>
<Parameter Name="listName">
<DefaultValue>21CF03AF-3A7E-479C-98E0-CBE0F16A594A</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>
</Query>

WithOut GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Name="GetList" Namespace= "http://schemas.microsoft.com/sharepoint/soap">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Contacts</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>
</Query>

GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>21CF03AF-3A7E-479C-98E0-CBE0F16A594A</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>


WithOut GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Contacts</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Please Help!!!

|||Ok, I tracked down the culprit. The Method element in your tests and the example I provided above differ very slightly. The namespace for the web service ends with a '/', which was mssing from in your query. This caused the method portion of the soap request sent to the server to exist in a different namespace than was expected, which caused it to be interpreted as null.

To reslove this issue, append a '/' to end of the Namespace attribute value in the Method element.

Ian|||

Thanks a lot it worked.

Working Query is

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Possible to use a Sharepoint List as a Datasource?

In Reporting Services 2005, is it possible to create a data connection to a sharepoint list? If so, what connection type and connection string do i use for this?It is possible using the Xml Data processing extension. Sharepoint exposes a Lists.asmx webservice, which can be queried using the Xml data processing extension.

Connection String:
http://<YourServerName>/sites/sitename/_vti_bin/Lists.asmx

Xml Query:

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetList">
</Method>
<ElementPath IgnoreNamspaces="true">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Dataset Parameter:
Name: listName, Value: The name of the list you want from the site.

Notes:
You may need to play with the ElementPath to get what you need. See this page for more information: http://msdn2.microsoft.com/en-us/library/ms365158.aspx|||

This is good as I have this exact requirement, but get

TITLE: Microsoft Report Designer

An error occurred while executing the query.
Failed to execute web request for the specified URL.


ADDITIONAL INFORMATION:

Failed to execute web request for the specified URL. (Microsoft.ReportingServices.DataExtensions)

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>Exception of type Microsoft.SharePoint.SoapServer.SoapServerException was thrown.</faultstring>
<detail>
<errorstring xmlns="http://schemas.microsoft.com/sharepoint/soap/">Value cannot be null.</errorstring>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>


BUTTONS:

OK

Any ideas

|||

I would suggest that you use the informations provided by Teun Duynstee in this link:

http://www.teuntostring.net/blog/2005/09/reporting-over-sharepoint-lists-with.html

Cheers
Markus

|||The

error that you are getting for the GetList method is most likely caused

by not using the correct name of the list. The listName must be either the

title or the GUID for the list.

For more info on this method http://msdn.microsoft.com/library/default.asp?url=/library/en-us/spptsdk/html/soapmListsGetList_SV01034346.asp

|||

Hi,

In case you are interested we are selling a reporting services (both 2000 and 2005 version) data extension for sharepoint.

This extension makes it possible to build report using sharepoint lists (including libraries).

Several lists may be joined using SQL-like operators.

Reports parameters may be used with the query string.

An evaluation version is available on our site at http://www.enesyssoftware.com/Default.aspx?tabid=56

If you prefer to do it by yourself, the article from Teun Duynstee is the way to go.

Frdric LATOUR

http://www.enesyssoftware.com

|||

Hi,

I have the same requirement of getting the data from List in SharePoint 2007. It exposed the method GetList(). I am using the same code which you have mentioned. But is not working.

Reporting Service SP 2 provide XML DataSource

Can you please rectify where i am going wrong. I have a List by name say: Announcements

How to Specify List Name and Where? I am unable to undertand your Dataset Parameter.

Dataset Parameter:
Name: listName, Value: The name of the list you want from the site.

I tried few combinations.

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/Announcements</ElementPath>
</Query>

Please help. As this will save me from writing DATA Extensions for my reports integration with sharepoint 2007

|||There are two ways to specify parameters for an Xml Data Processing Extension query.

1. Use the Reporting Services Dataset query parameters collection.

Add a query parameter to the dataset with the name 'listName' and value 'Announcements'.

2. Add the parameters directly to the Xmlk query, using the Parameters Xml element, which is a child of the Method element.

Add the following Xml as the child element to the Method element in the query above.

<Parameters>
<Parameter Name="listName">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>

Ian|||

Hi,

I tried as you said now my query is. Previoisly i was not in sharepoint integration mode. so i was giving another error. Now i am getting the error as "Error While reading XML reponse"

My Data Source is:
http://localhost/Docs/vti_bin/Lists.asmx

My Query is :
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName" Type="String">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath>GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

My Web Service is :

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
<soap12:Body>
<GetListResponse xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<GetListResult>
<xsd:schema>schema</xsd:schema>xml</GetListResult>
</GetListResponse>
</soap12:Body>
</soap12:Envelope>

I have tried all combinations. 1) Isn't there any tool where i can construct this query 2) I am not able to view the dataset result in XML, so that i can map it with <ElementPath>. I am not able to test webservice with this "http://localhost/Docs/_vti_bin/Lists.asmx?op=GetList" URL, to view the dataset result.

|||
The exception you see being thrown is usually a wrapped exception that occurs in the call in the request/response phase, most likely a permissions issue. Check the log files for more information about this exception.

Also, regarding the ElementPath:

Try setting the IgnoreNamespaces attribute to true on the ElementPath element:

<ElementPath IgnoreNamespaces="true">

Answers to your questions:

1. Unfortunately, no, there is no tool at this time.
2. After you set the attribute mentioned above, try making the ElementPath less restrictive and to return the Xml as is. For example, this will return one field containing the raw Xml of the GetListResult element. You can use this to information see what the elements are in the GetListResult.

<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>

Ian|||

Hi,

This time i tried all below combionations bit its still not working. I have wasted lot of effots on this and this is very important for me to get it solved.

ERROR its Gives in Log is
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><soap:Fault><faultcode>soap:Server</faultcode><faultstring>Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown.</faultstring><detail><errorstring xmlns="http://schemas.microsoft.com/sharepoint/soap/">Value cannot be null.</errorstring></detail></soap:Fault></soap:Body></soap:Envelope>

http://localhost/_vti_bin/Lists.asmx

GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Name="GetList" Namespace= "http://schemas.microsoft.com/sharepoint/soap">
<Parameters>
<Parameter Name="listName">
<DefaultValue>21CF03AF-3A7E-479C-98E0-CBE0F16A594A</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>
</Query>

WithOut GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Name="GetList" Namespace= "http://schemas.microsoft.com/sharepoint/soap">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Contacts</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">GetListResponse{GetListResult(XML)}</ElementPath>
</Query>

GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>21CF03AF-3A7E-479C-98E0-CBE0F16A594A</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>


WithOut GUID
<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Contacts</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Please Help!!!

|||Ok, I tracked down the culprit. The Method element in your tests and the example I provided above differ very slightly. The namespace for the web service ends with a '/', which was mssing from in your query. This caused the method portion of the soap request sent to the server to exist in a different namespace than was expected, which caused it to be interpreted as null.

To reslove this issue, append a '/' to end of the Namespace attribute value in the Method element.

Ian|||

Thanks a lot it worked.

Working Query is

<Query>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetList</SoapAction>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetList">
<Parameters>
<Parameter Name="listName">
<DefaultValue>Announcements</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="True">GetListResponse{}/GetListResult{}/List/Fields/Field</ElementPath>
</Query>

Friday, March 9, 2012

Possible to have link server in the connection string?

Hi,
I have an application which requires a server name (connection string)
in the configuration for connection. There isn't any big issue if I am
just connecting to a regular server. e.g. just entering the server
name (server1), however, now my question is is it possible to put in a
linked server within a server name e.g. server1..linkserver1? In fact,
I need the connection to linkserver1 instead. I have a linkserver
since the server can't be connected directly.
Please advice the exact format (e.g. server1..linkserver1 ) if there
is any. Thanks in advance. And your help would be greatly appreciated.On Feb 28, 12:26=A0pm, sweetpota...@.gmail.com wrote:
> Hi,
> I have an application which requires a server name (connection string)
> in the configuration for connection. There isn't any big issue if I am
> just connecting to a regular server. e.g. just entering the server
> name (server1), however, now my question is is it possible to put in a
> linked server within a server name e.g. server1..linkserver1? In fact,
> I need the connection to linkserver1 instead. I have a linkserver
> since the server can't be connected directly.
> Please advice the exact format (e.g. server1..linkserver1 ) if there
> is any. Thanks in advance. And your help would be greatly appreciated.
Or
If this is the configuration setup:
Server Name: Server1
Database Name: linkserver1..DB1
Will that work?
Thanks

Possible to have link server in the connection string?

Hi,
I have an application which requires a server name (connection string)
in the configuration for connection. There isn't any big issue if I am
just connecting to a regular server. e.g. just entering the server
name (server1), however, now my question is is it possible to put in a
linked server within a server name e.g. server1..linkserver1? In fact,
I need the connection to linkserver1 instead. I have a linkserver
since the server can't be connected directly.
Please advice the exact format (e.g. server1..linkserver1 ) if there
is any. Thanks in advance. And your help would be greatly appreciated.
On Feb 28, 12:26Xpm, sweetpota...@.gmail.com wrote:
> Hi,
> I have an application which requires a server name (connection string)
> in the configuration for connection. There isn't any big issue if I am
> just connecting to a regular server. e.g. just entering the server
> name (server1), however, now my question is is it possible to put in a
> linked server within a server name e.g. server1..linkserver1? In fact,
> I need the connection to linkserver1 instead. I have a linkserver
> since the server can't be connected directly.
> Please advice the exact format (e.g. server1..linkserver1 ) if there
> is any. Thanks in advance. And your help would be greatly appreciated.
Or
If this is the configuration setup:
Server Name: Server1
Database Name: linkserver1..DB1
Will that work?
Thanks