# Errata chapter 6

**URL:** <https://forums.kodeco.com/t/errata-chapter-6/47376>\
**Category:** Server Side Swift with Vapor\
**Created:** [August 26, 2018, 10:22am UTC](https://forums.kodeco.com/t/errata-chapter-6/47376 "2018-08-26T10:22:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![hammerhead](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/hammerhead/32/110937_2.png) [@hammerhead](https://forums.kodeco.com/u/hammerhead)\
**Post date:** [August 26, 2018, 10:22am UTC](https://forums.kodeco.com/t/errata-chapter-6/47376/1 "2018-08-26T10:22:15Z")

</div>

Pg 109

the constructor for MySQLDatabaseConfig requires a port number so instead of:

let databaseConfig = MySQLDatabaseConfig(  
hostname: “localhost”,  
username: “vapor”,  
password: “password”,  
database: “vapor”)

it should be:

let databaseConfig = MySQLDatabaseConfig(  
hostname: “localhost”,  
port: 3306,  
username: “vapor”,  
password: “password”,  
database: “vapor”)

Otherwise it doesn’t compile.

---

<div class="post-metadata">

**Author:** ![0xtim](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/0xtim/32/111111_2.png) [@0xtim](https://forums.kodeco.com/u/0xtim)\
**Post date:** [August 29, 2018, 3:04pm UTC](https://forums.kodeco.com/t/errata-chapter-6/47376/2 "2018-08-29T15:04:44Z")

</div>

Hi @hammerhead you shouldn’t need the port, it should have a default value, a la [https://github.com/vapor/mysql/blob/master/Sources/MySQL/Database/MySQLDatabaseConfig.swift#L35](https://github.com/vapor/mysql/blob/master/Sources/MySQL/Database/MySQLDatabaseConfig.swift#L35)

If you run `swift package update`, regenerate the project and try again does it still happen?
