diff --git a/lib/extensions/ar_adapter/ar_dba.rb b/lib/extensions/ar_adapter/ar_dba.rb index 25c78f73e1fe..e44024a49122 100644 --- a/lib/extensions/ar_adapter/ar_dba.rb +++ b/lib/extensions/ar_adapter/ar_dba.rb @@ -12,11 +12,11 @@ def spid end def xlog_location - select_value("SELECT pg_current_xlog_insert_location()") + select_value("SELECT pg_current_wal_insert_lsn()") end def xlog_location_diff(lsn1, lsn2) - select_value("SELECT pg_xlog_location_diff(#{quote(lsn1)}, #{quote(lsn2)})").to_i + select_value("SELECT pg_wal_lsn_diff(#{quote(lsn1)}, #{quote(lsn2)})").to_i end def client_connections