Database of blackberry problem

Hiiii all...

It's my first post

My problem is when for the first time that I create a database in the SD card using Eclipse plugin jde and also make a table and inserting some values inside works well, but only for once, if now I would add some more in my PB was what I do is, I go to the class where I wrote the insert and insert values statement but when I run my application and browsing my database in SQLite database browser it doesnot turn away all changes. I do not see my new values inserted why so much... I don't know it please help...

Thanks in advance

package com.robosoftin.demo;

Import net.rim.device.api.database.Cursor;
Import net.rim.device.api.database.Database;
Import net.rim.device.api.database.DatabaseFactory;
Import net.rim.device.api.database.Row;
Import net.rim.device.api.database.Statement;
Import net.rim.device.api.io.URI;
Import net.rim.device.api.ui.component.LabelField;
Import net.rim.device.api.ui.component.RichTextField;
Import net.rim.device.api.ui.container.GridFieldManager;
Import net.rim.device.api.ui.container.MainScreen;

SerializableAttribute public class CreateDatabaseScreen extends form {}
D database;
public CreateDatabaseScreen() {}
LabelField title = new LabelField ("SQLite Create database example and"+ ")
"inserting a value."
LabelField.ELLIPSIS | LabelField.USE_ALL_WIDTH);
setTitle (title);
Add (new RichTextField ("Creation of a data base and will add a few data" +))
"MyTest.db on the SD card"));
try {}
URI uri = URI.create ("file:///SDCard/Databases/SQLite_Guide/" + "MyTestDatabase.db");
Why do you need to create new DB? either drop a precedent using
DatabaseFactory.delete (uri) then create a new, or use
d = DatabaseFactory.openOrCreate (Uri);
d = DatabaseFactory.create (uri);
d.Close ();

If (DatabaseFactory.exists (uri)) {}
d = DatabaseFactory.open (uri);
create should be performed once atmost
Statement s = d.createStatement (' CREATE TABLE 'People' ('+ ')
"TEXT,"name +"
"" Age "INTEGER)"); "
s.Prepare ();
s.Execute ();
s.Close ();
            
            
Statement s1 = d.createStatement ("INSERT INTO People (Name, Age)" +)
("VALUES ('Uttam', 23) ');
S1. Prepare();
S1. Execute();
S1. Close();
            
Statement s2 = d.createStatement ("INSERT INTO People (Name, Age)" +)
("VALUES ('Rakesh', 26) ');
S2. Prepare();
S2. Execute();
S2. Close();

Statement s3 = d.createStatement ("" SELECT * FROM people "");
S3. Prepare();
Cursor cur = s3.getCursor ();
Line line;
{while (cur. Next())}
Row = cur.getRow ();
GridFieldManager grid = new GridFieldManager (1, 3, GridFieldManager.AUTO_SIZE);
Grid.Add (new LabelField (row.getString (0)));
Grid.Add (new LabelField (row.getString (1)));
Grid.Add (new LabelField (String.valueOf (row.getInteger (1)));)
Add (Grid);
}
            
d.Close ();
}
            
} catch (Exception e) {}
Add (new LabelField (e.getClass () + "" + e.getMessage ()));
}
        
}

}

Tags: BlackBerry Developers

