Posts

Showing posts with the label Learning

Working with SQLite in Android. Tools and stuff.

The Notepad tutorial uses sqlite to store the users entered notes. This is a single table, so this method query(String table, String[] columns, String selection, String[] selectionArgs, String groupBy, String having, String orderBy)  was fine. It takes a single table name and some params for the other clauses. To use more than one table I used the rawQuery(String sql, String[] selectionArgs) method. This takes arbitrary sql (union in my case) along with values to bind to any ? that you used. I have removed the SQLiteOpenHelper from the code also. This opens and creates your database and handles upgrading the database following schema changes. Overall I found this cumbersome and have switched to moving the database file from the device (emulator) to my pc. I then query it using SQLite 2009 Pro. I got it here . Excellent query analyzer type tool. I make my changes here (schema and data) and then push this back to the device when I am ready to test with the app. The pushing is...

Steps to learn Android

As you can see if you have read any of the other posts on this blog I am in the process of learning Android. I am going to keep a running list of the steps that I am taking to do this. Check this out every day. See what is being discussed. May even give a try at answering something for someone: http://stackoverflow.com/questions/tagged/android Check this every day also: http://android-developers.blogspot.com/ I subscribed to this one in Google Reader. Learn sqlite .