Use existing SQLite database

Put your problem here if it does not fit any of the other categories.

Use existing SQLite database

Postby chitgoks » Tue Mar 11, 2008 8:22 am

hi

is android capable of using an existing SQLite db file?
i dont want to do creation when the app is ran because i have existing data to put in the db and have the app use right away once it's installed in the emulator

so if it's possible, once i compile my project, which folder should i place the physical db file? and does the packager automatically place the db file in its appropriate directory?

the notepad example's code doesnt have this kind of sample.

thanks
Website/Java Games: http://www.chitgoks.com
Blogs:
http://tech.chitgoks.com
http://wuhtevah.chitgoks.com
http://disneyusa.blogspot.com
chitgoks
Developer
Developer
 
Posts: 36
Joined: Tue Mar 11, 2008 3:06 am

Top

Postby res » Sat Mar 15, 2008 11:02 pm

Use the res/raw directory, android doc link http://code.google.com/android/devel/re ... -i18n.html
res
Senior Developer
Senior Developer
 
Posts: 146
Joined: Tue Nov 20, 2007 8:14 pm
Location: United States

Postby felix » Mon Mar 17, 2008 6:17 pm

Use the DDMS perspective and search in data\data\your_package\database amd put your db inside this folder. It's works fine

:)
felix
Junior Developer
Junior Developer
 
Posts: 18
Joined: Thu Feb 14, 2008 4:25 pm
Location: Brasil

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: Exabot [Bot] and 16 guests