Android Programming Tutorials

(Romina) #1
The Restaurant Store

public String getNotes(Cursor c) {
return(c.getString( 4 ));
}
}

Extra Credit................................................................................................


Here are some things you can try beyond those step-by-step instructions:



  • Download the database off the emulator (or device) and examine it
    using a SQLite client program. You can use adb pull to download
    /data/data/apt.tutorial/databases/lunchlist.db, or use Eclipse or


DDMS to browse the emulator graphically to retrieve the same file.



  • Use adb shell and the sqlite3 program built into the emulator to


examine the database in the emulator itself, without downloading
it.

Further Reading.........................................................................................


You can learn more about how Android and SQLite work together in the


"Managing and Accessing Local Databases" chapter of The Busy Coder's


Guide to Android Development.


However, if you are looking for more general documentation on SQLite


itself, such as it's particular flavor of SQL, you will want to use the SQLite


site , or perhaps The Definitive Guide to SQLite.


107
Free download pdf