Similar Questions

  • Redirection in blackberry problem

    Hi all

    We are developing an application that involves a communication server. Download us the data from the server and storage in the database and display to the user. the problem is, the server redirects the request to another server and am getting error 302. If there is no redirection that everything works correctly. But the concept of redirection works properly in other devices like the iphone, android. Is there a problem with the blackberry connection? Please help me solve this problem. Additional details are

    OS: 5.0 and higher

    Test device: curve 9360 (OS 7.0)

    development tool: eclipse

    use the connectionFactory interactions http class

    Thanks in advance

    Adkins

    Problem solved!

    I ws wrong shipping method...

    Thanks for help

  • Smartphones with apps blackBerry problem

    Hello

    I have my Blackberry curve 9300 for 7 months already and a couple of days, two of my apps just be removed by themselves - facebook and the Blackberry app world. I have tried to reinstalled them both many times but each time, an error occurred and installation is not finished. One of the messages that are displayed, says there is a problem with the Internet, which is not true. I browse different websites without any problems.

    I tried to install facebook even through their Web site, but market... it means only: an error has occurred, please try again later.

    I rebooted the device and tried again, but it did not work...

    Could someone help me?

    Hello and welcome to the community!

    Please check your time zone settings, according to the this KB:

    • KB25882 "An error has occurred. "Please try again later" is displayed when the user tries to access BlackBerry App World

    Otherwise, you can search the KB database for maybe more useful articles that meet your situation.

    Good luck!

  • Z10 Z10 BlackBerry blackBerry problem

    Hola amigos, he estado en este foro desde than put tapeworm anteriores con equipos SO 5.0 y 7.1, bueno, pues ahora he defined por a BlackBerry Z10 el cual the explico:

    A mi me lo nuevo mi tio lo uso regalaron y probo por lo 2 dias y puso contrasena y blackberry ID y el equipo is tapeworm SO 10.3.2 stink there is activo funcion antirrobo, al hacer a borrado del equipo al forzado no tener the contrasena, me pedia BlackBerry ID el cual mi tio lo creo el con @gnail in @gmailvez.

    Entonces decidi usar el Método remove anti-theft y fixed el problema, pero veo as el equipo tiene muy few applications, solo como 8, me dijeron as debo fornuis via OTA is that ahorita tiene el SO wont developer pero en el celular works so well.

    Pero los details than the he hallado are:

    * The majority of the apps android no lo is our (Whatsapp, FbLite, Instagram, Opera Mini, Candy Crush etc.).

    Tengo el SO 10.3.2.2876, so intento volver has charged el mismo SO me vuelve a activar el antirrobo y no puedo each.

    * El equipo is calienta a poco (los en normal blackberry).

    Me so no tengo acceso para fornuis Wifi! Espero me help thanks!

    GOOGLE TRANSLATE:

    Hello friends, I have been in this forum because I had my previous teams with OS 5.0 and 7.1, well, because now, I chose a Z10 BlackBerry which I explain:

    For me that my uncle gave me new use it and tested for two days and put the password and blackberry ID and hardware already had OS 10.3.2 and as the anti-theft function is active, to do a removal forced the team's do not have the password, the BlackBerry ID pedia me as Uncle @gnail believed him instead of @gmail.

    So I decided to use the method remove anti-theft and solved the problem, but I see that the team has very few applications, like 8, told me I need to update via OTA because now you have installed the OS developer but if the phone works fine.

    But the details I found is:
    * More android apps do not open close (Whatsapp, FbLite, Instagram, Opera Mini, Candy Crush etc.).

    OS 10.3.2.2876 me, if I'm trying to reload the OS activate even me again the burglar and I can not use it.

    I recommend that I have no wireless access to day! I hope to help me and thank you!

    Solved! Thank you!

  • Q5 with accents blackBerry problem

    Hello!

    I bought my BlackBerry Q5 three days ago and this afternoon, when I pressed a long time on a letter,

    nothing!

    Normally, because I'm French, there are some proposals of letter with accents!

    So I put my tongue and my country, the Chinese, then the French!

    After it was OK!

    I just want to know if it will go another time and if an update will fix this!

    Thank you

    Antoine

    PS: I'm sorry for my English, as you may have read: I'm French

    I'm glad that you were able to fix it yourself, it might well be that future updates will suffer from the same problem until it draws the attention of the BlackBerry development team and attaches.

    Unless other will benefit from your difficulty so far here.

  • BlackBerry - problem downloading file

    I want to be able to download files via the java app BB

    first attempt:

    I create browserfield to call 'upload.php' and send the file dirrectly from this page, but got the following error message

    [24941.271] VM: + GC (f) w = 11
    [24942.203] VM:-GCt = 119, b = 1, r = 0, g = f, w = 11, m = 0
    [24942.264] VM:QUOT t = 8
    [24942.264] VM: + CR
    [24942.287] VM:-CR t = 3
    [24943.78] type of bridge: 5 PID: 149 Exception loading URL: net.rim.device.internal.bridge.BridgeDatagramTooLa

    RGEException [24943.78]: size of datagram Bridge: 8295740 exceeds the maximum: 1048576
    [24943.78] AM: output net_rim_bb_browser_olympia_proxy (397)
    [24943.78] net_rim_bb_browser_olympia_proxy cleaning (397) process that is started
    [24943.78] type of bridge: 5 PID: 149 cleaning process Java run
    [24943.787] VM:EVTOv = 7680, w = 201
    [24943.787] type of bridge: 5 PID: 149 disconnection
    [24943.787] type of bridge: 5 PID: 149 uninit
    [24943.797] type of bridge: 7 PID: 149 cleaning process Java run
    [24943.805] type of bridge: 7 PID: 149 disconnection
    [24943.812] type of bridge: 7 PID: 149 uninit
    [24943.812] type of bridge: 5 PID: 149 uninit

     

    second attempt:

    Oh... I thought I can solved this problem by creating a loading screen to read data from the file and send it to 'upload.php' as a type string or one he calls binary data may be...

    I followed the instructions in the following thread

    http://supportforums.BlackBerry.com/T5/Java-development/problem-how-to-upload-file-to-server/m-p/186... and... many other thread

    Pro:

    1. I can send text file on the server with the size< 100kb,="" it="" can="" be="" bigger="">

    disadvantages:

    1. only works with "interface = wifi", other type as Boolean deviceside does not work

    2. when I tried to download an image type ' image/jpeg', the compiler returns the following error

    [9852.57] GS (createSurface): promote temporarily the size of the window
    [9852.585] VM:EVTOv = 1, l = 31
    [9852.585] CMM: CreateFileApp (970) No sig 0 x 424252
    [9852.601] VM:EVTOv = 1, l = 31
    [9852.617] VM:EVTOv = 1, l = 31
    [9852.617] BRM:IDL +.
    [9852.625] BRMR +.
    [9852.625] BRM:NMC:393216
    [9852.625] BRM:JFR:92175860
    [9852.671] VM:EVTOv = 1, l = 31
    [9852.687] VM:EVTOv = 1, l = 31
    [9852.703] VM:EVTOv = 1, l = 31
    [9852.75] VM:EVTOv = 1, l = 31
    [9852.75] BRMR -.
    [9852.75] BRM:NMC:393216
    [9852.75] BRM:JFR:92175860
    [9852.75] BRM:IDL -.
    [9852.812] VM:EVTOv = 1, l = 31
    [9853.0] - 1
    [9854.257] VM:RTMSh = 134, o = 0x34101C00, p = net_rim_bb_trust_application_manager
    [9854.257] VMPRMv = 1
    [9854.265] AM: output net_rim_bb_trust_application_manager (388)
    [9854.304] VM:EVTOv = 7680, w = 194
    [9854.312] net_rim_bb_trust_application_manager cleaning (388) process that is started
    [9854.312] net_rim_bb_trust_application_manager cleaning (388) process
    [9864.101] server response: IMG-20130324 - 00241.jpg
    0
    error

    [9866.492] JVM: bklt @9866492: timer
    [9866.492] JVM: bklt [1] @9866492: usrIdle 14, usrTime 30, usrAct 1
    [9866.492] JVM: bklt [1] @9866492: chkIdle currTime 29, 31
    [9866.492] JVM: bklt @9866492: setTimer 16

    then I want to have a dead-end in my way... but what facebook, twitter etc. Use to upload the local file on their server ?

    additions to Split into pieces

  • Q10 Skype on my blackberry Q10 blackBerry problem

    I would like to share my problems with Skype. I have problems every day. The screen is freezing and not responding do not. I have uninstall several times to install again, but still is the same--a few hours of work normally and that the freezing point.

    I need urgent help...

    Best

    Ivo

    Hi Ivanlovelikov

    I recommend that you enter in the blackberry World

    And check if you have a new update of Skype

    But you have a new update, I invite you to download the Android BlackBerry BlackBerry Runtime application on the same world.

  • Database in Blackberry

    I need to store my data in my laptop, I need to use a database.

    But wich type of database is supported by most blackberry devices?

    Pls help me

    From 5,0 tou can use Sqlite...

    Or you can use RMS or PersistentStore (not exactly the databases but it might do the trick for you)

  • Connection of Z10 Wifi blackBerry problem

    I have problems connecting to a certain WiFi network.

    When I set this up, everything works perfectly. (Network Eduroam University with certificate authorization and eap tls).

    But when I move from one point to another that the login is disabled and when I turn it on again once I always get one of two errors:

    -Invalid EAP login data

    -Network authentication failed. Check network security preferences

    I greeted handover between Access automatically points. Can I prevent deactivation by switching wifi and before changing the location (not very convenient)

    Once the connection is disabled, I have to restart the BlackBerry. After that I'm more able to connect.

    Network administrators can not help me.

    It is very annoying and no iPhone or Android don't seem to have this problem. With my old Bold 9700 the automatic change of the access points have worked perfectly.

    Is there something else I could do?

    Thanks in advance!

    My device

    Z10-STL100-2

    SW 10.2.1.2102

    Since the last update (10.2.1.3247), the problem disappeared and constantly appeared again.

    Can't say more but I'm happy!

  • Protect the Q10 blackBerry with Blackberry problems

    Hello Blackberry community,
    Recently, I've had my Blackberry "BOLD" stolen so I said 'no problem, Blackberry protect will take care of all my stuff. "Sound in the cloud." But today, when I got the blackberry protect recovery in my brand new Q10 I realized that I don't have that 31 contact now! Almost all my contacts are GONE! Anyone know what could have happened with the rest of my contacts? I do not understand how the Blackberry protect weekly backups I had put up only ended up saving a small part of my contact list. According to the Blacberry protect the site, the last backup was August 5, 2014. My cell phone was stolen on 12 August, the backup should be updated. But it's not. Is there a problem with Blackberry protect migrate Blackberry 7-10 of Blackberry? No indication as to what is happening with my contacts is greatly appreciated.

    Concerning

    Hello there, 31 contacts most likely are from a very old backup, and all your contacts are now synchronized wirelessly with your email. Which is why you don't have them in a BlackBerry protects back upward.
    Haven't you set up your email yet? What are the prospects it, Gmail?

  • Z10 Z10 Contact with BBM blackBerry problem

    I recently updated my Z10 via BB link to the version of the 10.2.0.424 software and since then something strange happens with my contacts. I search for a name using the APP contact and dial the number of the office. After the call, the contact name is always displayed in my contacts list, but when I open the contacts to view the details, the name has been replaced with a BBM PIN code #. The PIN is also appearing in the list of calls instead of the name. The name is still in the list of contacts. Here's the weird thing in a case the BBM PIN # is for the BlackBerry phone staff people and not used for his work (the number in which I called him) he does not use his personal phone for business or work email. How did you personally BB PIN # end up on my phone?

    Hello Dale65

    Welcome to http://supportforums.blackberry.com/

    Follow the instructions to reload the BlackBerry OS link

    Plug into your BB10 and BBLink
    Then go to preferences and press on the optional software reloads

    Let the process do all your work, and then you begin to define your BB
    And load your backup.

    And let us know if your problem is persistence.

    You must have the latest version of the BlackBerry link installed

    Today updated the link for BlackBerry to version 1.2.0.32

    Download of BlackBerry link v1.2.1.31 (Windows OS)

    Download of BlackBerry link v1.1.1.39 (Mac OS)

    Stay on your side if you want again to 10.2

    Kind regards.

    VIA | gutijose14

    http://supportforums.BlackBerry.com/T5/BlackBerry-Q10/software-update-10-2/m-p/2668971#M13194

  • Emulator blackBerry problem

    Hello

    I installed the Netbeans 6.8.

    I installed the Blackberry JDE 4.7.0

    By using the following link

    http://http://Java-work.blogspot.com/2010/03/integrating-BlackBerry-emulator-with.html

    My problem here is that the Netbeans 6.8 had added the emulator of the Blackberry 9500

    I have download the LWUIT 1.4 and make use of the BlackberryTouchport.jar file in Netbeans 6.8

    When you run a particular program it does not launch this program rather that it showing the Blackberry 9500 emulator home page

    Hello

    I managed to install the plugins and emulator (9500 & 9000) Blackberry in Netbeans 6.8.

    Thank you for your help.

  • Q10 Blackberry ID blackBerry problem

    Dear Sirs,

    I have a problem with the Blackberry ID, somehow, I lost my password ID BB when I fight my Q10, never had any problems with it so I never had to look for him, I had some problems with my cell phone like turning off by itself every now and then these days and I took it to the provider (Vodafone). Do beckup on my laptop on blackberry link before and went to their maintenance workshop, they have erased all information from my device and Redid the software, obviously when I tried to restore from my laptop it asked me my BB ID which I didn't and Valerie could help me Vodafone went into the site ID blacberry and filled the form to reset my BB ID, I knew that the email address so that what was missing was the password, chose to forgotten password and the site told me that a password was sent to my email address BUT since yesterday nothing HAPPENED! I've been everywhere calls for help but help comes from knowhere, I really need this ID as my laptop is missing a few contacts of 1500, not allowed to e-mail accounts, no whattsapp, nothing... Please help me

    Check your spam mailbox folders and web mailbox.

    You also could whitelist the following address in your e-mail settings to make sure it is getting through:

    [email protected]

  • What is the location of the database in Blackberry while using phonegap

    I have a 9800 Simulator.
    I mounted a directory like SD card...

    Now, if I use

    I have a 9800 simulator.
    I mounted a directory as SDcard...
    
    Now if i use 
    
        function populateDB(tx) {
             tx.executeSql('DROP TABLE IF EXISTS DEMO');
             tx.executeSql('CREATE TABLE IF NOT EXISTS DEMO (id unique, data)');
             tx.executeSql('INSERT INTO DEMO (id, data) VALUES (1, "First row")');
             tx.executeSql('INSERT INTO DEMO (id, data) VALUES (2, "Second row")');
        }
    
        function errorCB(err) {
            alert("Error processing SQL: "+err.code);
        }
    
        function successCB() {
            alert("success!");
        }
    
        var db = window.openDatabase("Database", "1.0", "Cordova Demo", 200000);
        db.transaction(populateDB, errorCB, successCB);
    

    So, where will be my database is stored? And how can I see it?

    Try to watch this tutorial...

    http://docs.BlackBerry.com/en/developers/deliverables/8682/Create_a_SQLite_database_761831_11.jsp

  • transmission configurable url in the browser blackberry problem

    Hi... I have to go or ask the server the URL page... I don't have problem to request the page as

    _browserField.requestContent ("http://www.google.com");

    but I have problem to request the page as

    _browserField.requestContent ("http://www.google.com?userid=" + userId + "");

    It shows error as error http to connect to the origin server... pls someone help to solve this problem

    Thanks

    It's just a guess, but it sounds like a problem with encoding.

    You should encode them the query string part before concating it to the URL.

    Check out this class:

    http://www.BlackBerry.com/developers/docs/5.0.0api/NET/RIM/BlackBerry/API/browser/URLEncodedPostData...

    E.

