Windward Engine API Reference
AdoDataSourceImpl Constructor(String,String)
See Also  Send comments on this topic.
net.windward.api.csharp Namespace > AdoDataSourceImpl Class > AdoDataSourceImpl Constructor : AdoDataSourceImpl Constructor(String,String)




providerName
The name of the provider. For example, for SqlServer this would be "System.Data.SqlClient".
connectionString
The connection string used in the DbConnection constructor.

Glossary Item Box

Create a DataSourceProvider that uses Ado to access a SQL database. This constructor calls new DbConnection(connectionString) to create a connection. Each forEach and query tag will also cause a connection to be created.
Example:
Access: "System.Data.Odbc", "Driver={Microsoft Access Driver (*.mdb, *.accdb)};Dbq=Northwind.mdb"
DB2: "IBM.Data.DB2", "server=db2.windwardreports.com;database=SAMPLE;Uid=demo;Pwd=demo;"
Excel: "System.Data.OleDb", "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=Northwind Mini - Data.xlsx;Extended Properties=\"Excel 12.0 Xml;HDR=YES\""
MySql: "MySql.Data.MySqlClient", "server=mysql.windwardreports.com;database=sakila;user id=demo;password=demo;"
ODBC: "System.Data.Odbc", "Driver={Sql Server};Server=localhost;Database=Northwind;User ID=test;Password=pass;"
OleDB: "System.Data.OleDb", "Provider=sqloledb;Data Source=localhost;Initial Catalog=Northwind;User ID=test;Password=pass;"
Oracle: "Oracle.DataAccess.Client", "Data Source=oracle.windwardreports.com:1521;Persist Security Info=True;Password=HR;User ID=HR"
Do not use System.Data.OracleClient - even Microsoft discourages its use.
SqlServer: "System.Data.SqlClient", "Data Source=mssql.windwardreports.com;Initial Catalog=Northwind;user=demo;password=demo;"

Syntax

Visual Basic (Declaration) 
Public Function New( _
   ByVal providerName As String, _
   ByVal connectionString As String _
)
Visual Basic (Usage)Copy Code
Dim providerName As String
Dim connectionString As String
 
Dim instance As New AdoDataSourceImpl(providerName, connectionString)
C# 
public AdoDataSourceImpl( 
   string providerName,
   string connectionString
)
Managed Extensions for C++ 
public: AdoDataSourceImpl( 
   string* providerName,
   string* connectionString
)
C++/CLI 
public:
AdoDataSourceImpl( 
   String^ providerName,
   String^ connectionString
)

Parameters

providerName
The name of the provider. For example, for SqlServer this would be "System.Data.SqlClient".
connectionString
The connection string used in the DbConnection constructor.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP, Windows Vista, Windows Server 2003 family

See Also

© 2019 All Rights Reserved.