I am new to SQLite database. What I know currently is SQLite is a small and lightweight standalone database file that we can use without the windows/SQL authentication (correct me if I'm wrong). I have done research on .mdf file which I don't know whether it belongs to the SQLite. And most of the SQLite tutorial online is only for ASP.NET Core, how about ASP.NET MVC? My ASP.NET MVC project is currently published to IIS, so I need the SQLite Database can be published along, and also no need to set up SQL Server or any related setup in IIS. Anyway, I have no idea how to start. Appreciate if someone can provide me some tutorial link? Or even the most simplest example. Thanks in advance.
1 Answers
I am new to SQLite database.
What I know currently is SQLite is a small and lightweight standalone database file that we can use without the windows/SQL authentication (correct me if I'm wrong).
You are correct - however not needing to worry about authentication is not the main reason people use SQLite.
I have done research on .mdf file which I don't know whether it belongs to the SQLite.
With respect, you haven't done enough research: .mdf
files are specific to Microsoft SQL Server and not SQLite. SQLite does not have a defined file-extension but generally most people use .sqlite
.
And most of the SQLite tutorial online is only for ASP.NET Core, how about ASP.NET MVC?
"ASP.NET MVC" is an ambiguous term. But I assume you mean ASP.NET MVC 4 or ASP.NET MVC 5 for the .NET Framework, not ASP.NET Core.
As it's 2021 now, you should only use ASP.NET Core and only follow resources and guides for ASP.NET Core. If you have an existing project on ASP.NET-for-.NET Framework then the good news is that it's very easy to update.
My ASP.NET MVC project is currently published to IIS, so I need the SQLite Database can be published along, and also no need to set up SQL Server or any related setup in IIS.
You don't need to use Microsoft SQL Server at all if you're using SQLite:
- SQLite's database engine runs "in-process" (literally: inside the same OS process as your application code).
- This means you won't have any external dependencies other than the SQLite library in your project.
- Microsoft SQL Server is a dedicated server system that runs databases all the time and does nothing but run databases.
- Microsoft SQL Server and SQLite have absolutely nothing in common besides both supporting ISO SQL.
- As an aside, if anyone calls it "ANSI SQL" you should print out the ISO SQL specifications for the past 30+ years and dump them on their desks and make them read through it all: it hasn't been called "ANSI SQL" since the 1980s.
- Microsoft SQL Server and SQLite have absolutely nothing in common besides both supporting ISO SQL.
Anyway, I have no idea how to start. Appreciate if someone can provide me some tutorial link? Or even the most simplest example. Thanks in advance.
Recommending external resources is not something we do here on StackOverflow.

- 141,631
- 28
- 261
- 374