Showing posts with label map. Show all posts
Showing posts with label map. Show all posts

Wednesday, March 28, 2012

Please help i can't connect....

Hi
I'm loged on Workstation as a user EUR\zzzz1 and i use different user
EUR\abc123 to map a drive on remote server SERVER2, SERVER2 is a domain
controler . It works.
On SERVER2 i have SQL Server 2000 with mixed mode authentication.
I have a user abc123 added in Active directory on SERVER2:
SERVER2\abc123. The same user is added in Sql Server with rights etc.
When i lounch Query Analyzer on my Workstation and select Sql
Authentication to use EUR\abc123 user i got message "[Microsoft][ODBC
SQL Server Driver][SQL Server]Login failed for user 'EUR\abc123'"
Why i have no access to sql server ?
regards
m
Hi
You must not use SQL Authentication, as it is a domain account, you need to
select NT Authentication when connecting.
Regards
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"marta" <grupy_d@.go2.pl> wrote in message
news:1127985222.430902.144700@.o13g2000cwo.googlegr oups.com...
> Hi
> I'm loged on Workstation as a user EUR\zzzz1 and i use different user
> EUR\abc123 to map a drive on remote server SERVER2, SERVER2 is a domain
> controler . It works.
> On SERVER2 i have SQL Server 2000 with mixed mode authentication.
> I have a user abc123 added in Active directory on SERVER2:
> SERVER2\abc123. The same user is added in Sql Server with rights etc.
> When i lounch Query Analyzer on my Workstation and select Sql
> Authentication to use EUR\abc123 user i got message "[Microsoft][ODBC
> SQL Server Driver][SQL Server]Login failed for user 'EUR\abc123'"
> Why i have no access to sql server ?
>
> regards
> m
>
|||Ok now i use windows NT Authentication and i can log in but this way
i'm connected to SERVER2 with user EUR\zzzz1 not abc123... I need to
connect using user abc123. How to do that ?
M.
|||Hi Marta
If EUR\abc123 has been added to the server as a login, you will need SQL
authentication to connect as that login. Are you sure you're using the
right password?
HTH
Kalen Delaney, SQL Server MVP
www.solidqualitylearning.com
"marta" <grupy_d@.go2.pl> wrote in message
news:1127989262.660929.186550@.o13g2000cwo.googlegr oups.com...
> Ok now i use windows NT Authentication and i can log in but this way
> i'm connected to SERVER2 with user EUR\zzzz1 not abc123... I need to
> connect using user abc123. How to do that ?
> M.
>
|||Of course i can map a drive using that pass.
The problem is : how to connect to sql server on remote server with
windows authentication, when i am logged on local workstation with
different user.
M
|||You could probably use "Run As" (right-click the shortcut/executable,
and choose "Run as..." from the menu) to run Query Analyzer under the
context of another user, and therefore be able to pass that security
ticket to the SQL Server when you use Windows Authentication. Runas.exe
can also be called from the command line w/ switches. I believe this
functionality is only available from the right-click menu on Windows
2003 and XP - 2000 contains the command line version.
Good luck,
Tony Sebion
"marta" <grupy_d@.go2.pl> wrote in message
news:1128002474.807122.247970@.g14g2000cwa.googlegr oups.com:

> Of course i can map a drive using that pass.
> The problem is : how to connect to sql server on remote server with
> windows authentication, when i am logged on local workstation with
> different user.
> M
|||you can always connect to the ipc share of remote user with the login/pw of
the user you want
NET USE \\REMOTEPUTER\IPC$ /USER:MYUSERNAME "MYPASSWORD"
now event hough your are logged on as user LOCALUSER...any connection to
remote puter will be as MYUSERNAME
get it ?
"marta" <grupy_d@.go2.pl> wrote in message
news:1128002474.807122.247970@.g14g2000cwa.googlegr oups.com...
> Of course i can map a drive using that pass.
> The problem is : how to connect to sql server on remote server with
> windows authentication, when i am logged on local workstation with
> different user.
> M
>
sql

Please help i can't connect....

