Forum Discussion

JMcKinley's avatar
JMcKinley
Contributor
16 years ago

unable to resolve class groovy.sql.sql

I'm trying to access an SQL Server database. I grabbed the appropriate jdbc driver, loaded it on my local machine and modified the SOAP UI Pro bat file to include the classpath:

set CLASSPATH=%CLASSPATH%;%SOAPUI_HOME%..\lib\sqljdbc.jar

When I the following:

import groovy.sql.sql

I get the error:

"unable to resolve the class groovy.sql.sql"

What am I doing wrong?

Help!

3 Replies

  • SmartBear_Suppo's avatar
    SmartBear_Suppo
    SmartBear Alumni (Retired)
    Hi!

    I think you need a capital S in the second sql;

    import groovy.sql.Sql

    Does that help?

    regards,

    /Ole
    eviware.com
  • Yes, it does! I've gotten further (thank you).

    I am now getting an error message (unable to log in as user 'sa'.)

    Here is my connection string:

    def sql = Sql.newInstance("jdbc:sqlserver://qcsql","sa","","com.microsoft.sqlserver.jdbc.SQLServerDriver")

    I also tried:

    def sql = Sql.newInstance("jdbc:sqlserver://qcsql","sa","com.microsoft.sqlserver.jdbc.SQLServerDriver")

    and got the same error

    qcsql is the name of the server.

    Do you see anything wrong with the connection string?