How to properly configure & character in SQL Developer 17.3

Asked

Viewed 192 times

0

Hello friends I am trying to make a sql query in SQL Developer as follows:

SELECT * FROM CLIENTE WHERE NOME_CLIENTE IN ('SALES & CIA AGUIAR', 'SAO JOAO')

The tool is understanding the character '&' as a variable input and thus does not display the record of that client, I wonder if there is any way to configure this so that when the character '&' is passed inside simple quotes the tool understands that it is a text.

1 answer

0


Run this command before:

SET DEFINE OFF

And perform normally.

Or rewrite your command like this:

SELECT * FROM CLIENTE WHERE NOME_CLIENTE IN 
  ('SALES ' || chr(38) || ' CIA AGUIAR', 'SAO JOAO')
  • I ran the first command and it worked, thank you very much!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.