Forum Discussion

DavidEtcell's avatar
DavidEtcell
Occasional Contributor
12 years ago

Included JDBC SQL Server driver does not run stored procs

This should go in the SoapUI Pro bugs section, but I dont have permissions for that so its going here.

I am using SoapUI Pro, and attempting to add an SQL Server as a datasource.

please see the issue I was having at: http://forum.soapui.org/viewtopic.php?f=5&t=22836&sid=fc0cddf45bbab3292445d12f391a622f

So anyway, it turns out the included jdbc Sql Server driver just cant handle stored procs, and in fact cant even see them. I used a quick and nasty groovy script to test the included MS JDBC driver against the jtds jdbc driver available from sourceforge, and the results speak for themselves:

included jdbc driver:


jtds jdbc driver:

5 Replies

  • Hello,

    You should have access to the Pro Forum Please open a support ticket and include your license for this on the link below:

    http://www.soapui.org/Support/support-overview.html

    As per your Issue, it seems like you may be missing something in your Groovy script, can you please refer to the script in the link below:
    http://www.soapui.org/Scripting-Propert ... -datasinks

    Also, why are you using Groovy as the DataSource, I suggest that you use JDBC as your datasource and you can Query your Database with the Wizard that makes it much easier. Let me know if you have further questions.

    Regards,
    Temil Sanchez
  • DavidEtcell's avatar
    DavidEtcell
    Occasional Contributor
    No, the post topic buttons don't appear in the pro forums. Probably something to do with the procurement manager here having purchased it (so I'm sure she can post to the pro forums at will), though I have the license itself.

    If you have a look at the first message I posted here: http://forum.soapui.org/viewtopic.php?f=5&t=22836 you can see that I did attempt to use a JDBC request, but was getting nothing returned from both addressing the stored procedure with sql, or calling the stored procedure as a stored procedure.

    It really feels to me like this is based on that light weight sql query tool which doesn't understand procs (among a pile of other sql constructs).

    I have raised a service call though, as well as asked for access to the pro forum.
  • Hello,

    I took a quick look at your previous post and everything should work, I assume that there must be small step missing but we want to get the ball rolling so looking at the below groovy script it seems to me that you are using the incorrect syntax to call stored procedure, you should use "sql.call" instead of "sql.eachRow"

    Please refer to this link http://groovy.codehaus.org/Database+features

    Let me know if this solves your issue.

    Regards,
    Temil Sanchez
  • DavidEtcell's avatar
    DavidEtcell
    Occasional Contributor
    I have a problem with sql.call in either case. I believe this ISSUE is the groovy bug described at http://jira.codehaus.org/browse/GROOVY-3048

    The sql.eachRow isnt how I really want to address the resultset (hence why I am outputting to the log rather than doing anything useful with it), however I am using it to show the microsoft jdbc driver packed is simply not returning the results, where the one from sourceforge is.
  • Hi,

    The driver we ship for Microsoft SQL Server could be outdated. Can you try against the latest Microsoft SQL Server JDBC driver that is available?

    Also, are you calling a stored procedure that uses output parameters?