src-db/database/model/views/C_BPARTNER_V.xml
author Antonio Moreno <antonio.moreno@openbravo.com>
Mon, 04 Feb 2013 09:27:53 +0100
changeset 9910 6767429386d8
parent 7031 2aac4501bbd5
child 9911 444911e2b851
permissions -rw-r--r--
Changes required to support PostgreSQL 9.2
gorkaion@1785
     1
<?xml version="1.0"?>
gorkaion@1785
     2
  <database name="VIEW C_BPARTNER_V">
antonio@9910
     3
    <view name="C_BPARTNER_V"><![CDATA[SELECT p.ad_client_id, p.ad_org_id, p.c_bpartner_id, p.value, p.name,  p.referenceno, p.so_creditlimit - p.so_creditused AS so_creditavailable,  p.so_creditlimit, p.so_creditused, p.iscustomer, p.isvendor,  p.actuallifetimevalue AS revenue, c.name AS contact, c.phone, a.postal,  a.city, c.email FROM c_bpartner p LEFT JOIN ad_user c ON p.c_bpartner_id = c.c_bpartner_id LEFT JOIN c_bpartner_location l ON p.c_bpartner_id = l.c_bpartner_id LEFT JOIN c_location a ON l.c_location_id = a.c_location_id]]></view>
gorkaion@1785
     4
  </database>