Questions tagged [grdb]

GRDB is a popular Swift library used in relation to the SQLite database. Use this tag for questions about the use of GRDB. You would likely add the Swift tag, and possibly the SQL tag.

The GRDB library is at https://github.com/groue/GRDB.swift

It is a library for use in Swift projects which deal with the SQLite database.

It particularly focusses on performance and threading.

It deals with issues such as WAL support, migrations, reactive extensions, and change observation.

Links to GRDB installation, reference.

49 questions
0
votes
1 answer

GRBD Swift Sqlite

I'm using GRDB library for Swift Sqlite. I create a class for connection: import GRDB var dbQueue: DatabaseQueue! func setupDatabase() { var config = Configuration() config.readonly = true config.foreignKeysEnabled = true config.trace = {…
glcafuni
  • 1
  • 1
0
votes
1 answer

Swift compiler 2.1.1 hang forever on dictionary

I was building a class for a sqlite library, and suddenly the compiler hang forever. I finally get a test case for it, and found is related to a dictionary parsing. This is the minimal code: import Foundation import GRDB class DeudaCliente : Record…
mamcx
  • 15,916
  • 26
  • 101
  • 189
0
votes
0 answers

GRDB Sync with nested array

I am using GRDB to sync my JSON payload to SQLite however I am encountering an error whenever I have an array of other items within the main payload. fatal error: unexpectedly found nil while unwrapping an Optional value My JSON is: { "newsData":…
puks1978
  • 3,667
  • 11
  • 44
  • 103
-1
votes
1 answer

GRDB in Swift - .fetchAll Only Ever Returns One Column

My Original Code func getUserByEmpNum(_ id: Int) -> String { let nameQuery: String = "SELECT fld_str_firstname, fld_str_lastName FROM userView WHERE fld_int_id = \(id);" var returnStr = "" do { let dbQueue = try…
Stephen Clark
  • 41
  • 1
  • 9
1 2 3
4