Pergunta

versions: - WSO2 4.6.0 - Oracle 11g

I Have this procedure in an Oracle DB:

   PROCEDURE SEARCHCONTRACT ( CONTRACTNUM IN     OKC_K_HEADERS_B.CONTRACT_NUMBER%TYPE
                                 , cur_out          IN OUT RefCursor) 
   ....

The procedure is working fine!

Note that cur_out IN OUT RefCursor!

I have no clue on how to handle that parameter in a DBLookup mediator! This mediator does not have any place to inform whether each parameter is "IN" or "OUT" and I'm not sure if setting the direction (IN/OUT) would be enough.

Thanks in advance for any help!

Foi útil?

Solução

I believe you can use WSO2 Data Services Server (DSS) or your requirement.

You can download WSO2 DSS from http://wso2.com/products/data-services-server/

It has support for Oracle RefCursor.

You can then use the data service via WSO2 ESB.

Following article might help.

http://wso2.com/library/tutorials/use-oracle-ref-cursors-wso2-data-services-server

Outras dicas

just a thought. You could try to implement a pl/sql function that call that prodecure and return the value. This way you could get the result with the ddl SELECT MyfUCNTION(PARAM1) FROM DUAL.

You could also convert the procedure into a function.

Hope it helps!

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top