[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
RE: [sqr-users] how to remove a single quote from a name
- Subject: RE: [sqr-users] how to remove a single quote from a name
- From: "Peter Burton" <Peter_Burton@hyperion.com>
- Date: Fri, 27 Oct 2006 16:51:31 -0400
- Delivery-date: Fri, 27 Oct 2006 18:50:46 -0400
- In-reply-to: <s53df32e.092@mailhost.vac-acc.gc.ca>
- List-id: "This list is for discussion about the SQR database reportinglanguage from Hyperion Solutions." <sqr-users.sqrug.org>
- Thread-index: Acb6CZId8vsfTtu6T06Kd7FBLiIRtgAABPLw
- Thread-topic: [sqr-users] how to remove a single quote from a name
All,
Begin-Report
Let $Name = Replace('O''Hara', '''', '')
Show $Name
End-Report
Peter
-----Original Message-----
From: sqr-users-bounces+peter_burton=hyperion.com@sqrug.org
[mailto:sqr-users-bounces+peter_burton=hyperion.com@sqrug.org] On Behalf Of
PeterG Clark
Sent: Tuesday, October 24, 2006 10:03 AM
To: sqr-users@sqrug.org
Subject: Re: [sqr-users] how to remove a single quote from a name
I think you can use the translate for that as well:
let $q = chr(39)
let $null = ''
let $lname = translate($lname,$q,$null)
I haven't tested it, but give it a shot :-)
>>> Patricia.Overcashier@aam.com 2006/10/17 13:30:28 >>>
Hi everyone,
I select a last name and before comparing it I remove all special characters.
Thanks to all of your help, I can do that successfully.
The only character that I seem to struggle with removing is the single quote
I have the name O'Hara
I want it to be OHara
I am using translate to remove all of the other oddities.
let $lname = translate(lower($lname),'абвзийксуцн','aaaceeenooi')
I have tried this:
find ''' in $lname 0 #pos My errors happen here. I can't find the
single quote to get rid of it.
if #pos > 0
let #pso2 = #pos + 1
let $newlname = substr(lname,0,#pos)||substr($lname,#pos2)
end-if
Thanks again,
Patti Overcashier
Information Technology - PeopleSoft
American Axle & Manufacturing, Inc.
Detroit Gear Plant 3
1840 Holbrook
Detroit, MI 48212
_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users
_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users
If you have received this e-mail in error, please delete it and notify the
sender as soon as possible. The contents of this e-mail may be confidential and
the unauthorized use, copying, or dissemination of it and any attachments to
it, is prohibited. Internet communications are not secure and Hyperion does
not, therefore, accept legal responsibility for the contents of this message
nor for any damage caused by viruses. The views expressed here do not
necessarily represent those of Hyperion. For more information about Hyperion,
please visit our Web site at: www.hyperion.com
_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users