title: How read data from sqlite with SQLite.swift?
body: <p>I want to build a Dictionary app for iOS. I try to read data from sqlite database file with SQLite.swift <a href="https://github.com/stephencelis/SQLite.swift" rel="nofollow noreferrer">here</a>. </p>
  
  <p>My code</p>
  
  <pre><code>func configureCell(){
      //Todo: read sqlite file
      //let path = Bundle.main.path(forResource: "taidict", ofType: "sqlite")!
  
      do{
          let path = Bundle.main.path(forResource: "taidict", ofType: "sqlite")!
  
          let db = try Connection(path, readonly: true)
          let users = Table("words")
          let id = Expression&lt;Int64&gt;("id")
          let word = Expression&lt;String?&gt;("word")
          let shanword_uni = Expression&lt;String&gt;("shanword_uni")
  
          for user in try db.prepare(users.select(id, word, shanword_uni)) {
              print("id: \(user[id]), word: \(user[word]), meaning: \(user[shanword_uni])")
              // id: 1, email: alice@mac.com
          }
  
  
      }catch{
          print(error)
      }
  
  }
  </code></pre>
  
  <p>When I try to run, I have got an error like below.</p>
  
  <pre><code>    2017-10-03 21:59:57.826502+0630 TaiDict[60682:516343] [MC] Lazy loading NSBundle MobileCoreServices.framework
  2017-10-03 21:59:57.827558+0630 TaiDict[60682:516343] [MC] Loaded MobileCoreServices.framework
  2017-10-03 21:59:57.841476+0630 TaiDict[60682:516343] [MC] System group container for systemgroup.com.apple.configurationprofiles path is /Users/saitanwgpha/Library/Developer/CoreSimulator/Devices/BA4F6AD0-6C4D-4F29-B0E0-34B9F63607A0/data/Containers/Shared/SystemGroup/systemgroup.com.apple.configurationprofiles
  fatal error: 'try!' expression unexpectedly raised an error: Unexpected null value for column `"id"`: file /Library/Caches/com.apple.xbs/Sources/swiftlang/swiftlang-900.0.59/src/swift/stdlib/public/core/ErrorType.swift, line 181
  2017-10-03 21:59:57.870943+0630 TaiDict[60682:516343] fatal error: 'try!' expression unexpectedly raised an error: Unexpected null value for column `"id"`: file /Library/Caches/com.apple.xbs/Sources/swiftlang/swiftlang-900.0.59/src/swift/stdlib/public/core/ErrorType.swift, line 181
  Message from debugger: The LLDB RPC server has crashed. The crash log is located in ~/Library/Logs/DiagnosticReports and has a prefix 'lldb-rpc-server'. Please file a bug and attach the most recent crash log.
  </code></pre>
  
  <p>How should I fix it? Please help me.
  Best,
  Sai Pha</p>