MS SQL 挑战问题
程序员文章站
2022-06-12 19:24:06
...
SELECT T. ROW , T.PRODUCT_NAME, T.SALE_AMOUNT, T.SUM_RAT FROM (,T.PRODUCT_NAME,T.SALE_AMOUNT,( SELECT SUM (SALE_AMOUNT) SUM_SALE FROM TEST WHERE T.SALE_AMOUNT = SALE_AMOUNT) / L.SALE_AMOUNT AS SUM_RAT FROM TEST T, ( SELECT SUM (SALE_AMOUNT
SELECT T.ROW, T.PRODUCT_NAME, T.SALE_AMOUNT, T.SUM_RAT FROM ( , T.PRODUCT_NAME, T.SALE_AMOUNT, (SELECT SUM(SALE_AMOUNT) SUM_SALE FROM TEST WHERE T.SALE_AMOUNT AS