This section provides you with the connection strings you can use to
connect your database user in Ozeki NG - SMS Gateway to the database server.
When configuring
the database user, you have to enter the appropriate connection string in the
Connection string template of the Database connection tab in the
configuration form
(Figure 1).
In some situations, you need to modify the SQL templates in order to have
database connectivity. This can be done in the SQL for sending tab of
the configuration form.
Figure 1 -
Figure 1 - The Connection string template in the configuration form
The connection strings are organized into groups according to
the following
table of contents:
Generally, one of the first steps when you work
with databases is to open it. There are several types of database,
and each has a different mode of connection. To connect
to your database, you need to know the appropriate connection string.
This appendix contains the connection strings to most of the known databases.
You can find the connection string in the grey box below the name of each
database.
Driver={Microsoft Text Driver (*.txt; *.csv)};
Dbq=C:\DatabasePath\;Extensions=asc,csv,tab,txt;
If you use tab-delimited files, you have to create
the
schema.ini file,
and you need to inform the Format=TabDelimited option
in your connection string.
Note: You need to specify the file name in the SQL template statement.
For example:
If you use a Workgroup (System database): you need to inform the SystemDB Path,
the User Name and its password. For that, you have two solutions:
inform the user and password in the connection string
or at the moment of the open operation.
For example:
Also, you can use the Trusted_Connection parameter, which
indicates that you are using the Microsoft Windows NT Authentication Mode to authorize
user access to the SQL Server database.
For example:
If you want to connect to a remote SQL Server, you need to inform the
address,
the port, and the Network Library to use:
The Address parameter has to be an IP address, and it
has to include the port.
The Network parameter can be one of the following:
If you want to connect with a remote database, you need to specify
the name of the server or its IP in the Server parameter.
If the Port is different from 3306 (default port), you have to specify it.
The parameter Option can be one or more of the following values:
1 - The client can't handle the fact that MyODBC returns the real width of a column.
2 - The client can't handle the fact that MySQL returns the true value of affected rows.
If this flag is set, then MySQL returns 'found rows' instead. You need MySQL 3.21.14 or more recent
to get this to work.
4 - Make a debug log in c:\myodbc.log.
This is the same as putting MYSQL_DEBUG=d:t:O,c::\myodbc.log in AUTOEXEC.BAT.
8 - Don't set any packet limit for results and parameters.
16 - Don't prompt for questions even if the driver would like to prompt.
32 - Enable or disable the dynamic cursor support. This is not allowed in MyODBC 2.50.
64 - Ignore the use of database name in 'database.table.column'.
128 - Force the use of ODBC manager cursors (experimental).
256 - Disable the use of extended fetch (experimental).
512 - Pad CHAR fields to full column length.
1024 - SQLDescribeCol() will return fully qualified column names.
2048 - Use the compressed server/client protocol.
4096 - Tell the server to ignore space after function name and before '(' (needed by PowerBuilder).
This will make all function names keywords!
8192 - Connect with named pipes to a MySQLd server running on NT.
16384 - Change LONGLONG columns to INT columns (some applications can't handle LONGLONG).
32768 - Return 'user' as Table_qualifier and Table_owner from SQLTables (experimental).
65536 - Read parameters from the client and ODBC groups from my.cnf.
131072 - Add some extra safety checks (should not be needed but...).
If you want to have multiple options, you should add the above flags!
For example: 16 + 1024 = 1030 and use Option= 1030;.
If you want to connect to a "Named Instance" (SQL Server 2000), you need
to specify Data Source=Servere Name\Instance Name as
in the following example:
If you want to connect with a SQL Server running on the same computer,
you have to specify the keyword (local) in the Data Source
as in the following example:
Provider=DB2OLEDB;Network Transport Library=TCPIP; Network Address=130.120.110.001;Initial Catalog=MyCatalog;
Package Collection=MyPackageCollection;Default Schema=MySchema;
User ID=MyUsername;Password=MyPassword;
If you use APPC connection:
Provider=DB2OLEDB;APPC Local LU Alias=MyLocalLUAlias; APPC Remote LU Alias=MyRemoteLUAlias;Initial Catalog=MyCatalog;
Package Collection=MyPackageCollection;Default Schema=MySchema;
User ID=MyUsername;Password=MyPassword;
Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\DatabasePath\MmDatabase.mdb;User Id=admin;Password=;
If you use a Workgroup (System database):
Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\DataBasePath\mydb.mdb;Jet OLEDB:System Database=MySystem.mdw;
Connecting to an Excel Spreadsheet using the JET OLE DB Provider:
Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\DatabasePath\DBSpreadSheet.xls; Extended Properties=\Excel 8.0;HDR=Yes;
\;
Note: If HDR=Yes,
the provider will not include the first row of the selection into the recordset.
If "HDR=No", the provider will include the first row of the
cell range (or named ranged) in the recordset.
Connecting to a Text file using the JET OLE DB Provider:
Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=C:\DatabasePath\;Extended Properties=\text; HDR=Yes;FMT=Delimited;\;
Note: You need to specify the file name in the SQL template statement.
For example:
Select Name, Address From Clients.txt
Connecting to an Outlook 2000 personal mail box using the JET OLE DB Provider:
(By J. Cardinal)
Provider=Microsoft.Jet.OLEDB.4.0; Outlook 9.0;MAPILEVEL=;DATABASE=C:\Temp\;
Replace c:\temp with any temporary folder.
It will create a schema file in that folder when you open it,
showing all the fields available. Blank MAPILEVEL indicates top level of folders).
Connecting to an Exchange mail box through JET: (By J. Cardinal)
Provider=Microsoft.Jet.OLEDB.4.0;Exchange 4.0; MAPILEVEL=Mailbox - Pat Smith|;DATABASE=C:\Temp\;
You have to replace c:\temp with any temporary folder.
Replace Pat Smith with the name of the mailbox, and you have to
keep the vertical pipe character | to indicate the top level of folders.
Place the sub-folder after the vertical pipe when accessing the specific folder.
Note: you can enter queries against the mail store just like a database.
For example:
Microsoft� OLE DB for Online Analytical Processing (OLAP) is
a set of objects and interfaces that extends the ability of OLE DB
to provide access to multidimensional data stores.
This feature enables a client application to connect to an Analysis
server through Microsoft� Internet Information Services (IIS) by specifying a URL
in the Data Source property in the client application's connection
string. This connection method allows PivotTable� Service to tunnel through
firewalls or proxy servers to the Analysis server. A special Active Server
Pages (ASP) page, Msolap.asp, enables the connection through IIS.
The directory in which this file resides has to be included as part of the
URL when connecting to the server (for example, http://www.myserver.com/myolap/).
Note: "Data Source=" must be set to
the appropriate Net8 name which is known to the naming method in use.
For example, for Local Naming, it is the alias in the tnsnames.ora file;
for Oracle Names, it is the Net8 Service Name.
If you want to create a Data Link File, you can make a new empty text file.
Change its extension by .udl, then double-click the file,
and the operating system calls the Data Link app. for you