I'm facing items like this:

SELECT DISTINCT ON (listing_t.product_name) listing_t.product_name, 
company_t.company_name, company_t.company_address, 
      company_t.company_city, company_t.company_province, company_t.
company_url, company_t.company_phone,
    FROM listing_t inner join s_ad_contracts_t on 
s_ad_contracts_t.contract_company_id 
= listing_t.product_company_id
      inner join company_t on company_t.scid = s_ad_contracts_t.
contract_company_id
    WHERE company_t.status = 'active'
      AND listing_t.status = 'active'
      AND s_ad_contracts_t.contract_status = 'active'
      AND listing_t.product_name ILIKE '#{ submitted }'
    ORDER BY listing_t.product_name, company_t.company_name
    LIMIT 100

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sequel-talk/a738bd6a-8424-4b76-bfdb-6d64673f780d%40googlegroups.com.

Reply via email to