If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back  dBforums > Database Server Software > Oracle > String Comparison in PL/SQL

LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Registered User
Join Date: Mar 2010
Posts: 4
String Comparison in PL/SQL


I want to compare two strings

str1 VARCHAR2(10);
str2 VARCHAR2(10);

if they are equal perform some operation?

Could any one tell me how to do it using Oracle pl/SQL??

Thanks in advance
Reply With Quote
  #2 (permalink)  
Registered User
Join Date: Aug 2009
Location: Olympia, WA
Posts: 337
Really? This is a RTFM question. Are you sure you weren't looking for the mysql forum?
IF str1 = str2 THEN
  dbms_output.put_line('Read the fine manual');
  dbms_output.put_line('Or dont');
Reply With Quote
  #3 (permalink)  
Lost Boy
Join Date: Jan 2004
Location: Croatia, Europe
Posts: 4,001
Eh, "dont". Why didn't you provide an example of correct use of a single quote? Did you think that it would be too much for the first lesson?
Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On