开发者

What is the android_metadata table?

I try to integrate an existing database file into my Android project. I follow the instructions on this blog. They write that I have to add a table android_metadata with a column called locale and put en_US into it.

I try to figure out what this table is used for. Because my database content is german. Ma开发者_运维问答ybe i then should not put en_US into it? Is this required for localisation of the database content or is the table not needed at all?


the metadata table will be generated automatically. if you have content of german try updating the metadata table 'de_DE'.


If you're okay opening the DB with read-write access then you can let the openDatabase(...) call automatically generate it. For example in Android:

SQLiteDatabase.openDatabase(m_szMainDBPath, null, SQLiteDatabase.OPEN_READWRITE);


The metadata table is required to hold (as its name suggests) meta information about the application. This table is auto-generated in some cases (since api 4 if i remember correctly) but you may want to add it yourself.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