Re: Problem Inserting "&" sign. (ie. Sampson & Son's)

From: David Rackley <drack_at_sbctri.sbc.com>
Date: 1996/07/05
Message-ID: <9b20iqyhqp.fsf_at_diablo.tri.sbc.com>#1/1


In article <4rgr6s$9dh_at_sol.sun.csd.unb.ca> pmccarth_at_rpc.unb.ca (Patrick McCarthy) writes:

> I am trying to insert values into a record using Oracle 7.1.4 on Solaris 2.4
> Sun workstation. The problem is that I am trying to insert a text value which
> has the "&" sign in the text array. ie "Maclary & Son's". It keeps coming up
> with the message insert a value for Son's ?????? It obviously use the "&" to
> insert a variable field. How can I disable this ????

Use the "set escape" or "set define" commands to either escape the use of the '&' or re-define the '&' to a different character. In sqlplus type "help &" for a more detailed explanation.

  eg: set escape \

       select '\&test' from dual;

Hope this helps.

..dave  

-- 

  +----------------------+----------------------------------------------+
  | David Rackley        | email: drack_at_tri.sbc.com                     |
  | Southwestern Bell    |   tel: (512) 372-5516  FAX: (512) 372-5591   |
  | Technology Resources |  http://www.tri.sbc.com/                     |
  | 9505 Arboretum Blvd  +----------------------------------------------+
  | Austin, TX 78759     | It's OK to be a martyr, as long as you don't |
  |                      | bring your own firewood.  -- Dr. Jim Rigby   |
  +----------------------+----------------------------------------------+   
Received on Fri Jul 05 1996 - 00:00:00 CEST

Original text of this message