The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here

How to call a stored procedure in DB2

llohmannllohmann Member Posts: 2 Contributor I
Hello everyone,

I found this Question: https://community.rapidminer.com/discussion/29665/execute-stored-procedure-with-read-database-operator 

Which is already helpful, but it doesn't work in my context, bc I think its an oracle DB in their case. In my case I have a DB2 stored procedure and I want to call it, to get something back in RM Studio.

So what I've tried is the following:

Read DB Operator with SQL Code:

"SELECT *
FROM (
   CALL Schema.NameOfProcedure(%{LOADING_SCHEMA}, %{LOADINGTABLE})
)"

Is my Syntax messed up? Because I'll always get an error.

Answers

  • BalazsBaranyBalazsBarany Administrator, Moderator, Employee-RapidMiner, RapidMiner Certified Analyst, RapidMiner Certified Expert Posts: 955 Unicorn
    Hi,

    there could be many problems. 

    Does the query work in a native SQL client? Does it work with the actual parameters in RapidMiner (instead of the macros)? Maybe you need to quote the macro values with single quotes? '%{LOADING_SCHEMA}' etc.

    What does the error message say? Do you find additional information in the log of the database server?

    Regards,
    Balázs
Sign In or Register to comment.