Maybe you are looking for

  • Bring back our colors!

    It's more a coup to face a request (even if it's indirectly) The algorithm of color is what iTunes does stand out from other music libraries. That's what throws us in the future. That's what made my whole IMMERSIVE music experience.  I was friggin im

  • my computer says that my primary drive 1 not found, secondary drive 0 is not found. also allicating I/O bar for PCI device error.

    We had a power outage about 2 weeks ago, it burned my hard drive. My neighbor put a new disc in for me, now my computor is said primary drive 1 not found, O secondary drive not found, and 1 secondary drive not found. I do not know how to solve this p

  • Re: ThinkPad X60s BIOS lock

    I had questions affecting all BIOS options and learned to talk to my manager of the facility access (in the BIOS options). Unfortunately, I can't access and there is nowhere to give a supervisor password, so I can actually make changes. I was hoping

  • SQlite operations slow down the user interface on OS 5 thread

    Hi guys,. No notices that DB operations slow down the UI thread? For the entire application is unresponsible, and sometimes all the devices. Is it because that the operations of SD card? Could someone RIM's comment on that? Thank you Eugen

  • Switched Port Analyzer (SPAN) with ports different speed

    Hi all I want to configure the Analyzer SPAN (Switched Port) on 6500 SW as TenGig port Source port and destination port that connects the device is 1 Gig. This works if the source and destination have different speeds? Kind regards Lou.