mod_swift v0.7.0 Release Notes

Release Date: 2017-02-06 // about 7 years ago
  • We prefer the Elephant, a lot. It is the right thing.

    ๐Ÿ‘ mod_swift 0.7.0 brings you support for accessing SQL database using Apache mod_dbd. Yes, Apache even includes SQL database support!

    Enough words, this is how the code looks like:

    guard let con = req.dbdAcquire() else { return ... }guard let res = con.select("SELECT \* FROM pets") else { return ... }while let row = res.next() { req.puts("\<li\>\(row[0])\</li\>") }
    

    And the config looks like so:

    <IfModule dbd_module>
      DBDriver sqlite3
      DBDParams "/var/data/testdb.sqlite3"
    </IfModule>
    

    ๐Ÿš€ The release contains a very simple/basic wrapper library to make access to mod_dbd nicer, but is far from being a complete solution. Stay tuned.