Hello friends, I am trying to install the module report_analytic_line and there are one SQL statement that once is executed throws this error:
Can not drop columns from view!
This is the sql statement:
CREATE OR REPLACE VIEW report_account_analytic_line_to_invoice AS (
SELECT
DISTINCT(to_char(l.date,'YYYY-MM-DD')) AS name,
MIN(l.id) AS id,
l.product_id,
l.account_id,
SUM(l.amount) AS amount,
SUM(l.unit_amount*t.list_price) AS sale_price,
SUM(l.unit_amount) AS unit_amount,
l.product_uom_id
FROM
account_analytic_line l
left join
product_product p on (l.product_id=p.id)
left join
product_template t on (p.product_tmpl_id=t.id)
WHERE
(invoice_id IS NULL) and (to_invoice IS NOT NULL)
GROUP BY
to_char(l.date,'YYYY-MM-DD'), product_id, product_uom_id, account_id
)
Please have someone one hint to solve this issue?
Best regards,