Problem of SQLite in os 5 but that works well on os 6

Hi all!

I have a problem with my code while running under Curve 8520 with os 5.0.0.1036 (last available for 8520). I use a sqlite database, and all my code works fine in os 6 in a torch 9800.

But the 8520, I get an exception sying that I try to write in a database read only.

Here is my code to initialize the database:

private DbManager() throws Exception
    {
        // Determine if an SDCard is present
        boolean sdCardPresent = false;
        String root = null;
        Enumeration e = FileSystemRegistry.listRoots();
        while (e.hasMoreElements())
        {
            root = (String)e.nextElement();
            if(root.equalsIgnoreCase("sdcard/"))
            {
                sdCardPresent = true;
            }
        }
        if(!sdCardPresent)
        {
            this.db = null;
            UiApplication.getUiApplication().invokeLater(new Runnable()
            {
                public void run()
                {
                    // TODO : translate
                    Dialog.alert("The application requires a SDCard to store the history. Without card, your history will not be stored.");
                }
            });
        }
        else
        {
            dbLocation = "/SDCard/databases/"+BUNDLE_NAME+"/";

            // Create URI
            URI uri = URI.create(dbLocation + DB_NAME);     

            // Open or create a plain text database.  This will create the
            // directory and file defined by the URI (if they do not already exist).
            db = DatabaseFactory.openOrCreate(uri);  

            // Close the database in case it is blank and we need to write to the file
            db.close();

            // Open a connection to the database file
            FileConnection fileConnection = (FileConnection)Connector.open("file://" + dbLocation + DB_NAME);    

            // If the file is blank, copy the pre-defined database from this
            // module to the SDCard.
            if(fileConnection.exists() && fileConnection.fileSize() == 0)
            {
                readAndWriteDatabaseFile(fileConnection);
            }         

            // Open the database
            db = DatabaseFactory.open(uri);
        }
    }

And here is the statement that works with os 6, but not with the os 5:

public Integer create(Table table)
    {
        long id = -1;
        try
        {
            Statement statement = this.db.createStatement("INSERT INTO ZTABLE(" + Table.TABLE_PK +
                    "," + Table.TABLE_LONGITUDE +
                    "," + Table.TABLE_DATE +
                    "," + Table.TABLE_LATITUDE) VALUES (null,?1,?2,?3)");
            statement.prepare();
            statement.bind(1, table.getLongitude().floatValue());
            statement.bind(2, table.getDate().getTime());
                        statement.bind(3, table.getLatitude().floatValue());
            statement.execute();
            statement.close();

            // Retrieve the auto-generated ID of the item just added
            id = this.db.lastInsertedRowID();
        }
        catch(DatabaseException dbe)
        {
            CommonTools.errorDialog(dbe.toString());
        }
        return new Integer((int) id);
    }

Is there a question about the 5 operating system and functionality of sqlite? Or y at - it something wrong in my code that avoids a correct behavior?

Thank you very much in advance for your answers.

I use SQLite Database Browser on OSX:

http://sourceforge.NET/projects/sqlitebrowser/

never had any problems using db BB OS5 or OS 6

Tags: BlackBerry Developers

