I'm tying to call a MS SqLServer Stored Procedure from a Java Application but I haven't been able to do it.

I have the connection working which uses an IP address and Port, user and password, but whenever I try to use the Stored Procedure I get an error message.

I have the following code:

try {
Class.forName( "com.microsoft.jdbc.sqlserver.SQLServerDriver" );
Connection conn = DriverManager.getConnection ("jdbc:microsoft:sqlserver://","user","passw");

CallableStatement stmt = conn.prepareCall
("Call prc_GetRES_LegalAddr(? ? ? ? ?)",

The error happens when the prepareCall method is called.
I listed all the stored procedures and the prc_GetRES_LegalAddr procedure does not appear as part of the list.

There's an ASP which uses the same procedure and it works,
I think I need to pass additional info to the URL info, passed in the getConnetion() method???


With cmd.ActiveConnection =
"Provider=SQLOLEDB.1,Password=passw,Persist Security Info =True;
User ID=user;Initial Catalog=FSLegal;Network Address=;Network Library=DBMSSOCN;Application Name=FAST WEB"

Should I maybe pass the Network Library (i.e., DBSMSCON) in my URL?
since the stored prcedure does not exist as part of this connection.
Maybe it is located on this Network Library (different Path).

I get the following error:

com.microsoft.jdbc.sqlserver.SQLServerConnection.p repareCall(Ljava/lang/String;III) ......

Please help....