Discussion:
calling eConnect stored procedure directly
(too old to reply)
Vishal
2009-09-22 21:11:04 UTC
Permalink
Hi, trying to call procedure [taCreateVendorAddress] directy but keep getting
error 902. Can someone provide an example of how to use the econnect procs.
I have the econnect web service installed but I would like to call the proc
directly in this instance. Thanks in advance.
Mariano Gomez
2009-09-22 21:59:01 UTC
Permalink
You can call *certain* eConnect stored procedures directly, this is certainly
one of the ones you can call. Use this as a template:

DECLARE @Result INT, @ErrorState INT;
DECLARE @ErrString varchar(255);

EXEC @Result = taCreateVendorAddress
'ACETRAVE0001' -- Vendor ID
, 'WAREHOUSE' -- Address Code
, '' -- UPS Zone
, 'OVERNIGHT' -- Shipping Method
, 'USAUSSTCITY+6*' -- Tax Schedule ID
, 'Oscar Wilde' -- Vendor Contact
, '1101 Sactuary Dr' -- Adress 1
, 'Suite 200' -- Address 2
, '' -- Address 3
, 'USA' -- Country
, 'Chicago' -- City
, 'IL' -- State
, '43221' -- Zip Code
, '29455501010000' -- phone 1
, '' -- phone 2
, '' -- phone 3
, '' -- fax
, 0 -- update if exists
, 0 -- Requester transaction
, '' -- vCCode
, '' -- User defined 1
, '' -- User defined 2
, '' -- User defined 3
, '' -- User defined 4
, '' -- User defined 5
, @ErrorState OUTPUT
, @ErrString OUTPUT


SELECT @ErrorState, @ErrString

Needless to say, the vendor must already exist for this stored proc to work.

Best regards,
--
MG.-
Mariano Gomez, MIS, MCP, PMP
Maximum Global Business, LLC
http://www.maximumglobalbusiness.com
The Dynamics GP Blogster at http://dynamicsgpblogster.blogspot.com
Post by Vishal
Hi, trying to call procedure [taCreateVendorAddress] directy but keep getting
error 902. Can someone provide an example of how to use the econnect procs.
I have the econnect web service installed but I would like to call the proc
directly in this instance. Thanks in advance.
elmo : )
2012-01-12 10:30:44 UTC
Permalink
I want to know if "taSopLineIvcInsert" is also among those certain stored procedures?

Thanks,
elmo
Post by Vishal
Hi, trying to call procedure [taCreateVendorAddress] directy but keep getting
error 902. Can someone provide an example of how to use the econnect procs.
I have the econnect web service installed but I would like to call the proc
directly in this instance. Thanks in advance.
Post by Mariano Gomez
You can call *certain* eConnect stored procedures directly, this is certainly
'ACETRAVE0001' -- Vendor ID
, 'WAREHOUSE' -- Address Code
, '' -- UPS Zone
, 'OVERNIGHT' -- Shipping Method
, 'USAUSSTCITY+6*' -- Tax Schedule ID
, 'Oscar Wilde' -- Vendor Contact
, '1101 Sactuary Dr' -- Adress 1
, 'Suite 200' -- Address 2
, '' -- Address 3
, 'USA' -- Country
, 'Chicago' -- City
, 'IL' -- State
, '43221' -- Zip Code
, '29455501010000' -- phone 1
, '' -- phone 2
, '' -- phone 3
, '' -- fax
, 0 -- update if exists
, 0 -- Requester transaction
, '' -- vCCode
, '' -- User defined 1
, '' -- User defined 2
, '' -- User defined 3
, '' -- User defined 4
, '' -- User defined 5
Needless to say, the vendor must already exist for this stored proc to work.
Best regards,
--
MG.-
Mariano Gomez, MIS, MCP, PMP
Maximum Global Business, LLC
http://www.maximumglobalbusiness.com
The Dynamics GP Blogster at http://dynamicsgpblogster.blogspot.com
Post by JG
Mariano's template is correct - also just so you know here is what edit
check 902 is checking for - perhaps you do not have one of the fields set....
if (
@I_vVENDORID is null or
@I_vADRSCODE is null or
@I_vUpdateIfExists is null or
@I_vRequesterTrx is null
)
begin
/* input variable contains null value */
parameter for vendor addresses */ /*VENDORID ADRSCODE*/
@O_iErrorState,
@iCustomErrString,
@oErrString output,
@O_oErrorState output
end
Hope that helps,
JG
Post by Vishal
Thanks everyone, I forgot to pass parameter vRequesterTrx resulting in my 902
error. Cheers.
Post by VJ
You could also use the taErrorCode table under Dynamics database to
see what 902 is referring to...
....
east one input
etting
procs. =A0
proc
JG
2009-09-23 13:54:01 UTC
Permalink
Vishal:

Mariano's template is correct - also just so you know here is what edit
check 902 is checking for - perhaps you do not have one of the fields set....

if (
@I_vVENDORID is null or
@I_vADRSCODE is null or
@I_vUpdateIfExists is null or
@I_vRequesterTrx is null
)
begin
/* input variable contains null value */
select @O_iErrorState = 902 /* A null was found in at least one input
parameter for vendor addresses */ /*VENDORID ADRSCODE*/
exec @iStatus = taUpdateString
@O_iErrorState,
@iCustomErrString,
@oErrString output,
@O_oErrorState output
end

Hope that helps,

JG
Post by Vishal
Hi, trying to call procedure [taCreateVendorAddress] directy but keep getting
error 902. Can someone provide an example of how to use the econnect procs.
I have the econnect web service installed but I would like to call the proc
directly in this instance. Thanks in advance.
VJ
2009-09-23 15:44:01 UTC
Permalink
You could also use the taErrorCode table under Dynamics database to
see what 902 is referring to...
Post by JG
Mariano's template is correct - also just so you know here is what edit
check 902 is checking for - perhaps you do not have one of the fields set....
if      (
        )
begin
        /* input variable contains null value */
parameter for vendor addresses */ /*VENDORID ADRSCODE*/
end
Hope that helps,
JG
Post by Vishal
Hi, trying to call procedure [taCreateVendorAddress] directy but keep getting
error 902.  Can someone provide an example of how to use the econnect procs.  
I have the econnect web service installed but I would like to call the proc
directly in this instance.  Thanks in advance.
Vishal
2009-09-23 16:35:02 UTC
Permalink
Thanks everyone, I forgot to pass parameter vRequesterTrx resulting in my 902
error. Cheers.
Loading...