As in my title I want to get data from 2 rows which has same data in all columns except one column in any one row.you can get idea if you see the below details .
BEGIN SELECT EPI.ITEM_CODE, LMP.PROD_DESC, LLPC.COLOC_PROD_PRICE, BASE_PATH + '' + EPI.IMAGE_FOLDER_NAME + '/' + EPI.IMAGE_DESCRIPTION AS POPULAR_PRODUCTS_IMAGE_PATHS FROM ECOM_PRODUCT_IMAGES EPI INNER JOIN ECOM_POPULAR_PRODUCTS_MAPPING EPPIM ON EPPIM.ITEM_CODE = EPI.ITEM_CODE INNER JOIN LOM_MST_PRODUCT LMP ON LMP.PROD_CODE = EPI.ITEM_CODE INNER JOIN LOM_LNK_PROD_COMP LLPC ON LLPC.COLOC_PROD_CODE = LMP.PROD_CODE WHERE EPPIM.ITEM_STATUS = 'ACTIVE' END
I want to merge the result as in the below format :
Here for every product code I got two rows of data ,But in one row(POPULAR_PRODUCT_IMAGE_PATHS) column contains different data .I want to take that different data value as a new column value in result set .
Please help me to solve this issue. Thanks.
Cache file /home/queryxchang/public_html/apps/frontend/config/../cache/-q-7-204489-how-to-get-data-from-two-rows-which-has-same-data-in-all-columns-except-one-in-mssql- could not be written