Showing posts with label locally. Show all posts
Showing posts with label locally. Show all posts

Wednesday, March 7, 2012

Can't register SQL Server locally due to Login problems

Hello,
I had installed SQL Server 2000 locally on my machine and I had 2 security
logins: -
1. sa - default database was set to dbTest
2. mydomain\myusername - default database was set to dbTest
The thing is, "dbTest" was deleted due to some testing and now when I try
to connect to my SQL Server with Enterprise Manager, Login fails as the
default database is missing.
Is there a way I can register back my server ?
Thanks,
Sam.
Message posted via http://www.sqlmonster.com
You can try connecting via osql.exe (a command line tool) and issue the
appropriate command to change the default database (using sp_defaultdb).
or
You can try modifying your shortcut to Query Analyzer to something like
this:
"C:\Program Files\Microsoft SQL
Server\80\Tools\Binn\isqlw.exe" -SYourMachineNameHere -Usa -PTheSApwdGoesHer
e -dtempdb
I use the modified shortcut method to connect to a specific server and
connect to a specific database. However I don't know if you will be able to
do this if the user's default database is unavailable.
Keith
"Sameer Premji via SQLMonster.com" <forum@.SQLMonster.com> wrote in message
news:3c315b71f1a74a548e1b9c93ad0da038@.SQLMonster.c om...
> Hello,
> I had installed SQL Server 2000 locally on my machine and I had 2 security
> logins: -
> 1. sa - default database was set to dbTest
> 2. mydomain\myusername - default database was set to dbTest
> The thing is, "dbTest" was deleted due to some testing and now when I try
> to connect to my SQL Server with Enterprise Manager, Login fails as the
> default database is missing.
> Is there a way I can register back my server ?
> Thanks,
> Sam.
> --
> Message posted via http://www.sqlmonster.com
|||The shortcut didn't work.
How do I use osql.exe because double-clicking on it, vanishes and what is
the statement ?
Message posted via http://www.sqlmonster.com
|||Since osql is a command line tool you need to
Start | Run | cmd <enter>
osql /? <enter>
Keith
"Sameer Premji via SQLMonster.com" <forum@.SQLMonster.com> wrote in message
news:2313ae62041a424caca786036f7b4385@.SQLMonster.c om...
> The shortcut didn't work.
> How do I use osql.exe because double-clicking on it, vanishes and what is
> the statement ?
> --
> Message posted via http://www.sqlmonster.com

Can't register SQL Server locally due to Login problems

Hello,
I had installed SQL Server 2000 locally on my machine and I had 2 security
logins: -
1. sa - default database was set to dbTest
2. mydomain\myusername - default database was set to dbTest
The thing is, "dbTest" was deleted due to some testing and now when I try
to connect to my SQL Server with Enterprise Manager, Login fails as the
default database is missing.
Is there a way I can register back my server ?
Thanks,
Sam.
Message posted via http://www.droptable.comYou can try connecting via osql.exe (a command line tool) and issue the
appropriate command to change the default database (using sp_defaultdb).
or
You can try modifying your shortcut to Query Analyzer to something like
this:
"C:\Program Files\Microsoft SQL
Server\80\Tools\Binn\isqlw.exe" -SYourMachineNameHere -Usa -PTheSApwdGoesHer
e -dtempdb
I use the modified shortcut method to connect to a specific server and
connect to a specific database. However I don't know if you will be able to
do this if the user's default database is unavailable.
Keith
"Sameer Premji via droptable.com" <forum@.droptable.com> wrote in message
news:3c315b71f1a74a548e1b9c93ad0da038@.SQ
droptable.com...
> Hello,
> I had installed SQL Server 2000 locally on my machine and I had 2 security
> logins: -
> 1. sa - default database was set to dbTest
> 2. mydomain\myusername - default database was set to dbTest
> The thing is, "dbTest" was deleted due to some testing and now when I try
> to connect to my SQL Server with Enterprise Manager, Login fails as the
> default database is missing.
> Is there a way I can register back my server ?
> Thanks,
> Sam.
> --
> Message posted via http://www.droptable.com|||The shortcut didn't work.
How do I use osql.exe because double-clicking on it, vanishes and what is
the statement ?
Message posted via http://www.droptable.com|||Since osql is a command line tool you need to
Start | Run | cmd <enter>
osql /? <enter>
Keith
"Sameer Premji via droptable.com" <forum@.droptable.com> wrote in message
news:2313ae62041a424caca786036f7b4385@.SQ
droptable.com...
> The shortcut didn't work.
> How do I use osql.exe because double-clicking on it, vanishes and what is
> the statement ?
> --
> Message posted via http://www.droptable.com

Can't register SQL Server locally due to Login problems

