Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««12

SELECT from OPENDATASOURCE error Expand / Collapse
Author
Message
Posted Friday, February 15, 2013 12:55 PM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 9:55 AM
Points: 6,713, Visits: 11,747
The information you have provided does not compute. Are you sure your login has access to that table?

What does this return?

SELECT  *
FROM OPENDATASOURCE('SQLNCLI', 'Data Source=DESTSERVR\INSTANCE;Integrated Security=SSPI').TESTTBL.sys.tables
WHERE name = 'TBLNAME';

What about when using a username and password?

SELECT  *
FROM OPENDATASOURCE('SQLNCLI', 'Data Source=DESTSERVR\INSTANCE;user id=test;password=psw').TESTTBL.sys.tables
WHERE name = 'TBLNAME';



__________________________________________________________________________________________________
There are no special teachers of virtue, because virtue is taught by the whole community. --Plato

Believe you can and you're halfway there. --Theodore Roosevelt

Everything Should Be Made as Simple as Possible, But Not Simpler --Albert Einstein

The significant problems we face cannot be solved at the same level of thinking we were at when we created them. --Albert Einstein

1 apple is not exactly 1/8 of 8 apples. Because there are no absolutely identical apples. --Giordy
Post #1420728
Posted Tuesday, February 19, 2013 6:52 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Today @ 6:35 AM
Points: 44, Visits: 188
The query works when I pass it user id and password, but it does not work when I use integrated security. Any idea how to get integrated security to work?


Post #1421623
Posted Tuesday, February 19, 2013 7:19 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 9:55 AM
Points: 6,713, Visits: 11,747
Define "does not work." Error message? Empty resultset? Remember, I cannot see what you see


__________________________________________________________________________________________________
There are no special teachers of virtue, because virtue is taught by the whole community. --Plato

Believe you can and you're halfway there. --Theodore Roosevelt

Everything Should Be Made as Simple as Possible, But Not Simpler --Albert Einstein

The significant problems we face cannot be solved at the same level of thinking we were at when we created them. --Albert Einstein

1 apple is not exactly 1/8 of 8 apples. Because there are no absolutely identical apples. --Giordy
Post #1421641
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse