cancel
Showing results for 
Search instead for 
Did you mean: 

add some strings to Param.1 before calling oracle stored procedure from MII without BLS

Former Member
0 Kudos

Hi,

    We have one requirement. We are calling a Oracle SP to insert long values. Now the long value string contains many single quotes and to escape all these we need to add q'! at the beginning of the string and !' at the end of the string to insert them successfully to Oracle via a stored procedure call.

When we manually add the values in the Param.1 and call the SP , it works fine

But we want to add these at query level before passing the parameters to make the Oracle SP call.

How can we do that in MII ?

We dont want to use BLS for this as this will involve additions to existing architecture which will involve quite complexity.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Abhiroop,

To insert a single quote in Oracle,you need to add one extra single quote to it.

Use 'Replace' function of Oracle to replace the single quote everywhere in your string by two single quotes and then insert it.

Hope this helps.

Regards,

Anuj

Former Member
0 Kudos

Dear Abhiroop

Not sure, if you already tried with this below at SQL Query level

{call <pkg_name>.<SP_name>('[Param.1]',Q'![Param.2]!','[Param.3]',?)}

Where [Param.2] is the concerned parameter which receives long message. Hope it will work.

U need not change anything at BLS level which calls current SQL Query. Just replace current SQL Query with this new SQL Query with same name which will have same parameter numbers so that the mapping of these params in BLS level needs not be altered.

Regards

Som

jcgood25
Active Contributor
0 Kudos

What is the object (e.g. - Applet) or mechanism (e.g. - http/URL call) for calling your Query Template?

If using a URL format to call the servlet you can append &Param.1=xxxxx to the URL, otherwise use the document.APPLETNAME.getQueryObject().setParam(1,'xxxxx') to provide the desired information to your query.