我有这个查询
SELECT
PA.PK, PA.PACKAGE_NAME, ATTR.ENGLISH_NAME ATTRIBUTES,
PA.VALUE, ATTR_LIST.ENGLISH_NAME ATTRIBUTES_LIST
FROM
POSTS_ATTRIBUTES PA
INNER JOIN
POSTS P ON PA.POSTS = P.PK
LEFT OUTER JOIN
ATTRIBUTES ATTR ON PA.ATTRIBUTES = ATTR.PK
LEFT OUTER JOIN
ATTRIBUTES_LIST ATTR_LIST ON PA.ATTRIBUTES_LIST = ATTR_LIST.PK
WHERE
P.FIELDS = 83;
这给出了像这样的输出
PK | PACKAGE_NAME | ATTRIBUTES | VALUE | ATTRIBUTES_LIST
------------------------------------------------------------------
211| CERAMICS | RAW MATERIALS | (null) | CEMENT
212| CERAMICS | PRODUCTION OPERATIONS | (null) | PRESSING
213| CERAMICS | OPERATIONAL SERVICES | (null) | FORK LIFTS RENTAL
214| CERAMICS | FINISHED PRODUCTS | (null) | FLOOR CERAMICS
有没有办法通过查询反转列和行,使其看起来像
PACKAGE_NAME | RAW MATERIALS | PRODUCTION OPERATIONS | OPERATIONAL SERVICES | FINISHED PRODUCTS
---------------------------------------------------------------------------------------------------
CERAMICS | CEMENT | PRESSING | FORK LIFTS RENTAL | FLOOR CERAMICS