What is the best method for embbeding a database in an app ?
I mean hard coding it, a database that will never change. I do not want a file outside like an SQLLite or something else. I want it as a multidimensional variable inside the app, but the database is huge.
I am willing to create an app to convert it to standard code if needed. Maybe even crypted.
Thanks
The terms “huge” and “embedded in memory” are conflicting. Are you sure that an external DB is not a solution for your case? That external DB can be encrypted.
When I mean huge is not file size, it is many columns and rows. Too much for copying and pasting, but not large enough for embedding
What’s the current format of this data? Excel? SQLite? Yet to be typed?
Your usual option would be an Array.
Yes, but is there an app, script or something to create this array ? That’s my question. If not, I may create one.
Voc conhece a piada do Brasileiro que ia viajar para a Inglaterra mas estava temeroso por no saber Ingls, e ento o amigo capiau dele falou: “Besteira! Fala em Portugus devagar que eles entendem tudo!” ?
You can create an in-memory SQLiteDatabase if you like. Just instantiate one, keep DatabaseFile nil, and Connect. As for populating it… When you build a GUI app with Xojo on any platform, it will always have a folder structure to include libraries and resources. You could stick a text file of SQL commands in a file and place it in one of those folders. In app.Open, find the file, open it, run the SQL commands.
He doesn’t want external content and his data is just a matrix.