Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Problem connecting to the database after upgrading from .Net 1.1to .Net 3.0??

Reply
Thread Tools

Problem connecting to the database after upgrading from .Net 1.1to .Net 3.0??

 
 
Michael Howes
Guest
Posts: n/a
 
      08-26-2008


I am trying to upgrade a large asp.net application from .Net 1.1 to
..Net 3.0

I'm getting an error when connecting to the database now that the app
runs as a .Net 3.0 application.

the database connection code is part of Microsoft's ApplicationBlocks,
the Data Access Block. The project is using the SQLHelper class from MS.

The connection fails the SqlConnection call to Open()
Looking at the SQL Server 2005 logs it thinks the "Login failed" with
an Error 18456, Severity 14, State 5 which I think means some sort of
wrong password.

The exact code works in .Net 1.1
The error happens after upgrading .Net 3.0
If I change the <trust level= in the web.config from Medium to Full
the .Net 3.0 call to SqlConnection.Open() works just fine.

This application needs to run under Medium trust.

anyone have any ideas what I need to change to get this to work under
Medium trust? Other settings I need to make in the web.config maybe?
Do I need to upgrade to a newer version of Microsoft's Enterprise
Library?

thanks
mike

 
Reply With Quote
 
 
 
 
Cowboy \(Gregory A. Beamer\)
Guest
Posts: n/a
 
      08-27-2008
Ther simple answer is aim for the newer Enterprise library. This means
changing code, as it is completely different from the Application block you
are using.

Another option is to run in debug and find out where it is blowing up and
correcting that code. Maybe not the best long term strategy, but it works.
You will need to run against the block's source code to do this, not the
compiled block.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
"Michael Howes" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>
>
> I am trying to upgrade a large asp.net application from .Net 1.1 to .Net
> 3.0
>
> I'm getting an error when connecting to the database now that the app
> runs as a .Net 3.0 application.
>
> the database connection code is part of Microsoft's ApplicationBlocks,
> the Data Access Block. The project is using the SQLHelper class from MS.
>
> The connection fails the SqlConnection call to Open()
> Looking at the SQL Server 2005 logs it thinks the "Login failed" with an
> Error 18456, Severity 14, State 5 which I think means some sort of wrong
> password.
>
> The exact code works in .Net 1.1
> The error happens after upgrading .Net 3.0
> If I change the <trust level= in the web.config from Medium to Full the
> .Net 3.0 call to SqlConnection.Open() works just fine.
>
> This application needs to run under Medium trust.
>
> anyone have any ideas what I need to change to get this to work under
> Medium trust? Other settings I need to make in the web.config maybe?
> Do I need to upgrade to a newer version of Microsoft's Enterprise
> Library?
>
> thanks
> mike
>


 
Reply With Quote
 
 
 
 
Michael Howes
Guest
Posts: n/a
 
      08-27-2008

>
> Another option is to run in debug and find out where it is blowing up
> and correcting that code. Maybe not the best long term strategy, but it
> works. You will need to run against the block's source code to do this,
> not the compiled block.
>


the reason I think it's a trust issue is because I did trace and it
gets to the SqlConnect call to .Open() and fails. But this fails only
under Medium trust and not Full trust. In other words I already know
where it's failing, just don't have a guess as to why.

mike

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Database Database Database Database scott93727@gmail.com Computer Information 0 09-27-2012 02:43 AM
DataBase DataBase DataBase DataBase scott93727@gmail.com Computer Information 0 09-26-2012 09:40 AM
Problem connecting to the database after upgrading from .Net 1.1to .Net 3.0?? Michael Howes ASP .Net Security 2 08-27-2008 05:34 PM
Errors after upgrading SQL Server 2000 database compatibility level paulh@esellerate.net ASP General 3 01-25-2006 05:08 PM
Problems with Connecting to Internet after Upgrading bpgordon Computer Support 2 02-17-2004 05:59 PM



Advertisments