I have built a Visual Studio project to consume a a 3rd party web service. The goal is to export CSV data. This is my first time consuming a web service so not sure what I am doing.
Here is the information that the web service has provided me (some info changed to protect my data):
Web Services Page, WSDL, and DataSource for Web Services Export:
https://reportservices.credtest.com/reports/ExportService.asmx
Encrypted Connection String:
GG3FakeStringgvwkdR4aCjKiu591-aUB2cfN18cYlNyqcpLD0V291y1gnZawA__
Query for Dataset Export:
<Query>
<SoapAction>
https://reportservices.credtest.com/ExportDataSet
</SoapAction>
<Method Namespace="https://reportservices.credtest.com/" Name="ExportDataSet">
<Parameters>
<Parameter Name="connection" Type="String">
<DefaultValue>
GG3FakeStringgvwkdR4aCjKiu591-aUB2cfN18cYlNyqcpLD0V291y1gnZawA__
</DefaultValue>
</Parameter>
<Parameter Name="start_date" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="end_date" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="custom_param1" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="custom_param2" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="custom_param3" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">
ExportDataSetResponse{}/ExportDataSetResult{}/diffgram{}/NewDataSet{}/Table{CPT_Code,Description,Other_Code,CPT_Modifier,Service_ID,Service,Service_Description,Program_ID,Program,Pgm_Dsc,Start_Minutes,End_Minutes,Matrix_ID,Start_Age,End_Age,Claim_Format,Credential_Group,RollUp_Code,Rate,Deaf_Rate,Fixed_Units,First_Unit_Minutes,Unit_Minutes,Unit_Multiplier}
</ElementPath>
</Query>
Query for XML Export:
<Query>
<SoapAction>
https://reportservices.credtest.com/ExportXML
</SoapAction>
<Method Namespace="https://reportservices.credtest.com/" Name="ExportXML">
<Parameters>
<Parameter Name="connection" Type="String">
<DefaultValue>
GG3FakeStringgvwkdR4aCjKiu591-aUB2cfN18cYlNyqcpLD0V291y1gnZawA__
</DefaultValue>
</Parameter>
<Parameter Name="start_date" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="end_date" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="custom_param1" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="custom_param2" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
<Parameter Name="custom_param3" Type="String">
<DefaultValue>
</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">
ExportXMLResponse{}/ExportXMLResult{}/diffgram{}/NewDataSet{}/Table{CPT_Code,Description,Other_Code,CPT_Modifier,Service_ID,Service,Service_Description,Program_ID,Program,Pgm_Dsc,Start_Minutes,End_Minutes,Matrix_ID,Start_Age,End_Age,Claim_Format,Credential_Group,RollUp_Code,Rate,Deaf_Rate,Fixed_Units,First_Unit_Minutes,Unit_Minutes,Unit_Multiplier}
</ElementPath>
</Query>
Here is the description of what is happening.
Every time I try to add a Connected service I get an error, either when adding the service (WCF) or when doing a build (gRPC or OpenAPI).
I go to Connected Services > Manage Connected Services
This opens the Service References (OpenAPI, gRPC, WCF Web Service) window.
I click on “Add a new service reference”. This opens the Add Service Reference window and shows 3 choices to pick from (OpenAPI, gRPC, WCF Web Service).
I have tried both OpenAPI and gRPC and get errors when doing a build.
WCF gives me an error during the
If I choose Open API then the “Add a new OpenAPI service reference” window opens.
I fill out the form with the following information:
URL: https://reportservices.credtest.com/reports/ExportService.asmx (link changed to protect my data)
Namespace: CredNS
Class Name: CredCN
Code Generation Language: C#
Severity : Error
Code: MSB3073
Description: The command ""C:\Users\dwoodard.nuget\packages\nswag.msbuild\13.0.5\build../tools/Win/NSwag.exe" openapi2csclient /className:CredCN /namespace:CredNS /input:C:\Users\dwoodard\source\repos\CredibleCoreWebApp\CredibleCoreWebApp\OpenAPIs\ExportService2.asmx /output:obj\ExportService2Client.cs " exited with code -1
Project CredibleCoreWebApp
File: C:\Users\dwoodard.nuget\packages\nswag.apidescription.client\13.0.5\build\NSwag.ApiDescription.Client.targets
Line 28
Column 5
Suppression State
If I choose gRPC then the “Add a new gRPC service reference” window opens.
I fill out the form with the following information:
URL: https://reportservices.credtest.com/reports/ExportService.asmx
Select the type of class to be generated: Client (I have also tried server and “Client and Server”)
I get the result “Successfully added service Reference(s)”.
If I click on “view generated code” then I get the following error:
Unable to get the generated codefiles for gRPC service reference ExportService2. You may need to build the project first.
I immediately do a build and get 82 errors.
Error #1:
Severity : Error
Code:
Description: \src\github\grpc\workspace_protoc_windows_x64\third_party\protobuf\src\google\protobuf\compiler\parser.cc:648] No syntax specified for the proto file: Protos/ExportService2.asmx. Please use 'syntax = "proto2";' or 'syntax = "proto3";' to specify a syntax version. (Defaulted to proto2 syntax.)
Project: CredibleCoreWebApp
File: C:\Users\dwoodard\source\repos\CredibleCoreWebApp\CredibleCoreWebApp[libprotobuf WARNING T
Line: 1
Column: 1
Suppression State:
The many errors following are like this:
Expected top-level statement (e.g. "message").
Need space between number and identifier.
"e" must be followed by exponent.
WCF Gives errors when trying to add so never succeeds.
I enter the URI: https://reportservices.credtest.com/reports/ExportService.asmx
Click GO
Services: reports/ExportService.asmx (automatically populated)
Status: Warning: One or more errors occurred.
Error Details:
Cannot import wsdl:port\r\nDetail: \r\nXPath to Error Source: //wsdl:definitions[#targetNamespace='https://www.credtest.com/']/wsdl:service[#name='ExportService']/wsdl:port[#name='ExportServiceHttpPost']
Cannot import wsdl:binding\r\nDetail: The required WSDL extension element 'binding' from namespace 'http://schemas.xmlsoap.org/wsdl/http/' was not handled.\r\nXPath to Error Source: //wsdl:definitions[#targetNamespace='https://www.credtest.com/']/wsdl:binding[#name='ExportServiceHttpPost']
Cannot import wsdl:port\r\nDetail: \r\nXPath to Error Source: //wsdl:definitions[#targetNamespace='https://www.credtest.com/']/wsdl:service[#name='ExportService']/wsdl:port[#name='ExportServiceHttpGet']
Cannot import wsdl:binding\r\nDetail: The required WSDL extension element 'binding' from namespace 'http://schemas.xmlsoap.org/wsdl/http/' was not handled.\r\nXPath to Error Source: //wsdl:definitions[#targetNamespace='https://www.credtest.com/']/wsdl:binding[#name='ExportServiceHttpGet']
Related
So i'm trying to build a c# binding from a Android AAR, and i was following this guide https://developer.xamarin.com/guides/android/advanced_topics/binding-a-java-library/binding-an-aar/
But i'm running into an error like this
Severity Code Description Project File Line Suppression State
Error CS0534 'VaultManagerPaymentMethodsAdapter' does not implement inherited abstract member 'RecyclerView.Adapter.OnBindViewHolder(RecyclerView.ViewHolder, int)' Braintree.DropIn Path\Braintree.DropIn\obj\Release\generated\src\Com.Braintreepayments.Api.Dropin.Adapters.VaultManagerPaymentMethodsAdapter.cs 9 Active
And
Severity Code Description Project File Line Suppression State
Error CS0534 'VaultManagerPaymentMethodsAdapter' does not implement inherited abstract member 'RecyclerView.Adapter.OnCreateViewHolder(ViewGroup, int)' Braintree.DropIn Path\Braintree.DropIn\obj\Release\generated\src\Com.Braintreepayments.Api.Dropin.Adapters.VaultManagerPaymentMethodsAdapter.cs 9 Active
But if i try to add things to MetaData, i get errors saying that its already defined
<add-node path="/api/package[#name='com.braintreepayments.api.dropin.adapters']/class[#name='VaultManagerPaymentMethodsAdapter']">
<method abstract="false"
deprecated="not deprecated"
final="false"
name="onBindViewHolder"
native="false"
return="void"
static="false"
synchronized="false"
visibility="public">
<parameter name="holder"
type="android.support.v7.widget.RecyclerView.ViewHolder">
</parameter>
<parameter name="position"
type="int">
</parameter>
</method>
</add-node>
<add-node path="/api/package[#name='com.braintreepayments.api.dropin.adapters']/class[#name='VaultManagerPaymentMethodsAdapter']">
<method abstract="false"
deprecated="not deprecated"
final="false"
name="onCreateViewHolder"
native="false"
return="android.support.v7.widget.RecyclerView.ViewHolder"
static="false"
synchronized="false"
visibility="public">
<parameter name="parent"
type="android.view.ViewGroup">
</parameter>
<parameter name="viewType"
type="int">
</parameter>
</method>
</add-node>
any inputs would be appreciated
The temporary solution to this was to remove the node , not the ideal solution but since i don't need that specific thing, i just removed it
For example, if I want only packages for .Net Platform Standard. Now I am looking for a package, try to install it, getting:
error: Package <name> is not compatible with netcoreapp1.0 (.NETCoreApp,Version=v1.0).
Package <name> supports: portable-win81+wpa81 (.NETPortable,Version=v0.0,Profile=Profile32)
error: One or more packages are incompatible with .NETCoreApp,Version=v1.0.
and I have to start again. I see the supported platforms. That means, the info is there.
Edit: It will be better if I can set a filter in Visual Studio, but I do not see such, I have not seen it in nuget.org too. So the question is: Is there a way to get packages only for certain platform (that means filter by platform search for something). What I am interested in is .Net Platform Standard. I hope, you do not see something vague here.
Edit:
Here is the search api from nuget.org
<edmx:Edmx xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx" Version="1.0">
<edmx:DataServices xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" m:DataServiceVersion="2.0" m:MaxDataServiceVersion="2.0">
<Schema xmlns="http://schemas.microsoft.com/ado/2006/04/edm" Namespace="NuGetGallery.OData">
<EntityType Name="V2FeedPackage" m:HasStream="true">...</EntityType>
</Schema>
<Schema xmlns="http://schemas.microsoft.com/ado/2006/04/edm" Namespace="NuGetGallery">
<EntityContainer Name="V2FeedContext" m:IsDefaultEntityContainer="true">
<EntitySet Name="Packages" EntityType="NuGetGallery.OData.V2FeedPackage"/>
<FunctionImport Name="Search" ReturnType="Collection(NuGetGallery.OData.V2FeedPackage)" EntitySet="Packages">
<Parameter Name="searchTerm" Type="Edm.String" FixedLength="false" Unicode="false"/>
<Parameter Name="targetFramework" Type="Edm.String" FixedLength="false" Unicode="false"/>
<Parameter Name="includePrerelease" Type="Edm.Boolean" Nullable="false"/>
</FunctionImport>
<FunctionImport Name="FindPackagesById" ReturnType="Collection(NuGetGallery.OData.V2FeedPackage)" EntitySet="Packages">
<Parameter Name="id" Type="Edm.String" FixedLength="false" Unicode="false"/>
</FunctionImport>
<FunctionImport Name="GetUpdates" ReturnType="Collection(NuGetGallery.OData.V2FeedPackage)" EntitySet="Packages">
<Parameter Name="packageIds" Type="Edm.String" FixedLength="false" Unicode="false"/>
<Parameter Name="versions" Type="Edm.String" FixedLength="false" Unicode="false"/>
<Parameter Name="includePrerelease" Type="Edm.Boolean" Nullable="false"/>
<Parameter Name="includeAllVersions" Type="Edm.Boolean" Nullable="false"/>
<Parameter Name="targetFrameworks" Type="Edm.String" FixedLength="false" Unicode="false"/>
<Parameter Name="versionConstraints" Type="Edm.String" FixedLength="false" Unicode="false"/>
</FunctionImport>
</EntityContainer>
</Schema>
</edmx:DataServices>
</edmx:Edmx>
When I use Search function, the 'searchTerm' parameter works, but not the 'targetFramework' parameter.
Another Edit: VisualStudio NuGet HTTP request in Fiddler:
GET /api/v2/Search()?$filter=IsAbsoluteLatestVersion&searchTerm='mvv'&targetFramework='netcoreapp1.0'&includePrerelease=true&$skip=0&$top=26 HTTP/1.1
The target framework is set automatically from Visual Studio NuGet Package Manager. What actually does not work is the targetFramework parameter in the search api from NuGet
NuGet has option to target the framework as mentioned in here
There is an open feature request matching your scenario on github
I feel there might a possibility to attain your filtering using power shell console scripts as I came across this page. See the section "Getting the FrameworkName".
I've been browsing dozens of sites to help me deploy a web service to an IIS using MsDeploy.
I need to create the application, modify application pool and enable protocols, and update a appSetting (that contains a connection string, don't ask me why).
I can do all of these, except applying the good Application pool.
Here's the parameters.xml file I added to the project :
<parameters>
<parameter tags="IisApp" defaultValue="Default Web Site/MyWebService" name="IIS Web Application Name">
<parameterEntry match="#defaultValue" scope="IisApp" kind="ProviderPath"/>
<parameterEntry match="#defaultValue" scope="setAcl" kind="ProviderPath"/>
</parameter>
<parameter name="Configuration Connection String" defaultValue="Some real Connection String in there" tags="">
<parameterEntry kind="XmlFile" scope="\\web.config$" match="/configuration/appSettings/add[#key='ConfigurationSQLConnectionString']/#value" />
</parameter>
<parameter name="Application Pool" defaultValue="MyOwnAppPool" description="Application pool for this site">
<parameterEntry kind="DeploymentObjectAttribute" scope="application" match="/application/#applicationPool" />
</parameter>
</parameters>
Here's the way I generate the package :
MsBuild MyWebService.csproj /T:Package /P:PackageLocation="c:\somewhere\package.zip" /P:IncludeAppPool=true /P:IncludeIisSettings=true
Here's the generated archive.xml file :
<sitemanifest MSDeploy.ObjectResolver.dirPath="Microsoft.Web.Deployment.DirPathObjectResolver" MSDeploy.ObjectResolver.filePath="Microsoft.Web.Deployment.FilePathObjectResolver">
<appHostConfig path="Default Web Site/MyWebService" MSDeploy.path="2" MSDeploy.MSDeployLinkName="Child1" MSDeploy.MSDeployKeyAttributeName="path" MSDeploy.MSDeployProviderOptions="some stuff">
<application path="/MyWebService" MSDeploy.path="2" applicationPool="DefaultAppPool" MSDeploy.applicationPool="1" enabledProtocols="http" MSDeploy.enabledProtocols="1" serviceAutoStartEnabled="false" MSDeploy.serviceAutoStartEnabled="1" serviceAutoStartProvider="" MSDeploy.serviceAutoStartProvider="1" MSDeploy.MSDeployLinkName="PathElement" MSDeploy.MSDeployKeyAttributeName="path">
<virtualDirectoryDefaults path="" MSDeploy.path="1" physicalPath="" MSDeploy.physicalPath="9" userName="" MSDeploy.userName="1" password="" MSDeploy.password="1" logonMethod="ClearText" MSDeploy.logonMethod="1" allowSubDirConfig="true" MSDeploy.allowSubDirConfig="1" MSDeploy.MSDeployLinkName="virtualDirectoryDefaults" />
<virtualDirectory path="/" MSDeploy.path="2" physicalPath="C:\somewhere\MyWebService" MSDeploy.physicalPath="8" userName="" MSDeploy.userName="1" password="" MSDeploy.password="1" logonMethod="ClearText" MSDeploy.logonMethod="1" allowSubDirConfig="true" MSDeploy.allowSubDirConfig="1" MSDeploy.MSDeployKeyAttributeName="path" />
</application>
</appHostConfig>
<contentPath path="C:\somewhere\MyWebService\obj\Debug\Package\PackageTmp" MSDeploy.path="2" MSDeploy.MSDeployLinkName="Child2" MSDeploy.MSDeployKeyAttributeName="path" MSDeploy.MSDeployProviderOptions="some other stuff">
<MSDeploy.dirPath path="C:\somewhere\MyWebSerivce\obj\Debug\Package\PackageTmp" MSDeploy.MSDeployLinkName="contentPath" />
</contentPath>
<setAcl path="C:\somewhere\MyWebService\obj\Debug\Package\PackageTmp" MSDeploy.path="2" isDest="AA==" MSDeploy.isDest.Type="Microsoft.Web.Deployment.DeploymentObjectBooleanAttributeValue" setAclUser="" MSDeploy.setAclUser="1" setAclAccess="Read" MSDeploy.setAclAccess="1" MSDeploy.MSDeployLinkName="Child3" MSDeploy.MSDeployKeyAttributeName="path" MSDeploy.MSDeployProviderOptions="still some stuff" />
<setAcl path="C:\somewhere\MyWebService\obj\Debug\Package\PackageTmp" MSDeploy.path="2" isDest="AA==" MSDeploy.isDest.Type="Microsoft.Web.Deployment.DeploymentObjectBooleanAttributeValue" setAclUser="anonymousAuthenticationUser" MSDeploy.setAclUser="1" setAclAccess="Read" MSDeploy.setAclAccess="1" MSDeploy.MSDeployLinkName="Child4" MSDeploy.MSDeployKeyAttributeName="path" MSDeploy.MSDeployProviderOptions="final stuff I guess" />
</sitemanifest>
Here's the generated parameters.xml :
<parameters>
<parameter name="IIS Web Application Name" defaultValue="Default Web Site/MyWebService" tags="IisApp">
<parameterEntry kind="ProviderPath" scope="AppHostConfig" match="^Default\ Web\ Site/MyWebService$" />
<parameterEntry kind="ProviderPath" scope="contentPath" match="^C:\\somewhere\\MyWebService\\obj\\Debug\\Package\\PackageTmp$" />
<parameterEntry kind="ProviderPath" scope="setAcl" match="^C:\\somewhere\\MyWebService\\obj\\Debug\\Package\\PackageTmp$" />
<parameterEntry kind="ProviderPath" scope="IisApp" match="#defaultValue" />
<parameterEntry kind="ProviderPath" scope="setAcl" match="#defaultValue" />
</parameter>
<parameter name="IIS Web Application Pool Name" defaultValue="DefaultAppPool">
<parameterEntry kind="DeploymentObjectAttribute" scope="application" match="application[#applicationPool='DefaultAppPool']/#applicationPool" />
</parameter>
<parameter name="IisVirtualDirectoryPhysicalPath" defaultValue="C:\somewhere\MyWebService" tags="PhysicalPath">
<parameterEntry kind="DestinationVirtualDirectory" scope=".*" match="^C:\\somewhere\\MyWebService$" />
</parameter>
<parameter name="Configuration Connection String" defaultValue="Some real Connection String in there">
<parameterEntry kind="XmlFile" scope="\\web.config$" match="/configuration/appSettings/add[#key='ConfigurationSQLConnectionString']/#value" />
</parameter>
<parameter name="Application Pool" description="Application pool for this site" defaultValue="MyOwnAppPool">
<parameterEntry kind="DeploymentObjectAttribute" scope="application" match="/application/#applicationPool" />
</parameter>
</parameters>
And finally, here's the command I launch to deploy the package :
msdeploy.exe -verb:sync -allowUntrusted -enableLink:AppPoolExtension -source:package="c:\somewhere\Package.zip" -dest:auto,computerName="https://destinationserver:8172/MsDeploy.axd?site=WebSite_Deployment",userName="destinationserver\deploymentUser",password="shouldKeepItSecret",authType="basic" -setParam:name="IIS Web Application Name",value="WebSite_Deployment/MyWebService" -setParam:name="Configuration Connection String",value="The Real Connection String" -setParam:name="Application Pool",value="FinalAppPool" -setParam:name="IIS Web Application Pool Name",value="FinalAppPool" -verbose
I get the following log :
Verbose: Parameter entry 'IIS Web Application Pool Name/1' is applicable to 'sitemanifest/appHostConfig[#path='Default Web Site/MyWebService']/application[#path='/MyWebService']' because of its scope.
Verbose: Parameter entry 'Application Pool/1' is applicable to 'sitemanifest/appHostConfig[#path='Default Web Site/MyWebService']/application[#path='/MyWebService']' because of its scope.
But finally, the application pool that is set DefaultAppPool (and not FinalAppPool as expected). I first thought that msdeploy took the default application pool value for the parameter "IIS Web Application Pool Name". but it always take DefaultAppPool.
I just don't understand why.
As you can see, I'm using basic authentication with a non administrator account. I've activated Management Delegation Service on destinationServer to delegate contentPath, iisApp and setAcl to current user, and createApp and appHostConfig to WDeployConfigWriter.
The fact that I added the parameter "Application Pool" is because I found this here.
But even if I keep only one of those two parameters (Application Pool and IIS Web Application Pool Name"), the 2nd one is always in the archive.xml because of the msbuild package parameter IncludeIisSettings=true. And the result is the same.
It doesn't seem to be a right issue, as long as the application pool is really set by msdeploy. It's just that it doesn't take the provided application pool.
We also have a similar problem for Enable Protocols.
Sorry for the length, but I wanted to be exhaustive.
Don't know how you're deploying, but maybe you can use a script (with postSync argument) as mentionned there:
.net WebDeploy is there any way to run command/script on the target machine after deploy
In this script you can do everything you want with appcmd:
https://learn.microsoft.com/en-us/iis/get-started/getting-started-with-iis/getting-started-with-appcmdexe
I am doing SSRS to retrieve data from two SharePoint lists. One is the viewing part and the other is for the filtering part.
This is easily done on a SQLServer database Data Source, but how can it be achieved using SharePoint lists?
The following is my query:
The #name is a report parameter retrieved from the other list.
<Query>
<Method Namespace="http://schemas.microsoft.com/sharepoint/soap/" Name="GetListItems">
<Parameters>
<Parameter Name="listName">
<DefaultValue>{D5D33A07-D1CA-440F-8A6B-912B9CE5BB2F}</DefaultValue>
</Parameter>
<Parameter Name="rowLimit">
<DefaultValue>9999</DefaultValue>
</Parameter>
<Parameter Name="viewName">
<DefaultValue>{F5459664-7C2F-4618-81FC-F2275FB2FBCF}</DefaultValue>
</Parameter>
</Parameters>
</Method>
<Where>
<Eq>
<FieldRef Name='ows_Firstname' />
<Value Type='Text'>#name</Value>
</Eq>
</Where>
<ElementPath IgnoreNamespaces="true">GetListItemsResponse/GetListItemsResult/listitems/data/row{#ows_EmployeeID,#ows_Firstname,#ows_Lastname,#ows_Department}</ElementPath>
<SoapAction>http://schemas.microsoft.com/sharepoint/soap/GetListItems</SoapAction>
</Query>
Please help.
Jane, you have two options:
SQL Server 2008 R2 comes with the Sharepoint List Connection type (see link for tutorial) where the connection is as easy as using an SQL data source.
If you are unfortunate and don't have access to that connection type you can make use of Sharepoint Web Services (specifically thelists.asmx service) for your XML query. See this tutorial: SQL Reporting Services data from SharePoint lists.
How can I prepare the configuration settings (App.config, maybe?) I need to use Enterprise Library Data Access Application Block in a C# console project?
Following is what I currently trying with an App.config in the console project. When I call DatabaseFactory.CreateDatabase(), it throws an exception which says:
"Configuration system failed to initialize"
<configuration>
<dataConfiguration>
<xmlSerializerSection type="Microsoft.Practices.EnterpriseLibrary.Data.
Configuration.DatabaseSettings, Microsoft.Practices.EnterpriseLibrary.Data,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null">
<enterpriseLibrary.databaseSettings xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" defaultInstance="Northwind"
xmlns="http://www.microsoft.com/practices/enterpriselibrary/08-31-2004/data">
<databaseTypes>
<databaseType name="Sql Server" type="Microsoft.Practices.EnterpriseLibrary.Data.Sql.SqlDatabase,
Microsoft.Practices.EnterpriseLibrary.Data, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=null" />
</databaseTypes>
<instances>
<instance name="Northwind" type="Sql Server" connectionString="Northwind" />
</instances>
<connectionStrings>
<connectionString name="Northwind">
<parameters>
<parameter name="Database" value="Northwind" isSensitive="false" />
<parameter name="Integrated Security" value="True" isSensitive="false" />
<parameter name="Server" value="local" isSensitive="false" />
<parameter name="User ID" value="sa" isSensitive="false" />
<parameter name="Password" value="sa1234" isSensitive="true" />
</parameters>
</connectionString>
</connectionStrings>
</enterpriseLibrary.databaseSettings>
</xmlSerializerSection>
</dataConfiguration>
</configuration>
Use the Enterprise Library Configuration Tool which is integrated into Visual Studio once you install the Enterprise Library - it will ensure your configuration XML is setup correctly.