WPF Application with Database
i would like to or need to use a database for my wpf project. It has to store "person" "team" "goals" and maybe 2 more things, nothing 开发者_StackOverflow中文版very big. Ive already used (worked) with databases in java / php (postgresql), but is there maybe an "easier" way to store the things.. i mean if the db is going to be big than i could use (postgre or mysql), but this one would be small.
You could use XML or binary serialization, but if your items are related to each other, then a relational database (like some flavour of SQL) would likely be easiest to manage.
If you don't want the overhead of running and supporting a database server, take a look at System.Data.SQLite.
Well there are lots of options for storing your application data. Your choice will depend on things like whether multiple users need to access the same data store, whether you want to use stored procedures and SQL, what kind of security you need. I think the two most obvious options are:
- Serialize your objects to XML or binary. Have a look at Karl Shifflet's "Stuff" application video tutorials which includes one showing how to make a local data store
- Use a light-weight database like VistaDB or SQL Server Compact edition
精彩评论