Intelligent association typing

Should allow associations to automatically create foreign keys of the
same time as the primary key(s) of the model they reference. Has the
side-effect of also allowing associations to automatically create the
required foreign keys for models which have multiple primary key fields.

This change requires the support of an updated version of node-sql-query
which provides multi-condition join support.
See https://github.com/dresende/node-sql-query/pull/14