Skip to content

Instantly share code, notes, and snippets.

@mrtarkhan
Last active March 6, 2022 07:32
Show Gist options
  • Save mrtarkhan/802d511f0481ed648e309bbe396ff488 to your computer and use it in GitHub Desktop.
Save mrtarkhan/802d511f0481ed648e309bbe396ff488 to your computer and use it in GitHub Desktop.
changes Arabic characters to Persian characters in SQL-Server
-- This is a simple code to change ی , ک charachters from arabic to persian,
-- you can develop it to iterate over your column in a specific table or all
-- columns in a specific databases using many ways like cursors
UPDATE
dbo.ExampleTable
Set
FirstName = REPLACE(REPLACE(CAST(FirstName AS nvarchar(max)), NCHAR(1610), NCHAR(1740)), NCHAR(1603), NCHAR(1705))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment