ExecuteUpdate() returns 1 , but actually it has'nt updated the DB tables

DATABASE USED : ORACLE 9i
This is the function that is been called.
althou, this returns a +ve ans. , saying that the db has been updated ; but when i login into the DB, i donot find the row updated.
public void process(File dir) throws Exception
     FileInputStream fileIn = null;
     byte b[] = null;
     PreparedStatement stmt = null;
     PreparedStatement stmtBank = null;
     PreparedStatement stmtBrand = null;
     ResultSet rs = null;
     String updateBankInfoTable = "UPDATE ARBANKINFO SET ISSUERLOGO_LARGE = ? WHERE BANKID=?";
     String updateBrandInfoTable = "UPDATE ARBRANDINFO SET ISSUERLOGO_LARGE = ? WHERE BANKID=? and RANGEID = ?";
     int bankId = 0;
     int rangeId = 0;
     // FileNotFoundException or SecurityException might
     // be thrown while reading the files in this dir.
     try{
     fileIn = new FileInputStream(dir);
     }catch(Exception e)
          e.printStackTrace(p);
     String fileNameStr = dir.getName();
     if (fileNameStr!=null || fileNameStr.length()>0)
          // Read the file in a byte array
          long fileLen = dir.length();
          int readBytes = 0;
     int totalRead = 0;
     b = new byte[(int)fileLen];
     while((long)totalRead < fileLen)
     try {
                    readBytes = fileIn.read(b, 0, (int)fileLen);
               } catch (IOException e1) {
                    e1.printStackTrace(p);
     totalRead += readBytes;
     if (fileIn != null)
     fileIn.close();
     try{
     if (bankIDString!=null)
          stmt = conn.prepareStatement("select BANKID,RANGEID from ARESENROLLPROCESS where MAINLOGOURL = ?" +
               "and BANKID IN ("+bankIDString+")");
     else
          stmt = conn.prepareStatement("select BANKID,RANGEID from ARESENROLLPROCESS where MAINLOGOURL = ?");
     stmt.setString(1,fileNameStr);
     rs = stmt.executeQuery();
     int i =1;
     while (rs.next())
          bankId = rs.getInt("BANKID");
               rangeId = rs.getInt("RANGEID");
               i++;
               if (rangeId!=0)
                    stmtBrand = conn.prepareStatement(updateBrandInfoTable);
                    stmtBrand.setBytes(1,b);
                    stmtBrand.setInt(2,bankId);
                    stmtBrand.setInt(3,rangeId);
                    if (stmtBrand.executeUpdate()==1)
                                             p.println("Updated ARBRANDINFO table ");
                    else
                         // log in something
                                             p.println("*** Column not found in ARBRANDINFO table");
               else if (rangeId == 0)
                    stmtBank = conn.prepareStatement(updateBankInfoTable);
                    stmtBank.setBytes(1,b);
                    stmtBank.setInt(2,bankId);
                    if (stmtBank.executeUpdate()==1)
                                             p.println("Updated ARBANKINFO table");
                    else
                                             p.println("*** Column not found in ARBANKINFO table : " +
                                   "BANKID--> "+bankId);
               if (stmtBank != null)
               stmtBank.close();
          if (stmtBrand != null)
               stmtBrand.close();
     }catch(Exception e)
          e.printStackTrace(p);
     if (stmt != null)
          stmt.close();
     if (stmtBank != null)
          stmtBank.close();
     if (stmtBrand != null)
          stmtBrand.close();
Any suggestions ?????

i don't see how not setting the autoCommit parameter
has anything to do with this.If autocommit is false then an update will not be committed without an explicit commit()!
>
I would like to add one more thing in here, which m
sorry i shud hav added; this particluar fn. does
update a lot of row; but for some records, althou it
does say that it has updated(java API ); but in
reality it does not do it.
That makes a lot fo difference! It does mean that it is probably not a commit problem but without this extra information my money was on a commit problem. Are you swallowing an exception without reporting it?

Similar Messages

  • EDIT field in ALV GRID and on SAVE it has to update the DB Table

    Hi Experts,
    I have searched lot of forums...
    But i had not got the exact solution for this...
    I have multiple records that displayed in the ALV output screen and i had modified more than one record and then click on save.
    It has to modify all the lines that i had changed in the EDITABLE FIELD.
    Can any one help me in doing so...
    Sample code will be more help full....
    Thanks in advance,
    Kruthik

    Hi Kruthik
    Check [=> OO ALV Event DATA_CHANGED <= |http://abaptips.com/?p=70], hope you will get idea.
    Please reply in case of any confusion.
    Thanks and Best Regards,
    Faisal

  • Va02 screen input first save it has to update the data base table

    I am working on VA02.
    For only one user(delivery block)should be block and when we are changing in sales order document for that user it has to update the VBAK table.
    for second save i'm able to updating but i want to update at first save only.
    thanks,
    sree.

    I want to update the DB table VBAK. and the user exit is:
    here is my coding: my requirement is to block a field i.e LIFSK in va02 and after saving that and i have checked vbak table then in lifsk the blocked db is updated IN TABLE CONTENTS.LATER IF I SAVE IT ANOTHER TIME WITHOUT ANY MODIFICATIONS THE FIELD IS NOT UPDATED.
    now the problem is with updation .i have blocked the field.
    Please help me  its urgent
    FORM USEREXIT_MOVE_FIELD_TO_VBAK.
    tables: knkk.
    if not vbak-kunnr is initial.
      if vbak-auart NE 'ZFD' and
         vbak-auart NE 'ZCR2' and
         vbak-auart NE 'ZRE' and
         vbak-auart NE 'ZSD'.
        select single * from KNKK
          where  KUNNR = vbak-kunnr
          and    KKBER = '8000'.
          if sy-subrc = 0.
            clear vbak-LIFSK.
          ENDIF.
          IF NOT SY-UNAME = 'FINCOMM1' AND SY-TCODE = 'VA02'.
              SELECT SINGLE LIFSK FROM VBAK INTO LIFSK1 WHERE VBELN = VBAK-VBELN.
               IF LIFSK1 NE ' '.
                  vbak-LIFSK = ' '.
               ELSEif vbak-auart eq 'ZCR2'.
                      vbak-LIFSK = 'Z1'.
                  ELSE.
                      vbak-LIFSK = 'Z6'.
               endif.
             if sy-tcode eq 'VA02' . "added on 22/05/2008
            if screen-name = 'VBAK-LIFSK'.
                  screen-input = 1.
                  modify screen.
                  update vbak.
            endif.
      ENDIF.
          ENDIF.
      endif.
    endif.
      if sy-tcode eq 'VA02' AND sy-uname NE 'FINCOMM1'. "added on 22/05/2008
            if screen-name = 'VBAK-LIFSK'.
              screen-input = 1.
                  modify screen.
                  update vbak.
            endif.
    endif.
    endform.
    Thanks,
    sri.

  • I am trying to instal the latest version of iTunes onto my MacBook Pro, but my computer has been "configuring" the installation since 5pm yesterday and now it is 10:30am. It has never done this before. Can anybody help me out?

    I am trying to instal the latest version of iTunes onto my MacBook Pro, but my computer has been "configuring" the installation since 5pm yesterday and now it is 10:30am. It has never done this before. Can anybody help me out?

    Many thanks b Noir
    This is a copy of ONEof the keys  in the registry I changed  as told by Apple support today. I also have changed others as instructed by GEAR  software support to manually delete GEAR drivers (that I had installed but couldn't delete some of the others  they mentioned from Windows system 32. Then some bright spark at work told me I need the Gear drivers so  I downloaded the software and installed again.
    Sorry, just this minute went to insert image  and it is giving me a message saying this sort of content  is not allowed?.
    The most recent key I altered is in: HKey _local _machine. System\class - 4D36E965-E325-11CEBFC1-08002BE10318. Upper Filter data: Upper filter NTIDrvr  SiRem GEARAspiWDN.
    The GEARsoftware info about manually deleting  GEAR drive is from:
    http://www.gearsoftware.com/wiki/index.php?title=DRIVERS:_Windows_-_Updating%2C_ removing%2C_64_bit_versions%2C_etc
    I hope you can help

  • I backed up my iphone 4 and did an upgrade and changed my Apple ID and password but my phone has not recognised the new ID to upgrade my apps via the iphone.

    I backed up my iphone 4 and did an upgrade and changed my Apple ID and password but my phone has not recognised the new ID to upgrade my apps via the iphone.  How do I get rid of the old Apple ID when it comes to upgrading apps.
    I have been into setting>store and signed out and signed back in and it still asks for old ID and password.

    Everything you've had up to now has been tied to your old Apple ID. You cannot switch it over to a new Apple ID. You should contact iTunes support to help you with this:
    Apple Store Customer Service at 1-800-676-2775 or visit online Help for more information.
    To contact product and tech support visit online support site.
    For Mac App Store: Mac App Store Customer Service.
    For iTunes: Apple Support for iTunes - Contact Us

  • I hope this might interest someone. The situation; 3 floors,I am having trouble with an an Airport Extreme, 802.11n on the top floor and a Mac Pro 3.1 on the bottom floor. Not always but often it has trouble seeing the Airport and making a connection. I h

    I'm not sure how to post a message. I hope this might interest someone. The situation; 3 floors,I am having trouble with an an Airport Extreme, 802.11n on the top floor and a Mac Pro 3.1 on the bottom floor. Not always but often it has trouble seeing the Airport and making a connection. I have an older Airport Express, would it help to install it? would it work best if it was installed in the same room? should it be installed half way in between? Get another Extreme? The Mac Book Pro on the middle floor can see 11 networks in the neighbourhood if that might be causing a problem or would if I installed the Express. Thank for your consideration.   

    Thanks for your time ... I appologize for the font and colour, I compossed the question in pages and failed to notice the font colour as grey ... there are a variety of computers of various ages so I think it is using a setting that allows both 5G and 2.4 ... the connection to the Airport is thru a cable modem and cable does run throuhout the house ... maybe those hard wires would be a place to look at ... do you think that putting the 'Express' on the second floor might help ... thanks again ...

  • HT4943 I paid to subscribe to Ski Mag and Ski Racing but neither subscription has ever updated beyond the first issue.  Subscription is active but there never is a new mag...

    I paid to subscribe to Ski Mag and Ski Racing but neither subscription has ever updated beyond the first issue.  Subscription is active but there never is a new mag...
    They got the money but there is no monthly subscription and it says the subscription will expire in Feb!

    Hello ISXDesign,
    Thanks for the question, and welcome to Apple Support Communities. I understand that you are having issues redeeming a subscription that you have paid for. The best option will be to report an issue with your purchase:
    How to report an issue with your iTunes Store, App Store, Mac App Store, or iBookstore purchase
    http://support.apple.com/kb/HT1933
    Thanks,
    Matt M.

  • If i want to gift a friend an album but he already has some of the songs, will itunes charge me for the complete album, or the 'complete my album' price?

    I'd like to gift a friend an album, but he already has most of the tracks. So I was wondering if itunes would charge me for the complete price of the album or the 'complete my album' price.

    You will be charged for the entire album. The Gifting feature is not recipient-specific, so it would have no way to know that a particular recipient you might be sending to would already have the album. Why not just gift the songs you know your friend doesn't have?
    Cheers,
    GB

  • My apple tv has always had issues on connecting to wifi. but now that iv'e updated the system, it wont connect to wifi at all. Id like to know what to do, and if its eligible to get a new one. the serial number is: DY5HNVP5DRHN

    My apple tv has always had issues on connecting to wifi. but now that iv'e updated the system, it wont connect to wifi at all.
    My connection is fine because Im using it on my macbook pro perfectly, so the problem is definetly on apple tv.
    Id like to know what to do, and if its eligible to get a new one. the serial number is: DY5HNVP5DRHN

    From what I understand from this post, yes you do qualify for a replacement.
    http://www.macrumors.com/2013/04/15/apple-initiates-replacement-program-for-3rd- generation-apple-tvs-with-wifi-connectivity-issues/

  • I'm on 2014 but a colleague has now updated to 9.3 how can the update to 2014? thanks

    I'm on CC Indesign2014 but a colleague has now updated to 9.3 how can the update to 2014? thanks

    I am pretty sure that you can't install CC 2014 on 10.6.8.
    She could open the CC app with Spotlight (Command + Space, then type in "Cloud") but since she's on Snow Leopard (10.6.8) she won't see CC 2014 in her list of installable versions.

  • I have just tried to update my iPhone 5s to iOS 8.1.2 but my phone has frozen on the update screen what can I do to solve this problem please

    I Have just tried to update my iPhone 5s to iOS 8.1.2 but my phone has frozen on the update screen what can I do to solve this problem

    Hi Michaelcampbell1980,
    I understand that you have run into an issue while updating your iPhone. Here is an article that will help you address this issue:
    If you can't update or restore your iPhone, iPad, or iPod touch - Apple Support
    http://support.apple.com/en-us/HT201263
    Thanks for coming to the Apple Support Communities!
    Regards,
    Braden

  • HT203421 i buy a macbook air with my friend and i changed the apple id also.at first i can update the application but now its impossible to update the application.when i clock to update it shows the id of my fren andsomebody do you have idea to solve this

    i buy a macbook air with my friend and i changed the apple id also.at first i can update the application but now its impossible to update the application.when i clock to update it shows the id of my fren andsomebody do you have idea to solve this problem.

    The first thing to do with a second-hand computer is to erase the internal drive and install a clean copy of OS X. You — not the previous owner — must do that. How you do it depends on the model, and on whether you already own another Mac. If you're not sure of the model, enter the serial number on this page. Then find the model on this page to see what OS version was originally installed.
    1. You don't own another Mac.
    If the machine shipped with OS X 10.4 or 10.5, you need a boxed and shrink-wrapped retail Snow Leopard (OS X 10.6) installation disc from the Apple Store or a reputable reseller — not from eBay or anything of the kind. If the machine has less than 1 GB of memory, you'll need to add more in order to install 10.6. Preferably, install as much memory as it can take, according to the technical specifications.
    If the machine shipped with OS X 10.6, you need the installation media that came with it: gray installation discs, or a USB flash drive for some MacBook Air models. For early MBA models, you may need a USB optical drive or Remote Disc. You should have received the media from the previous owner, but if you didn't, order replacements from Apple. A retail disc, or the gray discs from another model, will not work.
    To boot from an optical disc or a flash drive, insert it, then reboot and hold down the C key at the startup chime. Release the key when you see the gray Apple logo on the screen.
    If the machine shipped with OS X 10.7 or later, you don't need media. It should boot into Internet Recovery mode when you hold down the key combination option-command-R at the startup chime. Release the keys when you see a spinning globe.
    2. You do own another Mac.
    If you already own another Mac that was upgraded in the App Store to the version of OS X that you want to install, and if the new Mac is compatible with it, then you can install it. Use Recovery Disk Assistant to create a bootable USB device and boot the new Mac from it by holding down the C key at the startup chime. Alternatively, if you have a Time Machine backup of OS X 10.7.3 or later on an external hard drive (not a Time Capsule or other network device), you can boot from that by holding down the option key and selecting it from the row of icons that appears. Note that if your other Mac was never upgraded in the App Store, you can't use this method.
    Once booted in Recovery, launch Disk Utility and select the icon of the internal drive — not any of the volume icons nested beneath it. In the Partition tab, select the default options: a GUID partition table with one data volume in Mac OS Extended (Journaled) format. This operation will permanently remove all existing data on the drive.
    After partitioning, quit Disk Utility and run the OS X Installer. You will need the Apple ID and password that you used to upgrade. When the installation is done, the system will automatically reboot into the Setup Assistant, which will prompt you to transfer the data from another Mac, its backups, or from a Windows computer. If you have any data to transfer, this is usually the best time to do it.
    Then run Software Update and install all available system updates from Apple. To upgrade to a major version of OS X newer than 10.6, get it from the Mac App Store. Note that you can't keep an upgraded version that was installed by the previous owner. He or she can't legally transfer it to you, and without the Apple ID you won't be able to update it in Software Update or reinstall, if that becomes necessary. The same goes for any App Store products that the previous owner installed — you have to repurchase them.
    If the previous owner "accepted" the bundled iLife applications (iPhoto, iMovie, and Garage Band) in the App Store so that he or she could update them, then they're linked to that Apple ID and you won't be able to download them without buying them. Reportedly, Apple customer service has sometimes issued redemption codes for these apps to second owners who asked.
    If the previous owner didn't deauthorize the computer in the iTunes Store under his Apple ID, you wont be able to  authorize it immediately under your ID. In that case, you'll either have to wait up to 90 days or contact iTunes Support.

  • Can I see how long the longest entry has been in the sticky table ?

    Hi,
    I have a customer who has a possible issue with the sticky inactivity timeout on the CSS. At the moment we are using no timeout, just relying on the CSS to purge the entries.
    However, is it possible to see how long the longest entry has been in the sticky table. I can see the 'elapsed time' with the 'show sticky' command but this only shows 100 entries per time and not in time order ?
    Thanks in advance for any help

    Michael,
    You can use the command "show sticky-table" with L3 or L4 options, depending on what you have configured, then add ip addressing to the command, to focus down to where the oldest sticky entries are likely to be, but theres no other way. If your problem is having too many entries, configure a sticky timeout, as the default of 0 will keep then forever, or until overwritten due to the table being full. If the problem is sticky entries timing out too early, you can use the timeout parameter to increase their life, but the sticky table is limited to 32k entries.
    Peter

  • Ended Alveza card status I have been asked by Apple to update the card, but whenever you want to update the collateral does not accept Visa site update Why

    Visa expired my right was my claim by Apple update the credit card, but whenever you want to update the Visa my right in the site does not accept site update Why

    if i have to read any comment by matt n again i will throw up...in my mouth. i have gone all over google trying to figure out what the f ff did to me without my permission, i have updates turned off so there should be no prompting to restart, there should be a polite offer not a forced update. i am angry and so are a ton of people.
    everytime i go to a new complaint, another angry fellow ff user there is matt n with his infuriating smiling little picture...telling me about the awesome safety and security of the new ff...ignoring that a supposed safe but ugly and unusable browser is worse than a customized, beautiful, well functioning browser...with supposed safety issues. i am so angry i cannot express how this has wasted my time. i have been online for 2 hours now figuring out how to fix, apparently i cannot. my old theme is not compatible now...so i am screwed.
    good bye. if i wanted chrome i would have had chrome. but i have no choice now.

  • Hi anyone. Can I buy an SD card reader for my old Powerbook G4, OSX, 10.4.11 and it's only USB. I've never needed one previously but I now need to update the firmware on my camera. Can I get one, if so which one's best? Many thanks.

    Hi anyone.
    Can I buy an SD card reader for my old Powerbook G4, OSX, 10.4.11 and it's only USB.
    I've never needed one previously but I now need to update the firmware on my camera.
    Can I get one, if so which one's best? Many thanks.

    Hello,
    If it is a PowerBook G4 with a PC Card slot, you have two possibilities. You could buy a USB card reader for SD, or a PC Card adapter (such as SanDisk's 6-in-1adapter). Please note that you are or may be limited to plain SD (that is, not SDHC) unless otherwise noted. For a USB reader, make sure that it has Mac support. BTW, is an SD card absolutely necessary for the firmware update; is there not a way of updating via cable? If you post back with the camera model, someone may be able to provide additional information.
    Jan

Maybe you are looking for

  • My wife and I have two different iCloud accounts. How can we share the Address Book?

    My wife and I have two different iCloud accounts. I have an iMac OS X 10.7.5 and she has a new iPad.  My Address Book is on iCloud but when she enters a contact on her iPad it goes to her Address Book. We want it to go to mine. We want to share my Ad

  • Changes made in Bex query not refelecting in Webi reports BO 4.0

    Hello Every One, We have made changes in BeX query and these changes are not getting reflected in webi reports. - We try to edit the connections. - Recreated the new connections and point it the webi report. We are using BO4.0 patch 2.9. DO we have t

  • Oracle 9i on Solaris

    I have Oracle 9.2.0.1 client on Solaris. I need to update the client to 9.2.0.7 per 3rd party program requirements. I have downloaded patch 9.2.0.7 for Solaris from metalink - p4163445_92070_SOLARIS64.zip. but it tries to install the second Oracle ho

  • Supplier Expenditure Table

    Hello All, I have a query regarding SRM - SCM (I am not sure which one since I do not know the difference between these). I am trying to find out: 1. Is SRM and SCM (of SAP) browser based and GUI based respectively? 2. Which of these (SRM or SCM) wou

  • Tick color property for XY graph

    I wish to change the tick color of XY graph programmatically. Then my program written as below. My bar graph contains 4 y scales. So i think the for loop should not be a problem. However, i get the error which stated ' Specified property not found'.