Created
April 11, 2018 20:45
-
-
Save edersqo/aadfcd4bbd9bdbc3e382e03915665900 to your computer and use it in GitHub Desktop.
Gets all Prices Stored at DCS_PRICE, and checks if it is the one -- pointing to the publishing schema.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT | |
* | |
FROM | |
( | |
SELECT PRICE_LIST, SKU_ID, COUNT(*) | |
FROM WLM_PROD_CATA.DCS_PRICE | |
GROUP BY | |
PRICE_LIST, SKU_ID | |
HAVING | |
COUNT(*) > 1 | |
) CATA_PRICE | |
LEFT JOIN | |
( | |
SELECT | |
IS_HEAD, | |
VERSION_DELETED, | |
CHECKIN_DATE, | |
PRICE_ID, | |
PRICE_LIST, | |
SKU_ID | |
FROM WLM_PROD_PUB.DCS_PRICE | |
) PUB_PRICE | |
ON | |
CATA_PRICE.PRICE_LIST = PUB_PRICE.PRICE_LIST | |
AND CATA_PRICE.SKU_ID = PUB_PRICE.SKU_ID; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment