none
Running Oracle stored procedure from MIMWAL RRS feed

  • Question

  • Has anyone got an example of a working connection string for connecting to Oracle?

    I've tried various ones that work from PowerShell, but I always get the same error:

    MicrosoftServices.IdentityManagement.WorkflowActivityLibrary.Exceptions.InvalidFunctionFormatException: The function 'CreateSqlParameter' is configured with an invalid or missing config key 'Oracle'.

    If I change the connection string to a MS SQL one I know works it is OK, so looks like it is 'invalid' rather than 'missing'

    For example this appears OK if run from PowerShell:

    $conn = New-Object System.Data.Odbc.OdbcConnection

    $conn.ConnectionString = "DRIVER={Oracle in OraClient12Home3};UID=YYYY;SERVER=ZZZZ;DBQ=ZZZZ;PWD="XXXX";"

    (new-Object Data.Odbc.OdbcCommand("select 'Hello World' from dual",$conn)).ExecuteScalar()

    My other thought is I'm using a driver that isn't compatible. 

    Has anyone ever got this working?

     

    Wednesday, September 18, 2019 11:09 AM

Answers

  • What is your actual entry in the config file? Have you not specified the providerName there? Depending on the provider, there may be different ways of specifying the connection string.

    PS: Only providers supported by WAL are System.Data.Odbc and System.Data.SqlClient. And the error seems to suggest that providerName="System.Data.Odbc"  is not specified.

    Wednesday, September 18, 2019 12:11 PM
    Owner

All replies

  • Have you added the connection string setting to the mimservice config file (Microsoft.ResourceManagement.Service.exe.config) by the name "Oracle"? If so, have you restarted the mimservice since then?
    Wednesday, September 18, 2019 11:38 AM
    Owner
  • Yes it is there and service restarted. I have another one calling MS SQL stored procedure that works fine.
    Wednesday, September 18, 2019 12:01 PM
  • What is your actual entry in the config file? Have you not specified the providerName there? Depending on the provider, there may be different ways of specifying the connection string.

    PS: Only providers supported by WAL are System.Data.Odbc and System.Data.SqlClient. And the error seems to suggest that providerName="System.Data.Odbc"  is not specified.

    Wednesday, September 18, 2019 12:11 PM
    Owner
  • You are correct, I had the wrong provider set.

    Correcting that allows me to get further.

    Thanks.

    Wednesday, September 18, 2019 12:24 PM