I ended up relying on the approach I used in webOS (and that Samuel M
reiterated above) -- loading a JSON file into an SQLite database, then
using SQLite query syntax to extract data when I need it. I haven't
tested it yet on an iPhone, but it works fine in the iOS simulator.
At one point in my testing I was able to get the alternative approach
to work -- creating an SQLite database outside the iPhone environment,
then renaming it (as Nick suggests above) and copying it into Xcode.
But I couldn't retrace my steps successfully a second time, so I went
back to the JSON approach. Works for now, and I'm comfortable with
it, so that's what I'll do going forward.
On Jan 13, 6:58 pm, Ricardo Andrade <
gvainformat...@gmail.com> wrote:
> Hi There, I did the same examplehttp://
docs.phonegap.com/phonegap_storage_storage.md.html,
> and I get erro "no such table: DEMO", Anyone has suggestion ? :-(
>
> Best regards,
>
> Randrade
>
> On 11 ene, 03:30, ben ben <
wangdybyt.hea...@gmail.com> wrote:
>
>
>
>
>
>
>
> > i get the same issue as sromalewski,i use web database (html5 special)
> > to store my data , and success in one page , when i access the
> > database in another page using "window.openDatabase" "select * from
> > userInfo" , LogCat feedback to me the error "sqlite returned:error
> > code = 1,msg = nosuchtableuserInfo", so anyone can give me some
> > suggestion ? thanx
>
> > On Jan 7, 6:37 pm, Giacomo Balli <
giacomoba...@gmail.com> wrote:
>
> > > or you just copy and paste ObjC code to access/edit thedband make it
> > > a plugin.
>
> > > On Jan 6, 10:54 pm, Nick McCloud <
n...@descartes.co.uk> wrote:
>
> > > > You can pre-populate the database - you just have to give it the names
> > > > that iOS needs to access it via HTML5 as per the posting you
> > > > referenced. It is as simple as not just using the names you want to
> > > > use.
>
> > > > On Jan 6, 7:39 pm, sromalewski <
spatialitya...@gmail.com> wrote:
>
> > > > > Thanks for your responses.
>
> > > > > My expectation that you couldpreloadan SQLite database came from
> > > > > > You can't just copy over any sqlitedbof your choice. You are best
> > > > > > off creating the database using HTML5/JS on your machine, which you
> > > > > > can then populate via SQLite Manager. You'll need to leave the name
> > > > > > alone (yes, all those 00000's!) and you will have to copy over the
> > > > > > database.dbas well. The HTML5 database access is firewalled - you
> > > > > > can't just directly open your own database. Re-read the first posting
> > > > > > you refer to and you'll see the details of what I'm talking about.
>
> > > > > > On Jan 5, 9:27 pm, sromalewski <
spatialitya...@gmail.com> wrote:
>
> > > > > > > I'm porting a webOS app over to iPhone, using PhoneGap and Jquery/
> > > > > > > JQTouch to do so. I've run into a problem, though, with an SQLite
> > > > > > > database that is stumping me from the start.
>
> > > > > > > My app displays local, officially designated landmarked buildings in
> > > > > > > various cities in the US. In webOS, I'd include a JSON file with the
> > > > > > > landmark info (name, date designated, etc), then Ajax that in to an
> > > > > > > SQLite database and run queries against the database to display info
> > > > > > > in the app. In webOS that works fine, though Ajax'ing it in is an
> > > > > > > extra step.
>
> > > > > > > It seems that with iPhone you canpreloadan SQLite database with the