International/Unicode characters with MSSQL
This page explains in details how you can send international
characters with Ozeki NG SMS Gateway in MSSQL. You will find how to configure an
existing database to be able to send international characters and how to create
a new database that supports Unicode characters.
Create new MSSQL database table
If you use MSSQL and you create a new database table, you need to use
nvarchar instead of varchar in the fields where you want to use
Unicode characters.
How to configure an existing MSSQL database to send international characters
If you already have created MSSQL database tables and you want
this database table
to support sending UNICODE characters via SMS, follow this configuration guide.
You need to configure your MSSQL database to accept international characters
such as Arabic, Chinese, etc.
Configuration guide
Start MSSQL Server Management Studio. Click on the
database to
be configured and select Properties (Figure 1).

Figure 1 - Properties
Then click on Options in the menu. In Collation
section you can select the types of characters you want the database to accept.
In this example I selected Arabic CI AI (Figure 2).

Figure 2 - Specify characters
Now in Tables section right click on ozekimessagein
table and select Modify (Figure 3).

Figure 3 - Modify tables
Set msg field to nvarchar (Figure 4).

Figure 4 - Select nvarchar
Increase the size of messages from (50) to (160) and
Save settings (Figure 5).

Figure 5 - Increase size and save settings
Now do the same process with ozekimessageout table. So
you need to right click on ozekimessageout table, select Modify, set
msg field to nvarchar, increase size
to (160) and save the changes.
Test
I created a test message containing Unicode characters (Arabic
has been selected) and inserted it into ozekimessageout table (Figure 6).

Figure 6 - Insert test message into ozekimessageout
On Figure 7 you can see that Ozeki NG SMS Gateway sent out the
test message (Figure 7)

Figure 7 - Sent message in Ozeki NG SMS Gateway
Dig deeper!
People who read this also read...
Send SMS from MSSQL database
Next page:
MySQL
|