stephencelis / SQLite.swift

A type-safe, Swift-language layer over SQLite3.
MIT License
9.57k stars 1.55k forks source link

Require a basic example project #583

Open sicaboy opened 7 years ago

sicaboy commented 7 years ago

Require a basic example project. I hope this lib can be friendly to beginners. I hope someone could write a iOS project in swift demonstrate how to insert, delete, query rows in a real iOS project.

Like what they did: https://github.com/FahimF/SQLiteDB/tree/master/Examples/iOS

gennaios commented 7 years ago

Agree a sample or updated docs would help. I've used the project in two apps but am still a beginner and now trying again, I get confused with the various ways to get data and then do something with the results. For example, db.prepare(table.filter(…)), table.filter(…), …update(…), when columns can be subscripted and when they can't, etc. The docs help a bit but somethings like looping over an entire table might be used less than accessing column values of a filter, and an update could help.

Another example, soon I'll be trying date values, and looking over the docs, there's an extension, talk about treating dates as int, and then a recommendation of using the text extension, of which I'm not clear if it's the one first mentioned or another.

rajesh-loganathan commented 5 years ago

Here is the example project for ios sqlite in swift language. I just created a wrapper class to make simplify the implementation with easy understanding.

Source Code: https://github.com/svmrajesh/SwiftSqlite.git

jberkel commented 2 years ago

What would be a good example project? I was thinking more along the lines of a small CLI app, also executable on Linux