Multi-Environment Config using port in database server
Try using a port variable:

'STAGING' =&gt; array(
    'server' =&gt; 'localhost',
    'port' =&gt; '3939',
    'user' =&gt; 'myusername',
    'password' =&gt; '***********',
    'database' =&gt; 'mydatabase',
),