Hello,
I had installed SQL Server 2000 locally on my machine and I had 2 security
logins: -
1. sa - default database was set to dbTest
2. mydomain\myusername - default database was set to dbTest
The thing is, "dbTest" was deleted due to some testing and now when I try
to connect to my SQL Server with Enterprise Manager, Login fails as the
default database is missing.
Is there a way I can register back my server ?
Thanks,
Sam.
--
Message posted via http://www.sqlmonster.comYou can try connecting via osql.exe (a command line tool) and issue the
appropriate command to change the default database (using sp_defaultdb).
or
You can try modifying your shortcut to Query Analyzer to something like
this:
"C:\Program Files\Microsoft SQL
Server\80\Tools\Binn\isqlw.exe" -SYourMachineNameHere -Usa -PTheSApwdGoesHer
e -dtempdb
I use the modified shortcut method to connect to a specific server and
connect to a specific database. However I don't know if you will be able to
do this if the user's default database is unavailable.
--
Keith
"Sameer Premji via SQLMonster.com" <forum@.SQLMonster.com> wrote in message
news:3c315b71f1a74a548e1b9c93ad0da038@.SQLMonster.com...
> Hello,
> I had installed SQL Server 2000 locally on my machine and I had 2 security
> logins: -
> 1. sa - default database was set to dbTest
> 2. mydomain\myusername - default database was set to dbTest
> The thing is, "dbTest" was deleted due to some testing and now when I try
> to connect to my SQL Server with Enterprise Manager, Login fails as the
> default database is missing.
> Is there a way I can register back my server ?
> Thanks,
> Sam.
> --
> Message posted via http://www.sqlmonster.com|||The shortcut didn't work.
How do I use osql.exe because double-clicking on it, vanishes and what is
the statement ?
--
Message posted via http://www.sqlmonster.com|||Since osql is a command line tool you need to
Start | Run | cmd <enter>
osql /? <enter>
--
Keith
"Sameer Premji via SQLMonster.com" <forum@.SQLMonster.com> wrote in message
news:2313ae62041a424caca786036f7b4385@.SQLMonster.com...
> The shortcut didn't work.
> How do I use osql.exe because double-clicking on it, vanishes and what is
> the statement ?
> --
> Message posted via http://www.sqlmonster.com

Friday, February 24, 2012

can't modify table in SMS...timeout expired?

Hi: I'm trying to add a field to a table by modifying it in Management
Studio. I'm running SQLSMS locally on the server.
When I try to save the table I get an error
"Post-Save Notifications...
[table name]
- Unable to modify table.
Timeout expired. The timeout period elapsed prior to completion of the
operation or the server is not responding."
The table currently has 5454 rows in it.
geek-y-guy (noone@.nowhere.org) writes:
> Hi: I'm trying to add a field to a table by modifying it in Management
> Studio. I'm running SQLSMS locally on the server.
That is a very dangerous function, which has serious bugs and shortcomings.
I strongly recommend to use ALTER TABLE statements to change your tables.
Or, at the very least, never, I say NEVER, save directly to implement
a change, but always generate a script and perform these modifications:
o Remove all BEGIN and COMMIT TRANSACTION except for the first and last.
o Wrap all batches in IF @.@.trancount > 0 BEGIN ... END
o Change all WITH NOCHECK to WITH CHECK.
And be very careful to check that the script only include the
changes you want to make. There are bugs that can cause discarded
changes to be includd.

> When I try to save the table I get an error
> "Post-Save Notifications...
> [table name]
> - Unable to modify table.
> Timeout expired. The timeout period elapsed prior to completion of the
> operation or the server is not responding."
> The table currently has 5454 rows in it.
Under Tools->Options there is a timeout for the Designers you can
change, if you insist on using that function. But if you run the script
from a query window,the timeout is not an issue.
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

Sunday, February 19, 2012

Can't login into SQL Server Database

Hey
I get the following error when trying to connect to my named instance Sql
Server running locally on my laptop. Does anyone know how to resolve this
I get the following error : Login failed for user:acw
Here is my code:
SqlConnection sConn = new SqlConnection(server=ACLAPTOP\ACSQLSERVE
R;User
id=acw; Password=;Database=BookSpot);
Thanks,
AlAl
Open QA and try to log in with the user. Do you get the same error?
"Al Wilkerson" <ac527@.comcast.net> wrote in message
news:7aCdnUdO-Ipm37zfRVn-gA@.comcast.com...
> Hey
> I get the following error when trying to connect to my named instance Sql
> Server running locally on my laptop. Does anyone know how to resolve this
> I get the following error : Login failed for user:acw
> Here is my code:
> SqlConnection sConn = new SqlConnection(server=ACLAPTOP\ACSQLSERVE
R;User
> id=acw; Password=;Database=BookSpot);
>
> Thanks,
> --
> Al
>|||I assume this is C# code. Did you give this user a blank password?
Double-check the password for this user and the rights/roles granted to this
user in EM. I assume your connection string is properly quoted (or it
wouldn't even compile for you). Finally, are you using Integrated Security
or SQL Server Authentication?
Thx
Mike C.
"Al Wilkerson" <ac527@.comcast.net> wrote in message
news:7aCdnUdO-Ipm37zfRVn-gA@.comcast.com...
> Hey
> I get the following error when trying to connect to my named instance Sql
> Server running locally on my laptop. Does anyone know how to resolve this
> I get the following error : Login failed for user:acw
> Here is my code:
> SqlConnection sConn = new SqlConnection(server=ACLAPTOP\ACSQLSERVE
R;User
> id=acw; Password=;Database=BookSpot);
>
> Thanks,
> --
> Al
>