MarschOSX / Responder

Senior Design I project for an Android auto-response application
0 stars 0 forks source link

Retrieving Database Results Issue #30

Closed gabowser closed 8 years ago

gabowser commented 8 years ago

Was unable to retrieve results from the Cursor object returned from a rawQuery() to the database, would always return an index out of bounds error even though the index was correct

gabowser commented 8 years ago

Determined that the cursor by default is pointing to the header/title row, before trying to retrieve results row, must move pointer to the next row via Curstor.moveToFirst() or other equivalent Cursor function calls.

Found this at: http://stackoverflow.com/questions/18167258/android-cursor-is-always-returning-null-even-if-the-database-is-not-empty