OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

[Solved] stripping -1 off the end of part number

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc
View previous topic :: View next topic  
Author Message
smiths
General User
General User


Joined: 04 Mar 2011
Posts: 11

PostPosted: Fri Mar 04, 2011 2:55 pm    Post subject: [Solved] stripping -1 off the end of part number Reply with quote

I have a column of part numbers that I need to strip the -1 off the end. I cannot do a simple find and replace because there is -1 in the body of a lot of the part numbers.

Example part number: CA759-1733-1

How can I strip the -1 off the end only?

Thanks,

Jake


Last edited by smiths on Thu Mar 10, 2011 6:33 am; edited 1 time in total
Back to top
View user's profile Send private message
Sliderule
Super User
Super User


Joined: 29 May 2004
Posts: 2499
Location: 3rd Rock From The Sun

PostPosted: Fri Mar 04, 2011 3:55 pm    Post subject: Reply with quote

You can use Find and Replace . . . BUT . . . you have to follow these steps . . . this assumes the values do NOT have any trailing space(s). Smile

  1. Select the range of cells that you want to search and replace
  2. Using a $ sign ( this is a part of the Regular expression ) means it will only find it when it ENDS with that string . . . therefore . . . in the Search for box . . . place . . .

    Code:
    -1$

  3. In the Replace with box . . . do NOT enter anything
  4. Press the More Options button
  5. Select Current selection only
  6. Select Regular expressions
  7. Press the Replace All button

I hope this helps, please be sure to let me / us know.

Sliderule

Thanks to add [Solved] in your first post Title ( edit button ) if your issue has been fixed / resolved.
Back to top
View user's profile Send private message
smiths
General User
General User


Joined: 04 Mar 2011
Posts: 11

PostPosted: Thu Mar 10, 2011 6:32 am    Post subject: Reply with quote

It worked! Thank you. I thought I was going to have to import it into mysql and do it with php.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group