ERROR: Document processed/posted en DBLINK

From: "luis muro" <luis(dot)muro(at)gmail(dot)com>
To: pgsql-es-ayuda(at)postgresql(dot)org
Subject: ERROR: Document processed/posted en DBLINK
Date: 2007-08-09 21:56:11
Message-ID: cfa0c710708091456u6a7677aye8732b71e0debb17@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

hola

Antes que nada un saludo a toda la comunidad de postges, tengo un pequeño
problema, estoy replicando alguna información usando dblink, este funciona
correctamente, incluso envio algunos inserts de prueba en tablas pequeñas
como

SELECT INTO v_dblink dblink_exec(
'dbname=amezcua
port=5432
', ' INSERT INTO foo values (' || COALESCE('''' ||
invoice.ad_user_id || '''','NULL') || ');' );

Pero al enviar una consualta mas grande como :

SELECT INTO v_dblink dblink_exec(
'dbname=amezcua
port=5432
', ' INSERT
INTO c_invoice (c_invoice_id, ad_client_id, ad_org_id, isactive,
created, createdby, updated, updatedby, issotrx, documentno, docstatus,
docaction, processing, processed, posted, c_doctype_id, c_doctypetarget_id,
c_order_id, description, isapproved, istransferred, isprinted, salesrep_id,
dateinvoiced, dateprinted, dateacct, c_bpartner_id,c_bpartner_location_id,
poreference, isdiscountprinted, dateordered, c_currency_id, paymentrule,
c_paymentterm_id, c_charge_id, chargeamt, totallines, grandtotal,
m_pricelist_id, istaxincluded, c_campaign_id, c_project_id, c_activity_id,
ispaid, createfrom, generateto, sendemail, ad_user_id, copyfrom,
isselfservice, ad_orgtrx_id, user1_id, user2_id)
VALUES (''' || invoice.c_invoice_id || ''', ''' || invoice.ad_client_id ||
''', ''' || invoice.ad_org_id || ''', ''' ||invoice.isactive || ''', ''' ||
invoice.created || ''', ''' || invoice.createdby || ''', ''' ||
invoice.updated || ''', ''' || invoice.updatedby || ''', ''N '', ''' ||
invoice.documentno || ''', ''' ||invoice.docstatus || ''', '''
||invoice.docaction || ''', '
|| COALESCE('''' || invoice.processing || '''','NULL') ||', ''' ||
invoice.processed || ''', ''' || invoice.posted || ''', ''' ||
invoice.c_doctype_id ||''', ''' ||invoice.c_doctypetarget_id ||''','
|| COALESCE('''' || invoice.c_order_id || '''', 'NULL') ||', '
|| COALESCE('''' || invoice.description || '''', 'NULL') ||', ''' ||
invoice.isapproved ||''', ''' || invoice.istransferred || ''', ''' ||
invoice.isprinted || ''', '
|| COALESCE('''' || invoice.salesrep_id || '''', 'NULL') ||', ''' ||
invoice.dateinvoiced || ''', '
|| COALESCE('''' || invoice.dateprinted || '''', 'NULL') ||', ''' ||
invoice.dateacct || ''', ''' || invoice.c_bpartner_id || ''', ''' ||
invoice.c_bpartner_location_id || ''', '
|| COALESCE('''' ||invoice.poreference || '''', 'NULL') ||', ''' ||
invoice.isdiscountprinted ||''', '
|| COALESCE('''' || invoice.dateordered || '''', 'NULL') ||', ''' ||
invoice.c_currency_id || ''', ''' || invoice.paymentrule || ''', ''' ||
invoice.c_paymentterm_id || ''', '
|| COALESCE('''' || invoice.c_charge_id || '''', 'NULL') ||', '
|| COALESCE('''' || invoice.chargeamt ||'''','NULL') ||', '''
||invoice.totallines || ''', ''' || invoice.grandtotal || ''',''' ||
invoice.m_pricelist_id || ''', ''' ||invoice.istaxincluded || ''', '
|| COALESCE('''' || invoice.c_campaign_id || '''', 'NULL') ||', '
|| COALESCE('''' || invoice.c_project_id || '''','NULL') ||', '
|| COALESCE('''' ||invoice.c_activity_id || '''','NULL') ||', ''' ||
invoice.ispaid || ''', '
|| COALESCE('''' || invoice.createfrom || '''','NULL') ||', '
|| COALESCE('''' || invoice.generateto || '''','NULL') ||', ''' ||
invoice.sendemail || ''', '
|| COALESCE('''' || invoice.ad_user_id || '''','NULL') ||', '
|| COALESCE('''' || invoice.copyfrom || '''','NULL') ||', '''
||invoice.isselfservice || ''', '
|| COALESCE('''' || invoice.ad_orgtrx_id || '''','NULL') ||', '
|| COALESCE('''' || invoice.user1_id || '''','NULL') ||', '
|| COALESCE('''' ||invoice.user2_id ||'''','NULL') ||')' ');

Me envia el siguente error

ERROR: sql error
DETAIL: ERROR: Document processed/posted

CONTEXT: SQL statement "SELECT dblink_exe ........

He buscado en foros y en google y no encuentro nada relacionado, el
parametro de dblink_exec tienen algun limite o algo por el estilo ????

Gracias a todos

Responses

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message Jaime Casanova 2007-08-09 23:46:28 Re: roadmap postgresql
Previous Message Guido Barosio 2007-08-09 21:24:23 Re: roadmap postgresql