Hi
I'm loged on Workstation as a user EUR\zzzz1 and i use different user
EUR\abc123 to map a drive on remote server SERVER2, SERVER2 is a domain
controler . It works.
On SERVER2 i have SQL Server 2000 with mixed mode authentication.
I have a user abc123 added in Active directory on SERVER2:
SERVER2\abc123. The same user is added in Sql Server with rights etc.
When i lounch Query Analyzer on my Workstation and select Sql
Authentication to use EUR\abc123 user i got message "[Microsoft][ODB
C
SQL Server Driver][SQL Server]Login failed for user 'EUR\abc123'"
Why i have no access to sql server ?
regards
mHi
You must not use SQL Authentication, as it is a domain account, you need to
select NT Authentication when connecting.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"marta" <grupy_d@.go2.pl> wrote in message
news:1127985222.430902.144700@.o13g2000cwo.googlegroups.com...
> Hi
> I'm loged on Workstation as a user EUR\zzzz1 and i use different user
> EUR\abc123 to map a drive on remote server SERVER2, SERVER2 is a domain
> controler . It works.
> On SERVER2 i have SQL Server 2000 with mixed mode authentication.
> I have a user abc123 added in Active directory on SERVER2:
> SERVER2\abc123. The same user is added in Sql Server with rights etc.
> When i lounch Query Analyzer on my Workstation and select Sql
> Authentication to use EUR\abc123 user i got message "[Microsoft][O
DBC
> SQL Server Driver][SQL Server]Login failed for user 'EUR\abc123'"
> Why i have no access to sql server ?
>
> regards
> m
>|||Ok now i use windows NT Authentication and i can log in but this way
i'm connected to SERVER2 with user EUR\zzzz1 not abc123... I need to
connect using user abc123. How to do that ?
M.|||Hi Marta
If EUR\abc123 has been added to the server as a login, you will need SQL
authentication to connect as that login. Are you sure you're using the
right password?
HTH
Kalen Delaney, SQL Server MVP
www.solidqualitylearning.com
"marta" <grupy_d@.go2.pl> wrote in message
news:1127989262.660929.186550@.o13g2000cwo.googlegroups.com...
> Ok now i use windows NT Authentication and i can log in but this way
> i'm connected to SERVER2 with user EUR\zzzz1 not abc123... I need to
> connect using user abc123. How to do that ?
> M.
>|||Of course i can map a drive using that pass.
The problem is : how to connect to sql server on remote server with
windows authentication, when i am logged on local workstation with
different user.
M|||You could probably use "Run As" (right-click the shortcut/executable,
and choose "Run as..." from the menu) to run Query Analyzer under the
context of another user, and therefore be able to pass that security
ticket to the SQL Server when you use Windows Authentication. Runas.exe
can also be called from the command line w/ switches. I believe this
functionality is only available from the right-click menu on Windows
2003 and XP - 2000 contains the command line version.
Good luck,
Tony Sebion
"marta" <grupy_d@.go2.pl> wrote in message
news:1128002474.807122.247970@.g14g2000cwa.googlegroups.com:

> Of course i can map a drive using that pass.
> The problem is : how to connect to sql server on remote server with
> windows authentication, when i am logged on local workstation with
> different user.
> M|||you can always connect to the ipc share of remote user with the login/pw of
the user you want
NET USE \\REMOTEPUTER\IPC$ /USER:MYUSERNAME "MYPASSWORD"
now event hough your are logged on as user LOCALUSER...any connection to
remote puter will be as MYUSERNAME
get it ?
"marta" <grupy_d@.go2.pl> wrote in message
news:1128002474.807122.247970@.g14g2000cwa.googlegroups.com...
> Of course i can map a drive using that pass.
> The problem is : how to connect to sql server on remote server with
> windows authentication, when i am logged on local workstation with
> different user.
> M
>

Monday, February 20, 2012

pivot on dynamic columns

I have a table with 40k terms and I need to map these to a set of objects where each object is represented as a column(tinyint). The object/column name is represented as a guid and columns are added/removed dynamically to support new objects for a set of terms.

I can get the rows needed:

guid1 guid2 guid3 guid4 guid5
================================
0 1 1 0 0
0 1 1 0 1

I think I need to then convert this set of rows to a table which I can join to the object runtime table to start these objects if the column has a count/sum greater than 0. This is the table I think I need in order to join on guids to the runtime table:

NAME Count
===========
guid1 0
guid2 2
guid3 2
guid4 0
guid5 1

I don't know how to construct this table for the former table. I think it may be a pivot table, but I don't know. I have the column names:

SELECT NAME
FROM SYSCOLUMNS
WHERE ID = OBJECT_ID(#Temp)
ORDER BY COLID

NAME is a sysname, which doesn't seem to cast into a guid, also a problem when joining the runtime table with this #Temp table.

I also don't want to use a cursor to construct a table.

Thanks for any help,
Jameshttp://www.sqlteam.com/item.asp?ItemID=2955

HTH