(SELECT ARRAY_TO_STRING(ARRAY(SELECT payment_method FROM dtb_payment_options LEFT JOIN dtb_payment ON dtb_payment_options.payment_id = dtb_payment.payment_id WHERE dtb_payment_options.product_class_id = prdcls.product_class_id ORDER BY dtb_payment_options.rank), ',')) as product_payment_names