clst/activerecord-sqlanywhere-adapter — comment on commit dfad24008b9c67b5c93635f2e4537101b3be04d4
File:  line 0
By clst:

Out of curiosity what dies the output of: puts Rails.configuration.database_configuration.to_yaml look like on your rails console?
Is it identical to: puts ActiveRecord::Base.configurations.to_yaml ?
If you are not using the default configurations how did you configure your rails?
Other than those the only way would be to parse database.yml directly AFAIK.