M
M
MrLumusss2022-01-30 12:26:08
Database
MrLumusss, 2022-01-30 12:26:08

How to save the results of the application not in the database, but in a file?

Good afternoon Khabrovites! There is an idea for an application for my own enterprise (I myself am not a specialized programmer). I have a paper version of equipment accounting for employees, I want to convert it into a number. The idea is as follows:
There is an employee, assigned to him: a mouse, keyboard, laptop, phone, SIM card, etc.
I will make an application in which it will be possible to keep this account, I don’t want to use MSSQL or similar things, but I want the file system, because there will be no more than 60 records and I don’t see the point in the database. And so actually question: How to organize saving of 50 instances of class Employee in a file and at program opening it to read and load in application? Previously only worked with MSSQL and EF6

Answer the question

In order to leave comments, you need to log in

2 answer(s)
@
@insighter, 2022-01-30
@MrLumusss

Work with SQLite and don't make up nonsense.

R
rPman, 2022-01-30
@rPman

Once upon a time, when I wrote a project in visual studio c # winform, I used dataset classes, which are essentially tables in RAM, the entire interface is almost written with a mouse, if necessary, save data to disk to the entire dataset WriteXml and when ReadXml starts, and that's all saved and loaded ... I never even looked inside, When you write a tiny application, which in half a year you won’t even remember because it’s not necessary, why even bother with databases.
I mean, if serialization to a file, in any format, solves your problem and does not add new ones, then why not.
This simple approach saves development time with a very inefficient way of storing data.
But there is a danger that storage formats from different versions of the .net framework will not be compatible.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question