If you are working on telephone solutions, please check
out the Ozeki VoIP SIP SDK.
It can be used to create:
- Adobe Flash video phone
- Silverlight video phone
- Web to web calls
- Web to VoIP calls
Custom SIP clients:
- Silverlight SIP VoIP client
- Flash SIP VoIP client
- C# .net SIP VoIP client
- ASP .net SIP VoIP client
- Web based SIP VoIP client
Custom VoIP solutions:
- VoIP SIP softphones
- VoIP call center clients
- VoIP IVR systems
- VoIP predictive dialer systems
- VoIP auto dialer systems
- VoIP call assistant
- VoIP call recording systems
- VoIP intercom solutions
Send SMS messages using Microsoft SQL Express
On this page you can get the necessary information to
configure Microsoft SQL Express database server for SMS messaging. This page
is an extension to the How to send
SMS from an database server guide.
The solution uses the Ozeki NG - SMS Gateway software installed on your PC.
To setup your system, first you need to
configure Ozeki NG SMS Gateway for
SMS messaging. After Ozeki NG is configured for SMS messaging, you can open it's
management console and you can install
a database user
in it. This database user will make SMS sending and receiving possible from your
SQL Express database server. The database user will require you to provide the
database connection type and the database connection string. For SQL Express
you will have to use the following parameters:
Provider=SQLNCLI;Server=.\SQLEXPRESS;User ID=ozekiuser;password=ozekipass;Database=ozeki;Persist Security Info=True
you have configured the database user, you need to create the database layout
in SQL express to be able to send and receive SMS messages by using SQL
INSERT and SELECT statements. You can create the database layout by opening
a windows command prompt (Start->Run->cmd.exe), and starting the SQL Command
interpreter by typing:
C:\sqlcmd -S .\SQLExpress
Once the SQL command interpreter is running, you should enter the following
commands. If the command interpreter could not connect to SQL express, try the
instructions provided on the How to
connect to SQL Express using the SQL command line utility page.
Figure 1 - SQL Create table script
create database ozeki
CREATE TABLE ozekimessagein (
id int IDENTITY (1,1),
CREATE TABLE ozekimessageout (
id int IDENTITY (1,1),
sp_addLogin 'ozekiuser', 'ozekipass'
sp_addsrvrolemember 'ozekiuser', 'sysadmin'
If you want to work with larger messages, you can increase the size of the
msg field, or you may also change it's data type.
After the database layout has been created you are ready to send your first SMS.
To send your first SMS message you should insert a record into the ozekimessagout
database table. You can use the following SQL command to achieve this:
insert into ozekimessageout (receiver,msg,status) values ("+44111223465","Hello
Hint: You can download SQLExpress free of charge from the following URL:
On some systems, you might have difficulties connecting to SQL Express. This
is the error message you might experience:
ERROR 6001: Database connection error: The 'SQLNCLI' provider is not
registered on the local machine..
SQLNCLI is installed with SQL Server Native Client. This error indicates that
this is not installed on your machine. You can try to change the provider
to "sqloledb" to use OLE DB and see if
that works. In this case your connection string would be:
Provider=SQLOLEDB;Data Source=.\SQLEXPRESS;User ID=ozekiuser;password=ozekipass;Database=ozeki;Persist Security Info=True
Or change the whole connection string to ODBC and use the following connection
Server};Server=.\SQLEXPRESS;User ID=ozekiuser;password=ozekipass;Database=ozeki;Persist Security Info=True;
Or change the whole connection string to SQLServer and use the following
Server=.\SQLEXPRESS;User ID=ozekiuser;password=ozekipass;Database=ozeki;Persist Security Info=True;
One of these should work.
Microsoft SQL Server 2008
If you use Microsoft SQL Server 2008, apply the
following connection string:
Provider=SQLOLEDB.1;Data Source=YourHostName;Persist Security Info=False;Integrated Security=SSPI;User ID=UserName;Password=User'sPassword;Initial Catalog=DatabaseName
People who read this also read...