Convert oracle SQL statement to MySQL
Good day. I am converting an oracle database to a mysql database. One of the scripts that is currently running on the oracle system is as follows:
UPDATE AR_CUST_MASTER a
SET ARCM_SHORT_NAME =
(SELECT ARCM_SHORT_NAME
FROM AR_CUST_MASTER b
WHERE b.ARCM_CUSTOMER_NO =
LPAD (
TO_CHAR (TRUNC (a.ARCM_CUSTOMER_NO / 1000) * 1000),
9,
'0')
AND MOD (b.ARCM_CUSTOMER_NO, 1000) = 0
AND a.ARCM_COMPANY = b.ARCM_COMPANY)
WHERE MOD (a.ARCM_CUSTOMER_NO, 1000) != 0;
I am having issues converting this to mySQL. Any help would be greatly appreciated.
Kind Regards,
supersobbie
Subject
Views
Written By
Posted
Convert oracle SQL statement to MySQL
5559
November 06, 2012 02:54PM
2480
November 10, 2012 06:42AM
2290
November 15, 2012 08:45AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.