"Mitch Wright" <[EMAIL PROTECTED]> wrote:
>
>"Chandu" <[EMAIL PROTECTED]> wrote:
>>
>>"Raja" <[EMAIL PROTECTED]> wrote:
>>>>I want to pass an array to an oracle stored procedure from ND page. >>The only
 way I could think of writing a procedure which can accept array as an input 
argument>is
 to write a package and have the procedure inside that package.>>But ND does not see
 the packages when I try to create a dataobject using the wizard.>>So how can I execute
 a stored procedure having an array type of input paramater  from a ND page.>>Any
 kind of pointers or snippets of code with the PL/SQL procedure and java code will>be
>highly
>appreciated and woudl really help.>>--------Here the PL/SQL block for creating a
 package/procedure which can accept array type of argument------->>CREATE OR REPLACE
 package array_pack as>type a_array is table of number(9)>      index by 
binary_integer;>>procedure
 test1 (invar in out a_array);>>end array_pack;>/>>CREATE OR REPLACE package body
 array_pack as>procedure test1 (invar in out a_array ) is>counter 
binary_integer;>begin>counter
 := 1;>>end test1;>>end array_pack;>/>>-------------End PL/SQL
>>BLOCK-------------------->>so how can i use this kind of procedure having an array
 type input  arguemnt from ND environment??>I am sure some of you would have come
 accross this problem and solved the same.>>Thanks in advance,>Raja
>>
>>
>>NetDynamics is yet to support array/vector data types for Oracle procedures.
>>In our systems,we create a transaction object and add stor proc data objects.
>>Please let me know if anybody had accomplished this.
>>
>>Chandu
>
>Try adding the array values you want to pass along to the stored procedure as a CSV:
>
>doParamIsArray.clearAllValues();
>doParamIsArray.setValue("invar", "1,2,3,4,5");
>doParamIsArray.execute();
>
>This assumes, of course, that "invar" shows up as a table in the procedure wizard.
>
>I haven't tried this with an RDBMS stored procedure, but it works for passing an 
>aggregate list to SAP via the PAC.
>
>- Mitch
>

Perhaps I should elucidate. Suppose we want to pass the following to a BAPI:

0 {
  userId "234" ;
  name "charles" ;
}
1 {
  userId "567" ;
  name "phil" ;
}

Additionally, let's assume that the BAPI also takes the color of the sky (?) as an 
argument.

doUpdateOrgUsers.clearAllValues();
doUpdateOrgUsers.setValue("skycolor", new CSpString("purple"));
doUpdateOrgUsers.setValue("userId", new CSpString("234,567");
doUpdateOrgUsers.setValue("name", new CSpString("charles,phil");
doUpdateOrgUsers.execute();

As I metioned before, this works when calling an SAP BAPI via the PAC, but since its
 data objects are subclassed from CSpProcedure, I would expect that this would also
 work for an RDBMS stored procedure as well.

- Mitch


_________________________________________________________________________
To unsubscribe from this mailing list please send an email to:
[EMAIL PROTECTED]
Please remember to use the same email address you subscribed with.

For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html

For dire need help, email: [EMAIL PROTECTED]

Reply via email to