How can I detect from the controller which database adaptor is in use?

I’m using Postgres in development and MySQL in production. They use
different SQL syntax in some places in my code.

How can I detect from the controller which adaptor is in use?

I’ll be migrating the production site to Postgres, so switching to
MySQL in development isn’t an option.

Thanks,
Jose

On Jan 8, 2:40 am, HG [email protected] wrote:

I’m using Postgres in development and MySQL in production. They use
different SQL syntax in some places in my code.

How can I detect from the controller which adaptor is in use?

Got it. Model#connection.adapter_name