How do I update the substring of a string value?

UPDATE table1
SET  SUBSTR  (TO_CHAR(field_value),3,2) = ' 50'  and SUBSTR (TO_CHAR(field_value),5,2)  =  '50'
where  ( SUBSTR(TO_CHAR(field_value), 3, 2) =  '100' ) or ( SUBSTR(TO_CHAR(field_value), 5, 2) =  '100' )tried the above in TOAD and I got "ORA-00927: missing equal sign." Please help!
data type for field_value is number. oracle version is 10g
thank you

Here's an example of how you can do it:
SQL> CREATE TABLE x
  2  AS
  3  SELECT 'SOME50HERE' AS field_x
  4  FROM dual;
Table created.
SQL> SELECT * FROM x;
FIELD_X
SOME50HERE
1 row selected.
SQL> UPDATE x
  2  SET    field_x =  SUBSTR(field_x,1,4)
  3                 || '75'
  4                 || SUBSTR(field_x,7)
  5  ;
1 row updated.
SQL> SELECT * FROM x;
FIELD_X
SOME75HEREBasically you need to break your string into three parts:
1. The part before the text you want to change.
2. The text you want to change.
3. The part after the text you want to change.
Then you concatenate them all together.
If #1 is not a known fixed number of characters, you can still use SUBSTR, by looking for the string you want to change like the following:
UPDATE x
SET    field_x =  SUBSTR(field_x,1,INSTR(field_x,'50') - 1)
               || '75'
               || SUBSTR(field_x,7)
;

