Modified the SQLite query when select rates from the given currency