[android-developers] Re: Database access error causes force close
On Sat, Dec 06, 2014 at 01:13:37PM -0800, Ted P wrote: On another note, learning to use the debugger is pretty easy, and super helpful especially in situations like this That's ultimately what put me on the right track. As it turns out, there is some conflicting information. The tables I try to read from don't exist in the online version of the database (as indicated by an error message in the debugger) and yet, a query on those tables returns all of the expected data ... correctly. The biggest thing I did was, upon seeing a new example, remove the try/catch for the cursor and replace it with if (c != null). That's when it started working right, and those tables that don't exist gave the cursor the exact data that's in them. :-) I don't understand the conflicting information, but hopefully that can get sorted out sooner or later. As to what code I'm using for the DataBaseHelper class, it's mostly adapted from this example: http://www.reigndesign.com/blog/using-your-own-sqlite-database-in-android-applications/ The SQL query itself (just one test one so far) is from many tutorials with my own limited SQL experience providing the SQL portion. Thanks, --jim -- THE SCORE: ME: 2 CANCER: 0 73 DE N5IAL (/4) | spooky1...@gmail.com | BOFH Excuse for the day: Running Mac OS X Lion | Too many ICBM / Hurricane: | . 30.44406N 86.59909W| interrupts -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en --- You received this message because you are subscribed to the Google Groups Android Developers group. To unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[android-developers] Re: Database access error causes force close (Update)
On Fri, Dec 05, 2014 at 02:59:20PM -0600, Jim Graham wrote: I'm trying to use an SQLite table with Android (and for almost the first time, period, but I familiarized myself with it using SQLite3 / tclsh8.4), and I've run into a bit of a problem where I can't seem to spot the error. Update: There may be a problem with the initial copying of the database. The copy in assets (according to ls -l is 150528, but long size = new File(db.getPath()).length(); reports a size of 12288. Does Android silently do compression of the database? Or was it only partially copied, thus likely explaining the error? Thanks, --jim -- THE SCORE: ME: 2 CANCER: 0 73 DE N5IAL (/4)MiSTie #49997 Running Mac OS X Lion spooky1...@gmail.com ICBM/Hurricane: 30.44406N 86.59909W Do not look into waveguide with remaining eye! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en --- You received this message because you are subscribed to the Google Groups Android Developers group. To unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[android-developers] Re: Database access.
Hello there! I had done the same, but a little different way. I found an xml library which was able to send messages to an server( IP and Port). I had created another project (normal java) and I had implemented there a server which was able to recive the android clinet requests and communicate with MySql DB. After the development completed I had exported into a jar file the server and just start it from a command line. cheers, Karoly On máj. 21, 10:07, Laxmihari laksh.ne...@gmail.com wrote: Hello everybody , I've just started Android application development only for my use. I succeed to develop small apps. Now, I'm trying to enhance my android development skills further and want to access central MySql database server from my android tablet / phone, like adding, deleting, modifying into the database using android coding. I'd appreciate your immediate answer on this topic. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Database access from another android phone.
Since devices on mobile networks generally can't be reached by incoming connections, you will probably have to have a server somewhere which all the mobile clients check in with so it can forward traffic between them (possible using C2DM to get their attention). You will have to build functionality into the app running on each device so that it can accept requests for db operations from the server. Do think about the privacy, battery life, and data plan limit/charges implications of what you are building. On Friday, March 30, 2012 4:15:09 AM UTC-4, Kirupa wrote: I want to access database of an application(I know the structure of database) from the another android phone.(every android phone has same application same database). -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Database Access from Android Application
John, The web script does not allow for open queries, it takes in the users username, password, and device id, and authenticates them with the server, before it then takes and executes a built in query on the script, using more POST data. If i store each persons information into different Tables, then the only thing that people can mess with is the information for which they have a password to modify. This is what i am currently using with PHP, and i see your point about embedding the SQL information in the app. On Jan 22, 7:15 am, Mark Murphy mmur...@commonsware.com wrote: On Sun, Jan 22, 2012 at 3:51 AM, Matt Clark mrclark32...@gmail.com wrote: Is there some kind of SQL library that i could just use insted of sending HTTP requests parsed by PHP files? That is not a good idea, for security reasons. That would mean that your database is open for the script kiddies of the world to attack, and that your database credentials are embedded in an APK for anyone to extract. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy Warescription: Three Android Books, Plus Updates, One Low Price! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en