问题
I have the following in Postgres 9.2.4:
postgres=# SELECT CHECKSUM(O_ORDERKEY) FROM tpch.orders;
checksum
--------------------
322119959934139382
(1 row)
Time: 41437.050 ms
I have an instance of Oracle 11g database, with the same TPCH data, which I want to check consistency with the Postgres instance by comparing table checksums. From this link https://docs.oracle.com/en/database/oracle/oracle-database/20/sqlrf/checksum.html#GUID-3F55C5DF-F23A-4B2F-BC6F-E03B34B78BA8 I found out that CHECKSUM keyword is supported only in Oracle 20c. In Oracle 11g, there are various hash functions supported, such as MD4, MD5, SHA1 etc. Can any one of that be used to get the same functionality as in Postgres checksum()? If yes, how?
来源:https://stackoverflow.com/questions/64259272/support-for-checksum-in-oracle-11g