Re: VARCHAR2s that contain ASCII 0s
Date: 19 Oct 1994 22:18:48 GMT
Message-ID: <DVANDERR.94Oct19151848_at_hen3ry.oracle.com>
In article <19OCT199408363793_at_devbn1.triumf.ca> grant_at_devbn1.triumf.ca (Peter Grant) writes:
Path: dcsun4.us.oracle.com!gatekeeper.us.oracle.com!sgiblab!sgigate.sgi.com!olivea!news.hal.COM!decwrl!tribune.usask.ca!quartz.ucs.ualberta.ca!unixg.ubc.ca!devbn1.triumf.ca!grant
From: grant_at_devbn1.triumf.ca (Peter Grant)
Newsgroups: comp.databases.oracle
Date: 19 Oct 1994 08:36 PST
Organization: TRIUMF: Tri-University Meson Facility
Lines: 24
Distribution: world
NNTP-Posting-Host: devbn1.triumf.ca
News-Software: VAX/VMS VNEWS 1.41
Is there any way in SQL*Plus to manipulate VARCHAR2 columns that contain ASCII 0s? I suspect they were inserted with Pro*C or Pro*FORTRAN, but none the less, they are in the database.
I can't use REPLACE or TRANSLATE because I can't reference ASCII 0. The TO_CHAR function returns 48 for a TO_CHAR(0). When I use the SQL*Plus ASCII function to look at the characters, they show up as 0.
try chr(0) instead of to_char(0)
Peter Grant, BSc, ISP //////// /////// //////// // // // // //////// grant_at_devbn1.triumf.ca // // // // // // /// /// // // /////// // // // //////// /////// // // // // // // // // // // // // // //////// ////// // // // Canada's National Meson Facility __________________________________________ _ Vancouver, British Columbia
-- This opinion will self destruct in 5 seconds. Danny van der Rijn--dvanderr_at_oracle.com || Take my advice --- {uunet,hplabs,apple}!oracle!dvanderr || *I'm* certainly not using it. (415) 506-3142 ||Received on Wed Oct 19 1994 - 23:18:48 CET