I know there are a lot of places where I can find sqlite data types such as in this link or this other link.
Maybe this question sounds stupid when I mention version 4 because version 4 documentation is not out there on the internet or maybe I have not been able to find it. Why is it that the dll library that I downloaded from SQLite site has:
also when I downloaded that library from here (sqlite-netFx40-setup-bundle-x86-2010-1.0.79.0.exe) and install the visual studio plugins I am able to create sqlite databases in visual studio as:
Note that I have several data types!!
I am very confused on the versions of sqlite. Am I using sqlite version 3? What are the data types that I can use with the version that I downloaded from here? If I am using sqlite version 3, then why does the visual studio table designer for sqlite gives me different data types than the ones from the documentation?
Seeing as there's no such thing as SQLite 4.x (yet, anyway), you're definitely using SQLite 3.7.10. The v4.0.30319 almost certainly refers to the .NET runtime, not SQLite.
SQLite has only a few built-in types, but ADO.NET has an interface to conform to, so this adapter does its best to map the set of types you see to SQLite's (much smaller) set of native types.
Related
I just started to use OpenRefine and I wonder if there is any SQLite addon I could use.
I found a bunch of addons on main download site but SQLite is not between them.
On the other hand there is a pull on github, that claims OpenRefine to support also SQLite. I tried to load data both from "This Computer" and "Database" option and I was not able to load SQLite in neither way.
And finally I found that there is a SQLite directory with JAVA files in the github extensions folder, that might be that above mentioned support. Is this meant to be installed the easy way (just create sqlite directory inside extensions and put all the *.java files there) or do I need some other trick to achieve support on SQLite within OpenRefine?
For future reference: The SQLite importer has been added to OpenRefine in version 3.4 (https://github.com/OpenRefine/OpenRefine/wiki/Changes-for-3.4) (as Ettore Rizza already mentioned)
I try to use the SQLite in the VS2017 in a universal windows platform project. I follow the guidance to download the SQLite extension for VS2015 although my local machine environment is VS2017, maybe this is the root cause? Then I add the reference with SQLIte. After that I installed the SQLitePCL with nuget.
After the SQLite installed, I wanted to try to run a demo to see if it can work right. But I found I can't using the namespace (using SQLite.Net.Attributes;) which it necessary for my demo.
I did some search about the SQLite and VS2017, But didn't found too much about such circumstances. So I want to know if anyone ever met such problem and How can your fix that?
Or it just unavailable to using SQLite in VS2017? If yes, can I complier a newest version about this?
Thanks everyone who can give me some reply or suggestion about this issue.
But I found I can't using the namespace (using SQLite.Net.Attributes;)
It seems like SQLite.Net.Attributes is belong to the Nuget package SQLite.Net-PCL, not SQLitePCL, the one you are using. SQLitePCL does't contain SQLite.Net.Attributes. You may obtain the package that is not you attempt to use.
There're many Nuget packages for SQLite, some of them are older with long time no updating. For UWP app, I'd recommend you to follow this tutorial to use a SQLite database in a UWP app.
I can get MvvmCross working with a Windows 8.0 Store App.
I can get SQLite working with a different Windows 8.0 Store App.
I cannot figure out how to get MvvmCross + SQLite working on a Store app.
I always get this Exception:
Failed to construct and initialize ViewModel for type Flux.Core.ViewModels.TestViewModel from locator MvxDefaultViewModelLocator - check MvxTrace for more information
I've spent the entire day searching with google, hoping to solve this myself. The KittenDb example is about as close as I've come, but there's no Store app example in there. (I got the Kitten example working no problem on Android.)
Is there any working example out there?
Thanks!
SQLite for Windows Store is a C++ component and comes in separate ARM, x86 and x64 binaries.
To install it, you need to add a Visual Studio extension - instructions in http://blogs.msdn.com/b/robertgreen/archive/2012/11/13/using-sqlite-in-windows-store-apps.aspx - and then reference that extension from your UI project.
To then link the correct platform version of the Cirrious.MvvmCross.Plugins.Sqlite.WindowsStore.dll assembly to your UI project, you further need to adapt your .csproj file with a <Choose> block a bit like the one in https://nuget.codeplex.com/discussions/446656
There is an open issue within MvvmCross to make SQLite easier to use from nuget (see https://github.com/MvvmCross/MvvmCross/issues/307) but I don't know if anyone is actively working on addressing this issue currently - currently users seem to be just putting up with challenges of different processor architectures and following the manual steps to adapt their projects.
I want to use SQLite as a database for my C++ project. I also need the ability to password protect the database. I got the standard SQLite from SQLite.org working - but I need to password/encrypt the database and they don't do that - they just stub the interface for it to be done with
SQLITE_API int sqlite3_key( sqlite3 *db, const void *pKey, int nKey);
After researching on the web how to do this, I came across System.Data.SQLite. It claims to do all I need quite easily, but I need to do it from unmanaged C++ project in Visual Studio 2008. I tried their project - but I can't get my unmanaged C++ project to allow the DLL to work - it squawks about dll not being safe/clr:safe compile - which I can't set in the System.Data.SQLite project and compile.
Can anyone help me with this or point me to a good resource on how to do this? I have been thrown into a C++ project (hadn't touched C/C++ since college (97-98), so I am really struggling with this when it comes to the linker/libs/modules. Java and .NET have spoiled me!
Thanks,
Mike
You can't use a managed DLL from unmanaged code like that, they're different systems. Just use the normal unmanaged SQLite build and read the docs on how to use keys.
Recently, I've faced a similar problem like Mike and resolved it.
I would like to post my solution here in case anyone need.
I have two programs:
One is in C# to create encrypted sqlite database files using System.Data.SQLite.
The other one is in C++ to read the file created by the C# program.
After googling with no result, I looked at source code of System.Data.SQLite to figured out how System.Data.SQLite encrypts a database file.
I recognized that System.Data.SQLite uses SQLite.Interop.dll wrapping native sqlite with additional features such as encryption.
Therefore I used that native source code to build a static library. Then I use the library to read the encrypted database files.
You can find the source code at the following link:
https://github.com/OpenDataSpace/System.Data.SQLite/tree/master/SQLite.Interop/src
Update 2020/04/11
You can find a step by step guide at the following link:
https://wordpress.com/post/nguyenduyanhsite.wordpress.com/71
I'm planning to use Sqlite but I don't know how to integrate it to visual studio or use it. Any help please... thanks.
I really recommend using System.Data.Sqlite ( http://sqlite.phxsoftware.com).
Have been using it for quite some time and it works great every time! You can create tables using the designer, similar to for MSSQL etc. Recommended++
Depends on how you want to use it. The easiest is to get the amalgamation version - this version "contains all preprocessed C code combined into a single source file", meaning you have a single .h and .c file to add to your project. This is the officially recommended practice.
If you want to build a "proper" library or link against SQLite dynamically, you have a bit more work ahead, since there's no VS project/solution files included with SQLite. You'll have to set up your own library project, add the correct files from the sqlite-source-x.y.z.zip file, and set this project as a dependency on your main project. Doing this is actually officially discouraged.
EDIT:
Forgot to mention that the above solution is assuming C/C++, as OP didn't specify language.
use System.Data.Sqlite
System.Data.SQLite is an ADO.NET provider for SQLite.