src/org/openbravo/erpCommon/ad_callouts/SE_InOut_DocType_data.xsql
changeset 423 ecf368072c48
parent 0 0247c26f10c6
child 799 fef2c5e2feb7
--- a/src/org/openbravo/erpCommon/ad_callouts/SE_InOut_DocType_data.xsql	Tue Feb 12 17:01:08 2008 +0000
+++ b/src/org/openbravo/erpCommon/ad_callouts/SE_InOut_DocType_data.xsql	Tue Feb 12 18:53:44 2008 +0000
@@ -30,7 +30,7 @@
         SELECT d.HasCharges,d.IsApproved,d.IsDocNoControlled,
         s.CurrentNext, d.DocBaseType
         FROM C_DocType d left join AD_Sequence s on d.DocNoSequence_ID=s.AD_Sequence_ID
-        WHERE C_DocType_ID=?
+        WHERE C_DocType_ID = TO_NUMBER(?)
       ]]>
     </Sql>
     <Parameter name="cDocTypeId"/>
@@ -41,7 +41,7 @@
       <![CDATA[
         SELECT C_DOCTYPETARGET_ID
         FROM C_INVOICE
-        WHERE C_INVOICE_ID = ?
+        WHERE C_INVOICE_ID = TO_NUMBER(?)
       ]]>
     </Sql>
     <Parameter name="cInvoiceId"/>
@@ -52,7 +52,7 @@
       <![CDATA[
         SELECT DOCUMENTNO
         FROM C_INVOICE
-        WHERE C_INVOICE_ID = ?
+        WHERE C_INVOICE_ID = TO_NUMBER(?)
       ]]>
     </Sql>
     <Parameter name="cInvoiceId"/>