Moving an SQL database to LiveCode
Posted: Fri Jan 28, 2011 6:27 pm
Hi,
I run a small business and I control my time bookings, invoicing and expenses in an application I wrote in RealBasic. One of reasons I moved from Realbasic to RunRev was the lack of any simple report generation in Realbasic - when creating a report I have to keep track of where everything is on the page which makes updating my reports slow and error prone. The application, which is called Time&Expense uses an SQL database with 5 data tables to store company and client information. While SQL is powerful it is overkill for my small business and quite difficult to maintain. However one of the strengths of Time&Expense is that the data is completely separate from the application code and this feature allows the application to be updated while leaving the data intact.
When I port my application to Livecode I plan to use its built-in data storage capabilities rather than an external SQL database as my data tables are very small. I wish to maintain the data in a separate data file so that it is possible to simply perform data ups: this file could be either a TSV or similar file opened on start-up or possibly a sub-stack. I have searched the forum for advice and found the following:
Richard Gaskin wrote last October:
Thanks for reading,
Simon
I run a small business and I control my time bookings, invoicing and expenses in an application I wrote in RealBasic. One of reasons I moved from Realbasic to RunRev was the lack of any simple report generation in Realbasic - when creating a report I have to keep track of where everything is on the page which makes updating my reports slow and error prone. The application, which is called Time&Expense uses an SQL database with 5 data tables to store company and client information. While SQL is powerful it is overkill for my small business and quite difficult to maintain. However one of the strengths of Time&Expense is that the data is completely separate from the application code and this feature allows the application to be updated while leaving the data intact.
When I port my application to Livecode I plan to use its built-in data storage capabilities rather than an external SQL database as my data tables are very small. I wish to maintain the data in a separate data file so that it is possible to simply perform data ups: this file could be either a TSV or similar file opened on start-up or possibly a sub-stack. I have searched the forum for advice and found the following:
Richard Gaskin wrote last October:
I am interested in how Richard's schema operates with a non-IDE version of the code, for instance is it a case of using a compiled/built main splash stack and having all the other stacks including those holding data as substacks thus allowing the subs stacks to be updated by the running application? If this is the way to go how would you advise implementing a 5 table structure; all the tables on one card, one table per card, one table per stack or some other cunning way?For documents, while I often use stack files for data storage because of the convenient efficiency of custom properties for storing stuff, I usually use it for storage only, with any views showing that data implemented as substacks of my app mainstack. This lets me update the user interface at any time without affecting the user's data files.
That's a whole other story we can get into later.
Thanks for reading,
Simon