datetime century date into pad dynamic cursor money percent sp job isnumeric isdate over update
SQLUSA.com
SQL 2008 GRAND SLAM ON 49 CD
FREE TRIAL  CLICK HERE TO ORDER  SEARCH
SQL Server Training SQL 2005 Scripts SQL 2008 Articles
SQL JOBS News Format Developer
How to handle Arabic language characters?

Execute the following Microsoft SQL Server T-SQL scripts in Management Studio Query Editor to illustrate the usage of Arabic language characters within an SQL Server database.

USE AdventureWorks2008;
GO
-- SQL Arabic language characters - Arabic collation
-- SQL unicode - nvarchar - 2 bytes per character
CREATE TABLE Sales.ArabicExpress (
  ID              INT    IDENTITY ( 1 , 1 ) PRIMARY KEY,
  FirstName       NVARCHAR(15),
  LastName        NVARCHAR(15),
  Address         NVARCHAR(50),
  City            NVARCHAR(20),
  State           NVARCHAR(4),
  Country         NVARCHAR(20),
  Zipcode         NVARCHAR(10),
  ModifiedDate    DATETIME default(getdate()))
GO
 
INSERT Sales.ArabicExpress(FirstName, LastName, Address, City,
State, Country, Zipcode)
SELECT N'للفلسطينيين', N'بتقديم', N'المشاركين في مؤتمر شرم',
N'حماس', N'وزير', N'الخارجية', N'13663'
GO
 
SELECT * FROM Sales.ArabicExpress
GO
/* Results to TEXT
ID          FirstName       LastName        Address                                            City                 State Country              Zipcode    ModifiedDate
----------- --------------- --------------- -------------------------------------------------- -------------------- ----- -------------------- ---------- -----------------------
1           للفلسطينيين     بتقديم          المشاركين في مؤتمر شرم                             حماس                 وزير  الخارجية             13663      2009-03-02 16:40:05.450
*/
 
-- Microsoft SQL Server unicode encoding of Arabic letters
SELECT            CONVERT(varbinary, left(FirstName,1)),
                  left(FirstName,1)
FROM Sales.ArabicExpress
GO
--0x4406   ل
 
 
-- Cleanup
DROP TABLE Sales.ArabicExpress
GO

 
------------
 
 

Order SQL 2008 GRAND SLAM Today!
SQLUSA.com Home Page
SQL Server Training at www.sqlusa.com.
Microsoft SQL Server 2012 Training Videos at www.sqlusa.com.
SQL Server 2008 Video Training at www.sqlusa.com.
SQL Server 2005 Training Videos at www.sqlusa.com.
Accounting
Administrative
Advertising
Arts
Architecture
Banking
Business Intelligence
Career Jobs
Celebrity
Computer
Consulting
Customer Service
Education
Engineering
Entertainment
Entry Level
Executive
Federal
Finance
Government
Hardware
Healthcare
Hospital
Human Resources
Information Technology
Insurance
Internet
Job Openings
Laboratory
Law Enforcement
Legal
Logistics
Manufacturing
Marketing
Medical
Military
Nursing
Pharmaceutical
Physician
Public Relations
Publishing
Real Estate
Restaurant
Retail
Sales
Social Media
Software
SQL Database
Telecomm
Therapist
Training
Transportation
Truck Driver
Travel
Web
Work from Home

FREE SS SQL / BI OLAP Short Videos on YOUTUBE.com

Microsoft Community Contributor 2011 Microsoft Community Contributor 2012

Search SQLUSA FREE SQL Server Articles & FREE T-SQL Scripts

JOIN US ON TWITTER

Copyright 2005-2012, SMI Corp. All Rights Reserved.

SQL Server 2012 is a program product of Microsoft Corporation.
SQL Server 2008 is a program product of Microsoft Corporation.
SQL Server 2005 is a program product of Microsoft Corporation.
SQL Server 2000 is a program product of Microsoft Corporation.