Custom post types with date based archive

After some more searching I found this. If you register your custom post type using the function as described in the link it will add an additional date archive.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)