Similar Questions

  • Flash wont 'register' on XP sp3 using IE7 but that works well on Safari

    Hello

    I lost flash on my desk, that I don't even remember how long ago. I just downloaded safari and used for things that need flash as youtube and others.

    I really want to solve this problem, so it does not work with Internet Explorer again, however. I read several help letters posted and tried to uninstall and reinstall and reboot several times and search the stop bit for all sorts of things but no luck. When I go to the control panel and click on the flash icon it says flash is installed for safari, but not for IE safari version is 10.3.181.34 when I do the installation for IE, it works 53% and fails and says "error unable to save. I ran malwarebytes, ccleaner and avg and avast antivirus, thinking there had to be some kind of malware, but no difference.

    If someone take me by the hand and tell me step by step what to do to diagnose and fix this problem I would be estatic. So, thanks in advance for any help offered.

    Jim III

    Sorry about that; I forgot the download link is incorrect; Download the file from http://kb2.adobe.com/se/cps/494/cpsid_49419/attachments/reset_fp10.zip

    (I will alert you tech services to fix this link of writing).

  • ECOSYS P6026 ca is not airprint in color... but that works well when sent from a PC

    trying to print wireless ECOSYSTEM P6026cdn in color.  Works fine with sending over the network from a pc, but will not work with ipads

    AirPrint on iOS devices is NOT based on the same printer driver installation. It's really to the manufacturer of the printer to provide support for the functionality of the printer for iOS platforms. When you print from a Windows PC, you do not use AirPlay. This isn't really a problem for Apple network.

  • Anyone know why the phone was hidden on white on iphone and ipad, but that works on android, how to fix?

    Anyone know why the phone was hidden on white on iphone and ipad, but that works on android, how to fix? TKX

    iOS devices automatically detect the phone numbers and make a link. We use link styles you have defined.

    Go to Site settings and create a new style of link with colors that will work and apply.

  • Product that works well to choose Select the pages to an existing PDF and copy to a new PDF file?

    Product that works well to choose Select the pages to an existing PDF and copy to a new PDF file?

    Hi Gregh65396892,

    You must use Acrobat, you can download a free trial of 30 days from the following link: https://www.acrobat.com/en_us/free-trial-download.html

    After downloading and installing Acrobat, you can open both files in acrobat with enabled page thumbnails view, select the pages in a PDF document, then drag them to the pane "thumbnail" file pdf of another, and these pages will be copied in the second file.

    Kind regards
    Rahul

  • I have a Creative cloud photography Plan (CC of Photoshop Lightroom). There a serial number for registration? because I have received no series by mail, but it works well!

    I have a Creative cloud photography Plan (CC of Photoshop Lightroom). There a serial number for registration? Because I have received no series by mail, but it works well! And he never asks me to activate with a serial number. I just pay monthly Plan.

    I ask this question because I have to change the computer and I didn't have trouble disattivate App and put it on the new pc!

    Can I turn off just from the creative cloud by disconnection of the account application, uninstall the application and then install on the new pc?

    The CC has not need any number of series, it is based on an Adobe ID.

    In the case where you are prompted for the serial number then you can refer to.

    Concerning

    Baudier

  • soundsnotcoming Laptop speakers on windows but that works with ubuntu

    Audio speakers aren't working only not with windows7/8/xp. But they work with Ubuntu 12.04/13.10.

    In windows, the earphones are functioning (plugged into the front outlet)

    Most often when a device does not work, it is because the driver is damaged. Re-install a new copy should help

    http://Windows.Microsoft.com/en-us/Windows7/update-a-driver-for-hardware-that-isn ' t-work correctly? SignedIn = 1

  • I upgraded to firefox 3.6 recently 11, but firefox11 works well with my windows 7. It became slow and strucks on for 6 seconds for each click.

    11 Firefox hangs frequently for about 6 seconds for each click as switching between tabs, closing tabs, opening new tabs.
    by clicking a link etc,
    3.6.17 worked well, but 11 Firefox is too slow.
    problem is the same with version 4 and 4.01
    can someone please help me to solve my problem

    I'm sorry that you have problems with Firefox doesn't work is not as fast as it should. I'd like to help you here so that you manage Firefox running at great speed.

    Firefox, try to start Firefox in Safe Mode. It temporarily disables your extensions, customizations, etc. so that we can see if they slow down Firefox. If Firefox works fine in Safe Mode, then it is probably a problem with the add-on. Restart Firefox in normal mode, and then type "subject: addons" (without the quotes) in the address bar. Disable your extensions, restart Firefox between each one, until you find the troublemaker. Once you do, you can disable this add-on.

    I also see you have advise McAfee Site. I would recommend disabling that, as it is known to cause leaks of massive memory than Firefox slow down

    If Safe Mode does not work, you can also try updating your graphics card driver. Update your graphics drivers to use hardware acceleration and WebGL reading can show you how to do this.

  • Satellite L70 - no sound from speakers but headphones work well

    Hello

    I have a sound problem with my computer (satellite 70 L)
    I tried everything but nothing to do, no audio output, but plugging the headphones into the audio port reinstall his works well, so I uninstall Conexant, even for its dts but its still doesn't work does not,

    Thank you

    In my view, the symptoms of laptop are clear enough: he does not resemble his driver or system problem because the sound seems to use the headset.

    I think that the internal speakers are defective. It seems strange to me that the two speakers have begun to malfunction at the same time, but this problem may occur.

    But before you contact the authorized Toshiba maintainer to fix, I would recommend you to recover the laptop just to be sure that this problem is not related to the failure of the system/software to 100%.

  • Creating Pages that work well on all Types of layout (Desktop, Mobile, Tablet)

    Hello

    I was reading the Adobe employee responses to a question that someone asked you to get a sensible width that works on all layouts (including the desktop, Tablet, Mobile) and I read your explanation of resizing of the browser window a little smaller until you cross a breakpoint, then resize slightly larger then it switches back on the smallest width that belongs to the next breakpoint plu followed by ScrollBar control horizontal and checking the items, for sensitive post and sizing settings etc. I checked and double checked all troubleshooting suggestions and I'm still not find what is causing the error.  Some of the pages on my site from work, some do not, and I can't find the common denominator that causes this problem of width sensitive.  The page looks good on a desktop computer, but it is to slap on a mobile device; I just want one suitable for a page-all and I've never had as much trouble with it before.  It is a very simple page and short (well, I'll have the same problem on a few pages - very short and simple), you think you can take a look at my .muse file and let me know what I'm missing? Time is a huge factor here, can anyone help me quickly?  The temp link is: HOME
    I appreciate your time!  The first page that is having this problem is the homepage.

    Hi @bpmcelwaine,

    Sorry I have not been on in a few days. I take a look at your file.

    I read that you have inherited this file to someone... it's fun!

    There are a few things it could be:

    #1 change the width of your Web site to 1000px because honestly your design starting to break at the level of the mark 960px, then this where your first breakpoint must be

    #2 that the navigation is on every page, this really should be on a Master Page and breakpoints must be added in there. (Ditto for the footer)

    #3 after you have done that delete pages. You can then add another breakpoint in your Master around 550. Move navigation where it should be and the PIN properly.

    #4-ensure that all images and text on your pages are on "width and height sensitive."

    #5-after doing this, the point 960 on your home page, you may need to move the text to the right side of your slideshow slot your slideshow, Ditto for the text boxes with the image. Basically, you need to simply close the browser width slowly and see what needs to change. Sadly, you have to work your way through the pages and do this everywhere. These are things that probably should have been made when the site was built.

    #6-the white boxes behind the slideshow and the text/images are difficult to treat because Muse does not pitch well. You might consider losing the bottom grey and changing to white background in order to mitigate this problem.

    I hope this helps!

  • Your linux desktop that works well with the fuser unit - is - it?

    I don't know anyone who runs linux on Fusion guest is aware that everything in 3D acceleration works (at least in Ubuntu) window of vmware Fusion to unity mode works not by 3D. And that since all popular linux distributions moves to 3D desktop computers we are practically forced to stop or mode full screen.

    My question is: someone found a good 2D for linux desktop computer that works with the fuser mode, and is also an up-to-date distribution?

    There are a few suggestions on an old net http://communities.VMware.com/message/2139647#2139647 to use With Mate Mint, but who had serious problems for me.

    I'm looking for basically two things.

    First of all the possibility to use the window of the unit mode.

    Second, the possibility of placing several editable launch icons in a home/toolbar etc station in Linux comments so I can open two different documents side by side, very quickly (which was another failure of Mate).

    Specifically, I'm eager to open two sets of accounts in Gnucash. This worked wonderfully in Ubuntu 10.04, and while it is tempting to return 10.04 reached EOL in April 2013 - he is also packing a old version of Gnucash that I'm used to using.

    (btw a different alternative, using the OSX of Gnucash package: works, but the heartbreaking text is horrible, that is why the desire to run in a Linux VM.) MacPorts/Fink is also out because it takes so long to compile whenever there is an update. Want a binary).

    Any suggestions?

    Confirmed to work with xubuntu 14.04.  Note, you need to install vmware tools and restart the virtual machine for this to work.

  • Messenger on Mac just disconnects and says service unavailable or something, but it works well for a few weeks.

    Messenger on MAC disconnects and says service unavailable or something, but it just works well for a few weeks... really annoying, please help!

    original title: WHY IS MSN MESSENGER 8 MAC NOT WORK?

    Hello

     
    You can display the query in the links provided to get better assistance.
    http://mac2.Microsoft.com/help/Office/14/en-us/Messenger/
  • Connection failed on version 37.0.1 but that works in all other browsers and firefox 36

    Question very similar to this, https://support.mozilla.org/en-US/questions/1056423. Am able to go to http://www.independentagent.com , then when you click on the link "sign" (which redirects to https://sso.iiaba.net/login.aspx?sid=xxx) this error indicates:

    The secure connection failed

    The connection to the server was reset while the page is loading.

       The page you are trying to view cannot be shown because the authenticity of the received data could not be verified.
       Please contact the website owners to inform them of this problem.
    

    I went through the area of the sso.iiaba.net https://www.ssllabs.com/ssltest/analyze.html?d=sso.iiaba.net and it advises a few warnings, but gives the site an overall rating of B.

        • Fixed. As noted, we were supporting former ciphers. We dressed and had recourse to the list of encryption and now we get an A on the analysis of ssllabs.com . Firefox does now, no problem. I wish the original error message was more descriptive.

    The site may attempt to return to TLS 1.0 in a way that is no longer allowed in current versions or maybe use a deprecated suite of encryption.

    You can open the topic: config page through the address bar and use the search bar to locate this pref:

    • Security.TLS.insecure_fallback_hosts

    You can double-click the line to edit the prefs and add the domain (sso.iiaba.net) to this preference.
    If there are already websites (domains) in this list, then add a comma and the new domain (without space).
    You should see fields separated by a comma in the value column.

    This site uses the encryption algorithm RC4 for the encryption, which is obsolete and little course. Login.aspx

    This site uses a SHA - 1 certificate; It is recommended to use the certificate with the signature algorithms that use stronger than SHA - 1 hash functions. [Learn more]

  • Animations by pulling twice on chrome and IE but that works flawlessly in Firefox.

    My animations of reversal is "disjoint" and trigger a rollover on a button and trigger an animation "blast doors" opening. The animation of the doors opening (animated gif) play twice on Chrome and IE. It should play only once. Everything works perfectly on Firefox.  The page works in Firefox, that's how I need to work in Chrome and IE.  Should what changes I make to the address/edit my code that IE and Chrome work exactly like Firefox treats the code?  Note that I'm not a coder.  I understand that some, but certainly a noob.  This is my first website. The entire site was made with Photoshop/Fireworks/Dreamweaver.  The site is at LAZZARODESIGN.com. Will display the code if necessary.

    Thanks in advance for any help on this problem of compatibility between browsers!

    #1 your page is only 770px wide, so it doesn't look much on the wider screens high resolution. See screenshot.

    #2 your site is not responding.  She is not re - measure made mobile, tablets and desktop computers.

    #3 Photoshop generated code is not valid.  See the link below for more details.

    [Valid] Validation of the markup of http://lazzarodesign.com/ - W3C Markup Validator

    Code errors result in 98% of the browser rendering problems.   Some browsers are less lenient error code than the others.

    Nancy O.

  • Query that works well as a toad, but not in forms 6i

    I now coding at the time press the triger

    declare
    CURSOR C1 (year number, month number) IS
    SELECT ITM_NO, ITM_NAME, XAQ QTY XAQ * TP VAL, gp
    Of
    (
    Select ci.itm_no ITM_NO, ci.itm_name ITM_NAME, cpg.group_id gp, xaq, ALLIED. CORP_PRIC_TP (ci.itm_no) TP of
    (
    Select prod_no, sum (xaq) * 1 xaq
    Of
    (
    Select prod_no, sum (nvl(xrd_sqty,0)) Xaq
    of allied.mrk_01_02
    where year = f_prd = month and year
    and area_id in (10200,10400,10100,10300,10500,20500,20300,20100,20200,20400,30100,30400,30300,30200)
    Prod_no group
    Union of all the
    Select prod_no, sum (nvl(xrd_sqty,0)) Xaq
    of allied.mrk_02_02
    where year = f_prd = month and year
    and area_id in (10200,10400,10100,10300,10500,20500,20300,20100,20200,20400,30100,30400,30300,30200)
    Prod_no group
    Union of all the
    Select prod_no, sum (nvl(xrd_sqty,0)) Xaq
    of allied.mrk_03_02
    where year = f_prd = month and year
    and area_id in (10200,10400,10100,10300,10500,20500,20300,20100,20200,20400,30100,30400,30300,30200)
    Prod_no group
    Union of all the
    Select prod_no, sum (nvl(xrd_sqty,0)) Xaq
    of allied.mrk_04_02
    where year = f_prd = month and year
    and area_id in (10200,10400,10100,10300,10500,20500,20300,20100,20200,20400,30100,30400,30300,30200)
    Prod_no group
    )
    Prod_no group
    ) A, allied.corp_inv, c01, c02, GIC, vpg allied.v_prod_grp allied.corp_prod_group allied.corp_01_02 allied.corp_01_01
    where this .itm_no = a.prod_no
    and this .itm_no = c02.itm_no
    and c01.grp_id = c02.grp_id
    and in c01.grp_id (55,56,57,58,59)
    and vpg.prod_no = ci.itm_no
    and vpg.group_id = cpg.group_id
    )
    where XAQ <>0;

    Begin
    delete from fiaz.tmp_topten_prod;
    because me in c1(:year,:month)
    loop
    insert into fiaz.tmp_topten_prod
    values (i.itm_no, i.itm_name, i.QTY, i.Val, i.GP, 0);
    end loop;
    standard.Commit;
    message ("inserted into temp'");
    exception when others then
    message (dbms_error_text);
    message (dbms_error_text);
    End;

    Same works of query (as used in cursor c1) fine in Toad but gives bad result of forms... and the problem is xaq field i.e returns incorrect quantity...
    I guess that the union clause does not work in this situation...
    Please suggest me the appropriate changes in the query to work much of the form as well...
    combination: Forms 6i, Oracle 8.0.6
    Kind regards
    Usman Afzal

    Did you get the grant on your mrk_01_02 of the table through a role? If so you would need a direct subsidy:

    http://asktom.Oracle.com/pls/Apex/f?p=100:11:0:P11_QUESTION_ID:1065832643319

    see you soon

