Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Dumping transaction from a web page

Author  Topic 

hasanali00
Posting Yak Master

207 Posts

Posted - 2006-10-04 : 11:47:29
Hi

I have this SP:

CREATE PROCEDURE sp_DumpTransaction

AS

dump transaction database_name with no_log
GO

This SP works fine when I run it through Enterprise Manager.

However, when I run this SP through an ASP.NET page, I get some errors. I cannot tell exactly what error I get, because ASP.NET does not tell me.

Would you have any more information on this issue?

Thanks

Kristen
Test

22859 Posts

Posted - 2006-10-04 : 12:00:47
Try logging in to Query Analyser using the same Login ID / Password as the web page, and run the command from there. Hopefully you will see the errors - its probably a permission error related to the UserID used by your ASP.NET application.

Kristen
Go to Top of Page

elwoos
Master Smack Fu Yak Hacker

2052 Posts

Posted - 2006-10-05 : 03:19:13
Kristen is almost certainly correct. If you want to see the error message you may have to login to the web server and use the localhost URL for the application. So for example if your app is at http://www.Somewhere.com/myapp/ then you would login to the web server and browse to http://localhost/myapp/


steve

-----------

Don't worry head. The computer will do all the thinking from now on.
Go to Top of Page

hasanali00
Posting Yak Master

207 Posts

Posted - 2006-10-05 : 05:36:03
Thanks for the replies.

I think this may NOT be a login problem.

I am running my app on a Shared SQL Server, so when I login to the live Query Analyser using the login details provided and run the SP, it runs OK

However, when I use the SAME login details inside my ASP.NET app, and run this SP, it fails.

So the login details for running the SP from QA and Web are same, but the SP seems to fail if run through web.

( If I remember correctly, this web operation was working fine for sometime, but now it fails)
Go to Top of Page

elwoos
Master Smack Fu Yak Hacker

2052 Posts

Posted - 2006-10-06 : 03:28:16
Are you using windows authentication in the web app?

Steve

-----------

Don't worry head. The computer will do all the thinking from now on.
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2006-10-06 : 03:36:41
... or SQL?
Go to Top of Page

hasanali00
Posting Yak Master

207 Posts

Posted - 2006-10-10 : 08:45:45
Well, inside my web.config file, I have this connection string:

<add key="ConnectionString" value="server=200.200.200.2000;uid=username;pwd=password;database=DB_name" />

So I guess its SQL authentication

The same values are used for connecting to the QA.
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2006-10-10 : 09:54:29
"So I guess its SQL authentication"

I don't think that follows, does it?

If the SQL is set to Windows Authentication won't it just ignore the UserID/Password that is given and use the current machine's Windows Authentication instead?

Kristen
Go to Top of Page

elwoos
Master Smack Fu Yak Hacker

2052 Posts

Posted - 2006-10-11 : 03:17:59
Yeah I think the default will be Windows Authentication. That means one of the IIS processes (can't remember which off the top of my head) is trying to call the sproc but it won't have Exec rights which is why it is failing.

steve

-----------

Don't worry head. The computer will do all the thinking from now on.
Go to Top of Page
   

- Advertisement -