Thursday, March 29, 2012
Error 18456 Login failed for user domain\user
service packs and critical updates are current on the server and clients.
SQL Server uses mixed authentification and runs under a domain account, the
users login with their domain\username, or at least they used to. Nobody
seems to know exactly when this stopped working, and of course, nobody said
anything until this week. Attempting to login now fails with error 18456
login failed for user domain\username. I've foolwed all the debugging info I
can find on Microsofts site. Running osql, I can log in using windows
authentification and SQL Server accounts with no problem. Trying to use
domain\username fails. I've been through everything from DNS to SQL Server
settings to client settings with no resolution. Anybody have an idea where
else to look?
Any hints would be greatly appreciated.
BruceHi Bruce,
Thank you for use the newsgroup and it is my pleasure to help you with you
issue.
From you information, you application, which used to work fine now got
error message
Could you check if the ODBC connection is made through the standard
security of SQL Server of trusted connection security? Is the SQL Server
authentication mode match the security option of ODBC connection? Could you
using the Query Analyzer to connect the SQL Server? That is, if you use the
standard security, such as use the account 'sa', when using 'sa' in Query
Analyzer, could it connect the SQL Server. When it is a Windows
authentication, when connect the SQL Server by Query Analyzer, you should
choose the Windows Authenticatin in the Query Analyzer.
Looking forward to your response. Thanks.
Best regards
Baisong Wei
Microsoft Online Support
----
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
Please reply to newsgroups only. Thanks.|||Baisong:
Using Windows Authentification or Sql Server Authentification both work
fine.
If I'm logged into the domain I can run
osql -S SERVER -d Test -E
or
osql -S SERVER -d Test -U SA -P password
with no problem I can connect through Query analyzer either way.
if I try
osql -S SERVER -d Test -U domain\username -P password
it fails with the message Error 18456 Login failed for user domain\username.
The application we are using was working with the domain\username login, I
can't use Windows Integrated security with it, and I really do not want to
setup and manage 50+ SQL Server accounts. I am assuming that something has
changed in the authentification / delegation process and am working through
that now. As far as I can tell nothing has changed, but obviously something
has.
Any ideas would be appreciated.
Bruce
"Baisong Wei[MSFT]" <v-baiwei@.online.microsoft.com> wrote in message
news:EKzqmHs7DHA.1992@.cpmsftngxa07.phx.gbl...
> Hi Bruce,
> Thank you for use the newsgroup and it is my pleasure to help you with you
> issue.
> From you information, you application, which used to work fine now got
> error message
> Could you check if the ODBC connection is made through the standard
> security of SQL Server of trusted connection security? Is the SQL Server
> authentication mode match the security option of ODBC connection? Could
you
> using the Query Analyzer to connect the SQL Server? That is, if you use
the
> standard security, such as use the account 'sa', when using 'sa' in Query
> Analyzer, could it connect the SQL Server. When it is a Windows
> authentication, when connect the SQL Server by Query Analyzer, you should
> choose the Windows Authenticatin in the Query Analyzer.
> Looking forward to your response. Thanks.
> Best regards
> Baisong Wei
> Microsoft Online Support
> ----
> Get Secure! - www.microsoft.com/security
> This posting is provided "as is" with no warranties and confers no rights.
> Please reply to newsgroups only. Thanks.
>|||Hi Bruce,
Thank you for your update.
For the 'osql -S SERVER -d Test -U domain\username -P password' which
failed with the error message, could you check if it is a valid SQL Server
login? You could check it by unfolder the database, unfoulder the
'Security', then in the logins, is the above 'domain\username' in the
logins?
Looking forward to your response. Thanks.
Best regards
Baisong Wei
Microsoft Online Support
----
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
Please reply to newsgroups only. Thanks.|||Yes, it is a valid login and the password is correct. The account also has
privledges (dbowner + our SQL_Admin role) to access the test database. It
works fine with Windows Integrated Security, so I don't think it is related
to SQL Server privledges, my guess is that something has changed in the
authentification authorization or delegation between the domain and the
server or the client.
The client computers are running MDAC 2.8 or 2.7RTM, and component checker
says they are current and all is well. Servers and clients are current on
patches, SQL Server is current. I've been throgh every article I can find on
MSDN that remotely deals with this error, and everything seems to check out.
I'm sure there is some little thing I'm overlooking, but I'm totally stumped
at this point.
Bruce
"Baisong Wei[MSFT]" <v-baiwei@.online.microsoft.com> wrote in message
news:ZZofg867DHA.2508@.cpmsftngxa07.phx.gbl...
> Hi Bruce,
> Thank you for your update.
> For the 'osql -S SERVER -d Test -U domain\username -P password' which
> failed with the error message, could you check if it is a valid SQL Server
> login? You could check it by unfolder the database, unfoulder the
> 'Security', then in the logins, is the above 'domain\username' in the
> logins?
> Looking forward to your response. Thanks.
> Best regards
> Baisong Wei
> Microsoft Online Support
> ----
> Get Secure! - www.microsoft.com/security
> This posting is provided "as is" with no warranties and confers no rights.
> Please reply to newsgroups only. Thanks.
>|||Bruce,
The exact same thing happen here - ODBC connections that had worked
stopped working. We THINK it was related to installing patches but not
the full SP3a running on SQL 2000. We know installing SP3a fixed it.
An easy test to see if it's the same problem - in the ODBC config, set
the server name servername.subdomain.domain.?, check with the network
people for the full name if you need to.
If it works then maybe install/reinstall SP3a on the server will help.
SQL DBA in Richmond, VA
PS - I know 4 locales that suddenly experienced this same problem.
Maybe triggered by Windows critical update?
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!
Thursday, March 22, 2012
Error 15274: Access to the remote server is denied because the current security context is not t
Hi,
I have a stored procedure servicing a queue (sql 2005).
The stored procedure updates some data in a different server and database.
If the queue contains messages and I execute manually the stored procedure, I don't have any problem at all.
However, if I set the queue to use the same stored procedure, it gives me the following error:
Error 15274: Access to the remote server is denied because the current security context is not trusted.
Any ideas?
Thanks,
Aron
Please, see if the following link to a similar question on this forum has the answer for your particular scenario: https://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1064271&SiteID=1
If the answers in this thread do not help you to resolve the problem, please let us know and we will be glad to provide further assistance.
Thanks a lot,
-Raul Garcia
SDE/T
SQL Server Engine
Error 15023: User already exists in current database
Can someone please help me with this problem.
I'm trying to add a new User to a particular database but
keep getting the above error, telling me that the user
already exists in the current database. When I look in
the Permissions in the database Properties, the only
user/role is public.
What can I do?
Maree.You have orphaned users to the syslogins table in the master database (EM doesn't show such). I
assume you did an attach or restore of the database...
Read about sp_change_users_login and/or use a GUI on top of the proc available at www.dbmaint.com,
free utilities.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as ugroup=microsoft.public.sqlserver
"Maree" <eeramstu@.yahoo.com.au> wrote in message news:0f8001c387b9$7d459ec0$a101280a@.phx.gbl...
> Dear Group,
> Can someone please help me with this problem.
> I'm trying to add a new User to a particular database but
> keep getting the above error, telling me that the user
> already exists in the current database. When I look in
> the Permissions in the database Properties, the only
> user/role is public.
> What can I do?
> Maree.|||Thank you so much Tibor!!
>--Original Message--
>You have orphaned users to the syslogins table in the
master database (EM doesn't show such). I
>assume you did an attach or restore of the database...
>Read about sp_change_users_login and/or use a GUI on top
of the proc available at www.dbmaint.com,
>free utilities.
>--
>Tibor Karaszi, SQL Server MVP
>Archive at: http://groups.google.com/groups?oi=djq&as
ugroup=microsoft.public.sqlserver
>
>"Maree" <eeramstu@.yahoo.com.au> wrote in message
news:0f8001c387b9$7d459ec0$a101280a@.phx.gbl...
>> Dear Group,
>> Can someone please help me with this problem.
>> I'm trying to add a new User to a particular database
but
>> keep getting the above error, telling me that the user
>> already exists in the current database. When I look in
>> the Permissions in the database Properties, the only
>> user/role is public.
>> What can I do?
>> Maree.
>
>.
>sql
Error 15023: User already exists in current database
database
then try following:
delete the user from database-folder--> user-tab and also delete user
for security-folder--> logins
and then create same user againYou can use sp_change_users_login to fix that. Here are some links that may
help:
http://www.databasejournal.com/feat...cle.php/2228611
Transferring Logins
http://www.support.microsoft.com/?id=246133 How To Transfer Logins and
Passwords Between SQL Servers
http://www.support.microsoft.com/?id=298897 Mapping Logins & SIDs after a
Restore
http://www.dbmaint.com/SyncSqlLogins.asp Utility to map logins to
users
http://www.support.microsoft.com/?id=168001 User Logon and/or Permission
Errors After Restoring Dump
http://www.support.microsoft.com/?id=240872 How to Resolve Permission
Issues When a Database Is Moved Between SQL Servers
Andrew J. Kelly
SQL Server MVP
"Sonal Chauhan" <sj2909@.yahoo.com> wrote in message
news:1e44a73a.0406071204.6d79cfb7@.posting.google.com...
> If you get this message : Error 15023: User already exists in current
> database
> then try following:
> delete the user from database-folder--> user-tab and also delete user
> for security-folder--> logins
> and then create same user again
error 15023 after restore db on different server (user dbo)
If you go to the user section of the db that you just restored, and delete all of the users, then go to the security options and allow these users to see it again, it should fix your problem.
There is a script somewhere that will resolve this, i will try to find and post.
Scooter McFlyhi,
but how i ll remove dbo in database.it is not removing anyway showing error that:
The selected use canot be dropped because the user owns objects
-Ashwini
Originally posted by scootermcfly
That is a user role, or user account error, and it probably already exists in the current system.
If you go to the user section of the db that you just restored, and delete all of the users, then go to the security options and allow these users to see it again, it should fix your problem.
There is a script somewhere that will resolve this, i will try to find and post.
Scooter McFly|||http://support.microsoft.com/default.aspx?scid=kb;en-us;819261 to resolve the issue.|||I would suggest EXECUTE sp_change_users_login 'Auto_Fix' (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/tsqlref/ts_sp_ca-cz_8qzy.asp) myself.
-PatP|||If you want to drop a user from a db where it owns objects, you can change object ownership to dbo (or any other user - NOT RECOMMENDED) and go on with the drop.|||yaa,solved
Error 15023 : User or role "abc" already exists in current database
particular user account created. However, after
restoration, I am not able to see the user account in the
User/Logins item and not able to create a new account with
the same name and making it the db_owner at the same time.
The system gives me this error.
Using sp_helpusers for this database, I realised that
there is a user account with the name "abc" but there is
no value in the "loginName" & "DefDBName" fields.
Please advise how I can sync this.
Thanks.It sounds as though the user is orphaned
Exec sp_change_users_login 'Report'
will show you this info
You can use the 'Update_One' parameter to match things up
OR you could simply use
Exec sp_revokedbaccess 'Name in DB'
EXEC sp_grantdbaccess [@.loginame =] 'login'
[,[@.name_in_db =] 'name_in_db' [OUTPUT]]
--
Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org
"Dara" <dara.lim@.ogilvy.com> wrote in message
news:075e01c35bf0$2360f020$a501280a@.phx.gbl...
> I have restored a database which has tables belonging to a
> particular user account created. However, after
> restoration, I am not able to see the user account in the
> User/Logins item and not able to create a new account with
> the same name and making it the db_owner at the same time.
> The system gives me this error.
> Using sp_helpusers for this database, I realised that
> there is a user account with the name "abc" but there is
> no value in the "loginName" & "DefDBName" fields.
> Please advise how I can sync this.
> Thanks.|||Hi Dara,
If you have a login for that user on your server you can use the
sp_change_users_login stored procedure to fix your problems. See Books
Online for the details.
--
Jacco Schalkwijk MCDBA, MCSD, MCSE
Database Administrator
Eurostop Ltd.
"Dara" <dara.lim@.ogilvy.com> wrote in message
news:075e01c35bf0$2360f020$a501280a@.phx.gbl...
> I have restored a database which has tables belonging to a
> particular user account created. However, after
> restoration, I am not able to see the user account in the
> User/Logins item and not able to create a new account with
> the same name and making it the db_owner at the same time.
> The system gives me this error.
> Using sp_helpusers for this database, I realised that
> there is a user account with the name "abc" but there is
> no value in the "loginName" & "DefDBName" fields.
> Please advise how I can sync this.
> Thanks.
Monday, March 19, 2012
Error 1222 Lock Request time out period exceed
the Enterprise Manager. This is a SQL2000 running on Windows2000. Does
anyone know what causes this and how to fix it? I also get this error
sometimes when I run a crystal report in my C# application.
Thanks,
AlphaA transaction is being blocked to acquire a lock because another transaction
already locked the resource.
See "Customizing the Lock Time-out" in BOL.
AMB
"Alpha" wrote:
> Hi, I'm getting this error when I tried to click on the Current Activity in
> the Enterprise Manager. This is a SQL2000 running on Windows2000. Does
> anyone know what causes this and how to fix it? I also get this error
> sometimes when I run a crystal report in my C# application.
> Thanks,
> Alpha|||Do not use the GUI. Instead, get used to sp_who, sp_who2 or sp_who1 in Query
Analyzer.
"Alpha" <Alpha@.discussions.microsoft.com> wrote in message
news:16FC85B9-57C8-4906-AC47-3B9E826D9A79@.microsoft.com...
> Hi, I'm getting this error when I tried to click on the Current Activity
> in
> the Enterprise Manager. This is a SQL2000 running on Windows2000. Does
> anyone know what causes this and how to fix it? I also get this error
> sometimes when I run a crystal report in my C# application.
> Thanks,
> Alpha|||Thank you. That was very helpful.
"Alejandro Mesa" wrote:
> A transaction is being blocked to acquire a lock because another transaction
> already locked the resource.
> See "Customizing the Lock Time-out" in BOL.
>
> AMB
> "Alpha" wrote:
> > Hi, I'm getting this error when I tried to click on the Current Activity in
> > the Enterprise Manager. This is a SQL2000 running on Windows2000. Does
> > anyone know what causes this and how to fix it? I also get this error
> > sometimes when I run a crystal report in my C# application.
> >
> > Thanks,
> > Alpha
Error 1222 Lock request
when trying to open SQL Server Current Activity folder
under the Management folder to display locks.
This was caused by several locks.
This made it very difficult to resolve the locks without
the GUI.
What would cause the SQL Server GUI to be unable to
display the locks?
Thank You,
Mickey Autry
mautry@.ev1.netThat's know to happen when you have a lot of locks. You can
use Query Analyzer to execute sql statments and system
stored procedures to view the same info you look at in the
Current Activity part of Enterprise Manager. Check books
online for more information on sp_lock, sp_who, sp_who2 and
the sysprocesses table.
-Sue
On Tue, 23 Sep 2003 15:41:17 -0700, "Mickey"
<mautry@.ev1.net> wrote:
>I received the Error 1222 lock request time out period
>when trying to open SQL Server Current Activity folder
>under the Management folder to display locks.
>This was caused by several locks.
>This made it very difficult to resolve the locks without
>the GUI.
>What would cause the SQL Server GUI to be unable to
>display the locks?
>Thank You,
>Mickey Autry
>mautry@.ev1.net
>
Sunday, February 19, 2012
Error - Application uses a value of the wrong type for the current operation
SELECT TowerNumber, TowerNumber AS CountEntriesPerTowerNumber
FROM tblTowers
WHERE (ReadingDate BETWEEN @.BeginningMonth AND @.EndingMonth) AND
(LocationID = @.LocationID) AND (SystemID = @.SystemID)
ORDER BY LocationID, SystemID, TowerNumber
When I use the same query and add group by, I get the error - Application
uses a value of the wrong type for the current operation
SELECT TowerNumber, COUNT(TowerNumber) AS CountEntriesPerTowerNumber
FROM tblTowers
WHERE (ReadingDate BETWEEN @.BeginningMonth AND @.EndingMonth)
GROUP BY TowerNumber, LocationID, SystemID
HAVING (LocationID = @.LocationID) AND (SystemID = @.SystemID)
ORDER BY LocationID, SystemID, TowerNumber
How do I get past this error?
ThanksHi,
Have u used any variable with datatype uniqueidentifier.If yes then
change the datatype.
from
Doller|||Not using uniqueidentifier.
I do have a field that is an identity field but it is not in the query and I
have never run into this before.
Plus the first query does work the second does not.
"doller" <sufianarif@.gmail.com> wrote in message
news:1128420745.167906.89260@.o13g2000cwo.googlegroups.com...
> Hi,
> Have u used any variable with datatype uniqueidentifier.If yes then
> change the datatype.
> from
> Doller
>|||Hi Craig,
Welcome to use MSDN Managed Newsgroup!
From your descriptions, I understood adding GROUP BY will lead to the error
message "Application uses a value of the wrong type for the current
operation". If I have misunderstood your concern, please feel free to point
it out.
Based on my knowledge, this could be caused by various reasons and let
perform the troubleshooting step by step.
1. Check the length of parameters. The error could if the length of the
data passed to the parameter exceeds the
maximum size of the parameter or field.
2. Use the Profiler to trace what was inserted into SQL Server
3. If we replace all the parameters with real value and execute the
replaced statements in Query Analyzer, will it report the error message?
Sincerely yours,
Michael Cheng
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================This posting is provided "AS IS" with no warranties, and confers no rights.
Error - Application uses a value of the wrong type for the current operation
SELECT TowerNumber, TowerNumber AS CountEntriesPerTowerNumber
FROM tblTowers
WHERE (ReadingDate BETWEEN @.BeginningMonth AND @.EndingMonth) AND
(LocationID = @.LocationID) AND (SystemID = @.SystemID)
ORDER BY LocationID, SystemID, TowerNumber
When I use the same query and add group by, I get the error - Application
uses a value of the wrong type for the current operation
SELECT TowerNumber, COUNT(TowerNumber) AS CountEntriesPerTowerNumber
FROM tblTowers
WHERE (ReadingDate BETWEEN @.BeginningMonth AND @.EndingMonth)
GROUP BY TowerNumber, LocationID, SystemID
HAVING (LocationID = @.LocationID) AND (SystemID = @.SystemID)
ORDER BY LocationID, SystemID, TowerNumber
How do I get past this error?
ThanksHi,
Have u used any variable with datatype uniqueidentifier.If yes then
change the datatype.
from
Doller|||Not using uniqueidentifier.
I do have a field that is an identity field but it is not in the query and I
have never run into this before.
Plus the first query does work the second does not.
"doller" <sufianarif@.gmail.com> wrote in message
news:1128420745.167906.89260@.o13g2000cwo.googlegroups.com...
> Hi,
> Have u used any variable with datatype uniqueidentifier.If yes then
> change the datatype.
> from
> Doller
>|||Hi Craig,
Welcome to use MSDN Managed Newsgroup!
From your descriptions, I understood adding GROUP BY will lead to the error
message "Application uses a value of the wrong type for the current
operation". If I have misunderstood your concern, please feel free to point
it out.
Based on my knowledge, this could be caused by various reasons and let
perform the troubleshooting step by step.
1. Check the length of parameters. The error could if the length of the
data passed to the parameter exceeds the
maximum size of the parameter or field.
2. Use the Profiler to trace what was inserted into SQL Server
3. If we replace all the parameters with real value and execute the
replaced statements in Query Analyzer, will it report the error message?
Sincerely yours,
Michael Cheng
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
========================================
=============
This posting is provided "AS IS" with no warranties, and confers no rights.
Error - Application uses a value of the wrong type for the current operation
SELECT TowerNumber, TowerNumber AS CountEntriesPerTowerNumber
FROM tblTowers
WHERE (ReadingDate BETWEEN @.BeginningMonth AND @.EndingMonth) AND
(LocationID = @.LocationID) AND (SystemID = @.SystemID)
ORDER BY LocationID, SystemID, TowerNumber
When I use the same query and add group by, I get the error - Application
uses a value of the wrong type for the current operation
SELECT TowerNumber, COUNT(TowerNumber) AS CountEntriesPerTowerNumber
FROM tblTowers
WHERE (ReadingDate BETWEEN @.BeginningMonth AND @.EndingMonth)
GROUP BY TowerNumber, LocationID, SystemID
HAVING (LocationID = @.LocationID) AND (SystemID = @.SystemID)
ORDER BY LocationID, SystemID, TowerNumber
How do I get past this error?
Thanks
Hi,
Have u used any variable with datatype uniqueidentifier.If yes then
change the datatype.
from
Doller
|||Not using uniqueidentifier.
I do have a field that is an identity field but it is not in the query and I
have never run into this before.
Plus the first query does work the second does not.
"doller" <sufianarif@.gmail.com> wrote in message
news:1128420745.167906.89260@.o13g2000cwo.googlegro ups.com...
> Hi,
> Have u used any variable with datatype uniqueidentifier.If yes then
> change the datatype.
> from
> Doller
>
|||Hi Craig,
Welcome to use MSDN Managed Newsgroup!
From your descriptions, I understood adding GROUP BY will lead to the error
message "Application uses a value of the wrong type for the current
operation". If I have misunderstood your concern, please feel free to point
it out.
Based on my knowledge, this could be caused by various reasons and let
perform the troubleshooting step by step.
1. Check the length of parameters. The error could if the length of the
data passed to the parameter exceeds the
maximum size of the parameter or field.
2. Use the Profiler to trace what was inserted into SQL Server
3. If we replace all the parameters with real value and execute the
replaced statements in Query Analyzer, will it report the error message?
Sincerely yours,
Michael Cheng
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
================================================== ===
This posting is provided "AS IS" with no warranties, and confers no rights.