Similar Messages

  • How do I update the software on my Airport Express?

    Hello everyone,
    I have an Airport Extreme base station acting as WDS and an Airport Express station. I recently upgraded the security on the Airport Extreme base station from 128-WEP to WPA (Personal), but I don't know whether I have to do something to the Airport Express base station. It's green light is on. Do I need to do something? Also, how do I update the software in the Express? Whenever I open the Airport Admin Utility, the only thing that comes up on a scan is my Extreme base station. Any advice would be most appreciated.

    yes you need to update your Airpost Express. I just went through this last week with two of my Airport Expresses. I updated my Base and my Remote's light was green but was unable to view it in Airport Admin Utility. So this is what I ended up doing and it works great.
    First bring the Airport Express you are working on in the same room as your computer......just the ease of seeing what is going on with the Airport Express. Next you need to reset it.....take a paper clip and push in the little button next to the Audio port and hold in 10 seconds. Then unplug the unit wait 10 seconds and plug it back in. wait about 3 minutes and then you will need to use Airport Set Up Assistant. You will need to make sure you have WPA Personal on your Airport Express too.
    don't forget to make sure you have the update firmware too.
    http://www.apple.com/support/airport/
    I hope this helps.....
    Powerbook G4 1.67 15", 1 gig ram, 128 vram, 80 gig harddrive   Mac OS X (10.4.6)   Powermac G3 266 mt, Dell 5150,ibook G4, 1 gig shuffle, epson printers, airport

  • How do I update the software on my iPad to iOS 6.3.1?

    How do I update the software on my iPad to iOS 6.3.1 from iOS 5.1.1?

    See the chart below to determine whether you can upgrade your device and what you can upgrade to.
    IPhone, iPod Touch, and iPad iOS Compatibility Chart
         Device                                       iOS Verson
    iPhone 1                                      iOS 3.1.3
    iPhone 3G                                   iOS 4.2.1
    iPhone 3GS                                 iOS 6.1.x
    iPhone 4                                      iOS 6.1.x
    iPhone 4S                                    iOS 6.1.x
    iPhone 5                                      iOS 6.1.x
    iPod Touch 1                               iOS 3.1.3
    iPod Touch 2                               iOS 4.2.1
    iPod Touch 3                               iOS 5.1.1
    iPod Touch 4                               iOS 6.1.x
    iPod Touch 5                               iOS 6.1.x
    iPad 1                                          iOS 5.1.1
    iPad 2                                          iOS 6.1.x
    iPad 3                                          iOS 6.1.x
    iPad 4                                          iOS 6.1.x
    iPad Mini                                     iOS 6.1.x
    =====================================
    Select the method most appropriate for your situation. If you are trying to upgrade to iOS 5 or higher, then you will have to connect your device to your computer and open iTunes in order to upgrade.
    Upgrading iOS
       1. How to update your iPhone, iPad, or iPod Touch
       2. iPhone Support
       3. iPod Touch Support
       4. iPad Support
         a. Updating Your iOS to Version 6.0.x from iOS 5
              Tap Settings > General > Software Update
         If an update is available there will be an active Update button. If you are current,
         then you will see a gray screen with a message saying your are up to date.
         b. If you are still using iOS 4 — Updating your device to iOS 5 or later.
         c. Resolving update problems
            1. iOS - Unable to update or restore
            2. iOS- Resolving update and restore alert messages

  • How do i update the software on my ipod touch? i went to settings, then general, but theres no option called software updates.

    How do i update the software on my ipod touch? i went to settings, then general, but theres no option called software updates.

    You needing to be running iOS 5 or later in order to do a Software Update from the device.  To run iOS 5 you need a 3G or 4G iPod Touch.  So if you really have a 4G iPod Touch, connect it to iTunes and you should be prompted about an update to its version of iOS.
    See here for more information: iOS: How to update your iPhone, iPad, or iPod touch
    B-rock

  • How do I update the software on my ipod touch

    How do I update the software on my ipod touch

    To update
    Connect the iPod to your computer and update via iTunes
    iTunes 10 for Windows: Update and restore software on iPod, iPhone, or iPad
    A 1G iPod can go to iOS 2.2 via iTunes and iOS 3.1.3 via
    Purchasing iOS 3.1 Software Update for iPod touch (1st generation)
    A 2G to 4.2.1. Requires iTunes version 10.X. That requires a Mac with OSX 10.5.8 or later. With 1OSX 10.4.11 you can only go to iTunes 9.X which gets you as high as iOS 4.1
    A 3G to 5.1.1  Requires iTunes version 10.5 or later
    A 4G to 6  Requires iTunes version 10.7 or later. That requires a Mac with OSX 10.6.8 or later
    Identifying iPod models

  • How do i update the software on an iphone 3g as it doesnt have the software update option on it, how do i update the software on an iphone 3g as it doesnt have the software update option on it

    how do i update the software on an iphone 3g as it doesnt have the software update option on it, how do i update the software on an iphone 3g as it doesnt have the software update option on it

    Hey wemmer
    Check out the following article on how to update you iPhone. The section you are looking for is Update your device using iTunes.
    iOS: How to update your iPhone, iPad, or iPod touch
    http://support.apple.com/kb/ht4623
    Thanks for using Apple Support Communities.
    Regards,
    -Norm G.

  • How do I update the iCloud ID on my phone?  I changed my ID on my laptop, but my iphone still has "sign in to iCloud" with the wrong ID and I cant figure out how to change it.

    How do I update the iCloud ID on my phone?  I changed my ID on my laptop, but my iphone still has "sign in to iCloud" with the wrong ID and I cant figure out how to change it.

    I have same question

  • Family sharing. i have set my wife up on family sharing and each time we try to download a book or an app, we are requested that i update the payment details. I have done this and we still cannot share.. what do i do or how do i update the payment

    family sharing. i have set my wife up on family sharing and each time we try to download a book or an app, we are requested that i update the payment details. I have done this and we still cannot share.. what do i do or how do i update the payment details to enable my wife to download

    Drrhythm2 wrote:
    What's the best solution for this? I
    Copy the entire /Music/iTunes/ folder from her old compouter to /Music/ in her account on this new computer.

  • My old Apple ID is on my iPhone, but this has been transferred to a new Apple ID.  The iCloud on my phone is requesting the password for the old Apple ID, but this no longer exists.  How do I update the iCloud Apple ID on my iPhone?

    My old Apple ID is on my iPhone, but this has been transferred to a new Apple ID.  The iCloud on my phone is requesting the password for the old Apple ID, but this no longer exists.  How do I update the iCloud Apple ID on my iPhone?  When I try to get the old passwork through forgot my password, the reply is that there is no account that exists. 

    Try the following....
    Go to Settings>icloud, scroll to bottom of screen and tap Delete Account.  Then log in using a different ID.

  • How can I update the thumbnails in the slide panel when a slide has been changed?

    When the text in a slide has been changed, how can you update the thumbnail in the slide panel to reflect this change?
    We translated slides, but the slides in the slide panel are still in English.
    Thanks for your help.

    the slides should update automatically as you type
    are you using a  theme you created yourself, or one you have added for this show?
    when you play the show, does the slides show correctly?  If they are OK you could still show the presentation.
    also what Mac are you using and what graphic crd is installed?

  • How can we update the last synchronization date and time..on SUP in sccm 2012 R2

    Hi,
        Can you any one please guide me how can i update the last  synchronization date & time in SUP on SCCM2012 r2 , some how its updated as future date and when ever i try to synch the SUP with disconnected WSUS its shows in the wsyncmgr.log 
    "Wakeup for a polling cycle " and  " Wakeupby inbox drop" and "Wakeup by SCF change"  
    Thanks 
    Balaji K

    You'll probably have to call CSS on this one as this not normal by any means. The messages you noted above are completely normal but if that's all you are seeing then there's an issue.
    Have you reviewed wcm.log and wsusctrl.log?
    Jason | http://blog.configmgrftw.com | @jasonsandys

  • HT1918 I cancelled a payment through PayPal. How do I update the payment for that charge?  I looked at my payment information and it has my credit card information.  I'm not sure where to update the PayPal part of payment.

    I cancelled a payment through PayPal. How do I update the payment for that charge?  I looked at my payment information and it has my credit card information.  I'm not sure where to update the payment that was associated with my PayPal account?  I am not sure what that paid for?  I am trying to process updates on my IPhone & IPad for apps. I have already downloaded. 

    Hi Xellana, and a warm welcome to the forums!
    I'm looking for information and pricing on possibly upgrading the processor from the PowerPC to Intel.
    While anything is possible if you had enough money... NOPE, you can't change the CPUs to Intel, nor can you get any faster PPC upgrades for it. It'd be far cheaper to buy a new IntelMac than to replace everything inside the G5, and I mean just about everything, then figure out how to machine the case & such to mount Intel Logic Board, Graphic Card & such.
    Sorry.

  • How can I update the firmware all at once

    I'm a tech support in a school, approximately our school has over 500 laptops, how can I update the firmware on all laptops at once?

    Apple Configurator is the software you want - and it's free from Apple. However, I'm dubious that firmware can be updated all at once.
    http://help.apple.com/configurator/mac/1.4.1/

  • TS1538 how do i update the ipod touch

    how do i update the ipod touch

    To update
    Connect the iPod to your computer and update via iTunes
    iTunes 10 for Windows: Update and restore software on iPod, iPhone, or iPad
    A 1G iPod can go to iOS 2.2 via iTunes and iOS 3.1.3 via
    Purchasing iOS 3.1 Software Update for iPod touch (1st generation)
    A 2G to 4.2.1. Requires iTunes version 10.X. If a Mac it requires OSX 10.5.8 or later. With 1OSX 10.4.11 you can only go to iTunes 9.X which gets you as high as iOS 4.1
    A 3G to 5.1.1  Requires iTunes version 10.5 or later
    A 4G to 6  Requires iTunes version 10.7 or later. For a Mac, that requires a Mac with OSX 10.6.8 or later
    Identifying iPod models

  • How do you update the iPod touch 8GB

    How do I update the iPod touch 8GB?

    What's your current operating system?
    Also read here:
    Updating iOS
    (Note that I am a representative of the organization for the above link, which is not endorsed by Apple)

Maybe you are looking for