How would I create a searchable database?
For example, a number of items would be added to a list created at runtime.
I would like to implement it into the interface so when the search_database() verb is called it would output the results of which items from the list include the text from the input.
Not sure where to start looking.
Jan 16 2015, 10:34 pm
|
|
What do you want to store in the database? Also, do you want to store it in a text file?
|
I want to store objects in the list that output as their image file. Then I would make a save system for the list.
|
This is how I would do it. Database is a list which you can add() and remove() things from. When you do, it automatically saves an updated copy of itself.
To make a new database you give it a file name. var/Database/myDatabase = new/Database("Database") If a file already exists with that name then the new database object will read the file and turn itself into that database. Database |
I highly recommend using the /database system that BYOND provides. It uses SQLite (you can Google SQLite syntax) to store data in a very robust format that includes powerful search systems.
|