I need to initialize a variable to connect to an SQLite database in Swift. I am using the SQLite.swift library and need to connect to the database with this line:
let db = try Connection("path/to/db.sqlite3")
However, this line by itself will not…
I'm using sqlite.swift in my Swift project. Until now I'm using Cocoapods to install/update the library.
Is it possible to install sqlite.swift with Carthage insted of using Cocoapods?
I'm writing some tests to see if a person object is correctly saved into a local database (SQLite, using strings for the dates).
in my tests I have :
let testPerson = Person(firstName:"John", lastName:"Doe")
After saving to the database I test if…
I am trying to insert data from array into my table. If the insert is done I think, its suppose to print it in the console, but it is not. So I tried db.trace(println) and it shows me
SELECT * FROM "formatedData1"
My createDatabase function:
…
I'm trying to use sqlite.swift in a small app I'm developing, but I'm new to Swift and SQLite. I used CocoaPods to install sqlite.swift. I used these commands:
sudo gem install cocoapods
pod setup --verbose
I then navigated to the directory for my…
I detect whether a connection exists on a Singleton instance and if it doesn't it will open up a new connection on app start up. However, ideally I'd like for the open function to fire when the Singleton is first created without having to explicitly…
I have this function that initializes a database (basically copied from the documentation of SQLite.swift).
func createDB() {
let paths = FileManager.default.urls(for: FileManager.SearchPathDirectory.documentDirectory, in:…
I use like with lowercaseString and Russian symbols but LOWER doesn't convert them to lowercase in the query. I tried to create my own function but it didn't work for me. How to solve this problem?
Having studied the documentation of SQLite, I…
After upgrading to Xcode 12 / iOS 14 my project is no longer compiling/importing the SQLite3 library because it is previously defined in the iOS 14 usr/include.
Is this something that I can fix in my build settings? Can I remove it from the…
I was wondering, does SQLite.swift have the capability, to detect & notify table data change?
(Similar to what is offered by NSFetchedResultsController, to detect & notify entity data change)
For GRDB.swift, it offers the capability to observe…
I am using SQLite.swift and I would like to represent a SQL statement with multiple dynamic filter conditions in the type safe API. I have found similar questions, but none of them provided any insights on how this might be possible.
So far I would…
I am using SQLite.swift to connect to a database but am getting "Missing required module 'SQLiteObjc'" on the import of SQLite.
I believe I have connected it properly.
Here is another screenshot I took. It seems to be reading the SQLiteObjc module…
I am using SQLite.swift and I want to insert an UIImage in a column of type 'blob'.
My table:
"CREATE TABLE IF NOT EXISTS " + TABLE_USER +
"(" +
COLUMN_ID + " INTEGER PRIMARY KEY, " +
…
I'm using SQLite.swift and SQLCipher via cocoapods.
I get the error ambiguous use of 'SQLITE_DETERMINISTIC' in the SQLite.swift file: Connection.swift fails at line 590. Snippet is show below.
var flags = SQLITE_UTF8
#if !os(Linux)
…