- Messages
- 1,420
- Reaction score
- 46
- Points
- 48
I am currently working on an extensive online application and I am looking to implement the javascript local database storage. However, I have run into quite a substantial problem; the javascript requires a SQL file to import data into the local database from the server database. I currently have the server database complete, but I cannot figure out a way of sending the sql table data from the server to the user's computer (It is not a security critical table, so it is fine to be stored in the user's browser and the table is relatively small). The idea of this is to reduce loading times when just doing a quick search.
The main issue here is the inability to use mysqldump or 'outfile' on the server to create a sql file that I could then read with javascript. Basically, what I am searching for is a solution that will let me parse a mysql table on the server into a sql file on the server, similar to the export function in phpmyadmin. The phpmyadmin export function is not a possible solution as the table updates with fresh data automatically once an hour.
If there is no viable solution, then it is likely I will have to create a completely custom script, so obviously it would be easier to check that there isn't any simpler ways of doing it first.
The main issue here is the inability to use mysqldump or 'outfile' on the server to create a sql file that I could then read with javascript. Basically, what I am searching for is a solution that will let me parse a mysql table on the server into a sql file on the server, similar to the export function in phpmyadmin. The phpmyadmin export function is not a possible solution as the table updates with fresh data automatically once an hour.
If there is no viable solution, then it is likely I will have to create a completely custom script, so obviously it would be easier to check that there isn't any simpler ways of doing it first.