[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2064
  • Last Modified:

chr function

When using the chr function on values 127 and beyond, it appears to return only one value, as if the last char in the character set is 127. This is happening on a HP-UX running an Oracle 8.0. However, it gives a different result when tried with an aix system on oracle 8.0 [ I can go all the way upto 255 ]. I believe this has nothing to do with the oracle and unix system, but some setup for oracle is making this. Can you please tell me what is that setting that I am missing?

Thank you
0
mmanju
Asked:
mmanju
  • 9
  • 4
  • 3
  • +4
1 Solution
 
sudhi022299Commented:
chr function will return the character according to your database character set or according to the nls character set.

try finding out the values what values have been set to these parameters.
0
 
vishoneCommented:

 Hi mmanju,

 I think this depends on two things
 (1) The operating system - the character set
       supported by it.
 (2) The front end used to execute the query,
       for example sqlplus, or plus33w...

 - Vish
0
 
mmanjuAuthor Commented:
Thank you for your answers. Is there any way of finding the nls_character_set in oracle? I tried looking for all entries where name  like '%nls%' under v$parameter, but could not find anything that said nls_character_set. Is there any other place where I can find it?

Also, any unix command for finding the character set?

Any help would be appreciated.

Thank you
0
Free recovery tool for Microsoft Active Directory

Veeam Explorer for Microsoft Active Directory provides fast and reliable object-level recovery for Active Directory from a single-pass, agentless backup or storage snapshot — without the need to restore an entire virtual machine or use third-party tools.

 
bkowalskiCommented:
It's in v$parameter and is called nls_language.

-Brad
0
 
mmanjuAuthor Commented:
Its set to AMERICAN in both systems and nls_territory is set to AMERICA, but both behave differently.

Any ideas?
0
 
crsankarCommented:
Normally only the first 128 characters are usually used. The next 128 chratcters are called as extended characters and are only used by some east asian languages (eg. japaneese).
0
 
mmanjuAuthor Commented:
Thank you for that. But, my question is what setting is making one system of same oracle version be able to use all 255 characters and other use only first 127 of the same. Any suggestions would be greatly appreciated.

Thank you
0
 
crsankarCommented:
Is there any possibility that one of the servers has additional language support installed?
0
 
mmanjuAuthor Commented:
I apologise for being a pain. But, would you be kind enough to tell me how to look for that information? Your help is greatly appreciated.

Thank you
0
 
Andrei RodionovCommented:
Hello mmanju!

Just try to

select parameter, value
  from v$nls_parameters
  where parameter like '%CHARACTERSET%';

It returns one (for Oracle7) or two (for Oracle8) rows that inform you about character set(s) installed. Watch a difference between your databases (if it exists)...

Andrew Rodionov
0
 
mmanjuAuthor Commented:
Adjusted points to 150
0
 
mmanjuAuthor Commented:
Thanks very much. That answered my question. The character set is set to WE8DEC and that should be the reason.

Thanks to all of your for your help.

0
 
crsankarCommented:
Please accept an answer.

Thanks
0
 
Ron WarshawskyCommented:
Why accept? He can left it hang, untill it will be scheduled for deletion.
0
 
Andrei RodionovCommented:
Is it possible?..
So let have it on your conscience...

Andrew Rodionov
0
 
sudhi022299Commented:
manju, you have to accept the answer and give the expert the points failing which , you may not get answers to your future Qs.
0
 
mmanjuAuthor Commented:
EXCUSE ME GUYS. I ONCE AGAIN, JUST FOR CLARIFICATION, I DID CHOOSE THE "ACCEPT COMMENT AS ANSWER" BUTTON AND I DONT KNOW WHY ITS NOT GETTING REPORTED. DID SOMETHING CHANGE? ONCE AGAIN SORRY ABOUT THIS, AND IS THERE A SEPERATE ACCEPT ANSWER THAT I HAVE TO USE?

PLEASE LET ME KNOW.

THANK YOU
0
 
Andrei RodionovCommented:
Excuse me mmanju, but you accepted wrong answer in my opinion...

Andrew Rodionov
0
 
mmanjuAuthor Commented:
I realised that one after I committed the mistake. I need to accept the answer given by you on Feb 21st, which was the one that completed my need. Is there a way the change it please.

Once again, my apologies about all this stuff.

Thank you
0
 
Andrei RodionovCommented:
OK.

Relax and feel free to ask any other questions ;)

Andrew
0
 
mmanjuAuthor Commented:
Thanks guys, you are all just wonderful.
Still, if there is a way, please let me know. I will go ahead and change it.

Manju
0
 
sudhi022299Commented:
Manju, you can create another Q with the title as "Points for Andrew" and accept it.

I could have created anoterh Q myself but i don't have so much of points right now. I can put a Q for only 100 points.

Regards,
Sudhi.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 9
  • 4
  • 3
  • +4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now