Maybe you are looking for

  • Satellite Pro L40 - wireless adapter does not work - Vista

    I recently had some problems with my laptop.A couple of weeks, I put in a disc of OpenSuse.It's not stable anything, but locked me out of my original Vista operating system. I reinstallled Vista Home Basic, but there are a few problems.Mainly, my wir

  • How to make DVD player region free player on Satellite L40 - 14Y

    I can not play region 1 DVD on my player. (PowerDVD, windows player) The usual 5 times have been used. I've heard of software to make your region free player, but I don't want to ruin my notebook or losing my warranty. So is it a software or the abil

  • Presario CQ42: To change boot order

    I'm changing the boot on my laptop PresarioCQ42 settings. Instructions on the HP site telling me to log on to the BIOS settings and the press of the Advanced tab. I opened e parameters the BIOS but do not see the tab Advancsd. Can someone help me Aus

  • WRT56G connects to the PC

    I have just come from my WRT56G as a friend and have a strange problem.  I connect the modem directly to a PC so that I can put it up, but no connection - any port I use.  I have W7 and have no problem with my other router (Dynex... Yes, I said Dynex

  • Error during client access VPN SSL 210.210.12.19 you may have insufficient rights on the computer. _ (5030062)

    Error then access SSL VPN client 210.210.12.19 once connected to Active X startd download site and ends with the following error: could not start the components needed to start the client, you may have insufficient rights on the computer. (5030062) N