How to insert Indian Rupee symbol in oracle 11g? -
i want insert indian rupee symbol in oracle 11g.
i have tried:
insert currency(name, symbol) values ('rupee', unistr('\20b9')); but not working.
select ascii('₹') dual; gives ascii value rupee symbol after insert shows box in row.
here can see
select chr(14844601) dual;
seems need change font in sql developer. check this sqlfiddle.
there 2 things wrong in question text: unicode symbol it's code nchr() function must used instead of chr(). second '₹' constant string treated varchar2 , specify nvarchar2 constant must prepend n literal: n'₹' .
to change font open tools -> preferences ... menu

and choose code editor -> fonts node. @ page can select font font name dropdown list. copy , past rupee symbol sample text field see if font acceptable. arial (on win7) works fine me:

this setting changes grid font font in code editor:

actions above puts half of way full rupee symbol support because select n'₹' dual return question sign. because of query text encoding conversion done between client , server side.
deal issue oracle provides ora_nchar_literal_replace environment setting. setting guides client api analyze query text character constants prefixed n , use special internal format encode such data on client side before transferring query text server. unfortunately sql developer uses thin jdbc api ignores environment setting, adding environment variable doesn't solve problem.
but there another way turn on same behavior oracle.jdbc.convertncharliterals property acts on system , connection levels.
turn property on, locate ide.conf file in sqldeveloper\ide\bin directory in sql developer installation folder , add line end of file:
addvmoption -doracle.jdbc.convertncharliterals=true save file , restart sql developer, things must work now:

p.s. instructions based on sql developer version 3.2, old versions may have location of configuration file. e.g. sqldeveloper\bin\sqldeveloper.conf .
Comments
Post a Comment