小型个人应用程序的最佳数据存储方法(SQL 数据库、XML 或其他文件类型)
我在这里对 SO 做了一些研究,但还没有找到我真正需要的东西。 我目前正在学习 C++,以帮助我的公司将 MSSQL Delphi 驱动的应用程序转换为 C++。为了帮助促进我的学习,我正在开发一个供我家庭使用的个人应用程序。因为我真的不认为我需要数据库的力量,所以我正在寻找其他方法来存储数据。如果您知道该程序将做什么,这可能有助于回答我的问题。
它是什么:家庭预算、医疗和规划申请。
我想用它做什么:而不是将预算电子表格、PDF 医疗文档和其他面向家庭的数据以无组织的方式保存在拇指驱动器上。我想构建一个具有多种工具的前端。
我希望能够存储和访问一般个人信息、完整的家庭医疗记录(包括糖尿病跟踪工具,例如每日血糖数值和注射的胰岛素)、预算信息、当前/历史账单信息(账户编号、应付金额、已付款、截止日期等)数据以及我能想到的任何其他数据,以使我的个人数据更有条理。我还计划能够打印报告并为这些数据制作图表。我可能希望加密数据,但目前我不确定。
现在我知道实际的 sql、mysql 或进度数据库对于这个项目来说绝对没问题,但是我真的希望使用其他可能更小、更简单的东西。 XML 是一个有效的选择吗?是否有其他文件类型可以用来存储所有数据。我正在寻找一个占地面积小、能够快速访问并且能够对数据执行“按摩”的产品。
I have done a little research here on SO and haven't found exactly what I was needing.
I am currently learning C++ to help transition my companies MSSQL Delphi driven application over to C++. In order to help facilitate my learning I am working on a personal application for my home use. Since I don't really think I will need to power of a database I was looking at other methods to store data. It may help answer my question if you know what the program will do.
What it is: Family Budget, medical and planning application.
What I want to do with it: Instead of keeping budgeting spreadsheets, PDF medical documents and other family oriented data on a thumb drive in an unorganized manner. I want to build a front-end that has multiple tools.
I want to be able to store and access general personal info, full family medical records (including diabetic tracking tools such as daily glucose numbers and insulin delievered), budget information, information on current/historical bill (account #'s, amounts due, paid, due dates, etc) data and really anything else I can think of to make my personal data more organized. I also plan to be able to print reports and make charts and graphs for this data. I may wish to encrypt the data but I am unsure at this time.
Now I know that an actual sql, mysql or progress database would be absolutely fine for this project, however I really wish to use something else that may be smaller and simpler. Would XML be a valid option? Are there other file types out there that I could use to store all the data. I am looking for a small footprint, with quick access and the ability to perform "massaging" on the data.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
使用 SQLite。它为您提供了 DBMS 的大部分功能,包括 SQL-92 的大部分完整实现,但完全嵌入到您的应用程序中,并且没有安装占用空间。
对于 C++,有几个可用的库将 OO API 包装在相当原始的 C 接口周围。请参阅这个问题获取建议。
甚至不要考虑使用 XML。数据库是存储您正在使用的信息的完美场所。
Use SQLite. It gives you much of the power of a DBMS, including a mostly complete implementation of SQL-92 but is completely embedded in your app, and has no installation footprint.
For C++, several libraries are available that wrap an OO API around the fairly RAW C interface. See this SO question for recommendations.
Don't even think about using XML. A database is the perfect place to store the kind of information you are working.
SQLite(如 Marcelo 推荐)或 SQL Server CE(如果您将使用 .NET)
SQLite (as Marcelo recommends) or SQL Server CE (if your will use .NET)