I use winforms to develop a desktop application, and right now I plan to use SQL server express, but the problem is, if i use sql server express, then the installation is much trouble, i need to install sql server first, and install my own applicaiton.
Then I tried to use access 2003 as my database, then I only need to copy the mdb file with my application. But the access 's function is not that strong, the text length is limited to 255 byte.
Is there any other database solution, which is easy to integrate to my application, and easy to install after i develop my application ?
Many many desktop application have their own database, and easy to install and easy to use, what database do they use ?
SQLite. Extremely robust and easy to work with, and has C# bindings. It is now the most widely deployed embedded database. The DLL is under 300Kb.
Use SQL Server Compact Edition (CE). It's free, and comes with Visual Studio. It's file-based, but can easily synchronize with a "real" SQL Server database.
I was going to post a list of links to SQL CE information, but I found too many good links with the following search: http://social.msdn.microsoft.com/Search/en-US?query=sql+server+compact+edition.
you can try Non-Sql db, like Db4o, it's:
easy to set up
easy learning curve
C# native
Object oriented
Light weight
Related
I have been given the tasking of providing a desktop solution which allows a user to simply and safely create bespoke reporting queries where their knowledge of the database is limited.
Immediately what came to mind is the SQL server query designer in SSMS. I have searched the internet with no success of whether this can be integrated into a C# Windows Forms application. Has anyone had any success of invoking this functionality in C#?
I used to work with Korzh's EasyQuery component in ASP.NET MVC, but they have the WinForms edition too.
It seems like exactly what you need - the database structure is hidden, end user operates with visual "conditions" and "columns", you get an SQL query as a result.
Here is the link: http://devtools.korzh.com/easyquery/
I'am programming a Windows 8 Store App (Metro Design) with C# and XAML using Visual Studio 2012.
There is no need for a database server with multi user support etc.
I want to store my data in a local database and don't know which database is suitable for my needs.
Maybe SQLite? Or are there solutions that fits better for Windows Store Apps and integrates better in Visual Studio?
The app is kind of a calender and the database should store the user data that consists of the dates, tasks and so on.
SQLite is supported for WinRT.
http://visualstudiogallery.msdn.microsoft.com/23f6c55a-4909-4b1f-80b1-25792b11639e
SQLite is the recommended database to be used for Win 8 Apps.
Links for implementing the same
http://timheuer.com/blog/archive/2012/08/07/updated-how-to-using-sqlite-from-windows-store-apps.aspx
http://code.msdn.microsoft.com/windowsapps/Using-SQLite-Asynchronously-b8372137
https://visualstudiogallery.msdn.microsoft.com/23f6c55a-4909-4b1f-80b1-25792b11639e
Ok, this is a great question that I had to learn the hard way. By default WinRT applications do NOT have access to, directly at least, to any type of database structure. This means no Express, Compact, CE, SQLite etc.
There are three ways around this. Do not use a database and instead use a local file structure where you store and retrieve your data. XML works very nicely with this because you can maintain many of the same features a database would give you.
The second option is to use IndexedDB. It is similar to a cookie style local storage model where files are saved in your apps local apps folder.
The third and final option is to use web services. WinRT does have access to the internet which means you can write API and WebServices that can be called. This does mean that you need to have a server running which is connected to a master database. When your app needs data it calls your web service and obtains what it needs.
Overall, for the application you are describing the first option may best suite your needs. Keep a local XML file in your apps folder and read/write from it.
My question was marked as a duplicate of this question (although it was about C++ not C#). I thought I should still post my findings here. C++ apps have another alternative:
Extensible Storage Engine (ESE)
The list of all such API available for Store apps can be found on this link under the section Jet.
As one of variant:
Devart LinqConnect for Metro – a fully-functional high-performance ORM solution for developing Windows Store applications using either of LINQ or ADO.NET to access data.
http://code.msdn.microsoft.com/windowsapps/A-Simple-Windows-Store-85f29843#content
or next link can be usefull to
http://social.technet.microsoft.com/wiki/contents/articles/18417.windows-store-app-with-a-sqlite-database.aspx
Basically all I want is to be able to create like a self contained database in my Windows Forms application, I do not want to connect to a server or anything like that with SQL Server, I just want like a small database in the application that can handle a few transactions.
Like for instance if I create a Windows Forms application then it would have its own small database in it and when deploying it.. it will save rows there and stuff. I remember hearing about a plug in, it started with a CT or something don't recall, but it would be a plugin for Visual Studio.
Any help would be much appreciated.
Regards
You can use SQL Server Compact or SQLite (ADO.NET provider is available here). Both are embedded database engines that run in-process. You don't need to install anything, just include the appropriate DLLs with your application.
Visual Studio has no problem providing you with just such a database. Just right click your project, add new item, and select SQL Server Database. The database created will be part of your project and can be deployed as needed.
If you have a limited amount of data you can just right-click the project and Add a DataSet. Then you can define multiple tables in the .xsd and store multiple rows. in the .xml. Then you can write some simple code in the .xsd code-behind to auto load and save defaults and even pull back rows of data. I typically use this approach for storing a single record in each table. It will also work with multiple records in each table. There's a point where if you start to get a lot of data you'll probably wish you had used something like SQL Compact Edition or something similar that you bundle with your app.
you can use sqlLite,this is the website
http://www.sqlite.org/
or you can use access too
So I'm using C# 2010 Express and wondering what the best toolset is for developing a C# project with a MySQL backend? I know what if you use SQL Server Compact edition from within C# it will let you access the DB directly from the IDE. Is there a similar way to integrate the development with a remote MySQL Database?
Also, is MySQL a versatile enough solution for writing a program with C#? I am looking to build a seperate PHP web site (a reporting portal) that will access the MySQL data. I'd love to go open source all the way, but it seems like C# is the best app to create the app I'm trying to create (touch screen interface for data entry).
Whenever I program a database related homepage I always use HeidiSql and mysql. Both of them are easy to figure out and fast to use.
From their site:
HeidiSQL is a lightweight, Windows
based interface for MySQL databases.
It enables you to browse and edit
data, create and edit tables, views,
procedures, triggers and scheduled
events. Also, you can export structure
and data either to SQL file, clipboard
or to other servers.
All you do is install Mysql, set up a pass and username. and it's up and running.
Then all that's left is to install Heidisql. Heidisql it is a free program. If you need more details on how to attach heidi to your database please do write again.
There is
http://www.devart.com/dbforge/mysql/fusion/
But it's not free and is a plugin which you can't use with Express. There is no way to do this with Express as you can't add onto the basic functionality.
This might be a stupid question but I'm new at all this.
I want to create a Windows program that communicates with a database. Is there any way to do this without the user of my program have to install a database program like MySql?
I'm going to program it in C#.
You can use embedded databases like SQLite or Firebird Embedded.
You can find the full list of embedded database solutions on wikipedia page
SQL Server Compact works for you. But it doesn't support some functionalities. But you don't need to install a seperate database server. It works embedded.
Since you mention MySQL: MySQL Embedded Database
(It's not free, though.)