Friday, February 24, 2012

different environment fails to fill a dataset

I have a C# client application that uses SQL Server as a backend. It works
fine on my development workstation. But when I moved it to another test
workstation four out of the five winforms worked fine but one doesn't. The
one that doesn't can open the connection and return the server version as a
test of whether the open worked right. I does. But when you run the
oledbadapter.fill command to fill the dataset it fails. It acts as if it
can't open the server. Further reading shows that the fill command can
actually open a connection on its own if necessary without the open command.
Is there anything in the environment or SQL Server that could be causing this
rejection. The SQL Server database was detached, copied, and then reattached
on the test workstation. SO it should be a duplicate.
Randy
Did you resync the logins to the users in that db after you attached it? If
not check out sp_change_users_login in BooksOnLine.
Andrew J. Kelly SQL MVP
"rseedle" <rseedle@.discussions.microsoft.com> wrote in message
news:C298B6AF-C57D-40EE-905C-CB50F29126F3@.microsoft.com...
>I have a C# client application that uses SQL Server as a backend. It works
> fine on my development workstation. But when I moved it to another test
> workstation four out of the five winforms worked fine but one doesn't. The
> one that doesn't can open the connection and return the server version as
> a
> test of whether the open worked right. I does. But when you run the
> oledbadapter.fill command to fill the dataset it fails. It acts as if it
> can't open the server. Further reading shows that the fill command can
> actually open a connection on its own if necessary without the open
> command.
> Is there anything in the environment or SQL Server that could be causing
> this
> rejection. The SQL Server database was detached, copied, and then
> reattached
> on the test workstation. SO it should be a duplicate.
> Randy

No comments:

Post a Comment