Re: Script starten unter anderm Benutzer

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Berger Hans (BergerHans_at_discussions.microsoft.com)
Date: 02/10/05


Date: Thu, 10 Feb 2005 06:21:03 -0800

Hall Christoph

Werde ich testen. Vielleicht gibt es eine 'neuere' Version dieses SETUSER

Gruss
Hans

"Christoph Muthmann" wrote:

> Berger Hans wrote:
> > Hallo
> >
> > Ich bin mit SA Rechten beim SQL Server angemeldet. Habe ein Script
> > mit ca. 3000 Zeilen zur Modifikation einer DB. Die Tabellen gehören
> > nicht dem DBO sondern einem 'Domainuser\Testuser'. Damit ich die
> > Tabellen überhaupt sehen kann, müsste ich dem Script bei allen
> > Tabellen den Owner voransetzen.
> >
> > Kann ich dieses Script unter einem anderen Benutzer starten ohne mich
> > aber anders beim SQL Server anzumelden? Die Registrierung bleibt auf
> > der Serverrolle SA.
> >
> > Dieses Prozedere wäre manchmal schneller
>
> Hallo Hans,
> kennst Du SETUSER?
>
> Laut BOL soll damit das gewünschte erreicht werden. Da gibt es aber
> noch folgenden Hinweis:
>
> Wichtig SETUSER ist in Microsoft® SQL Server™ 2000 nur aus Gründen der
> Abwärtskompatibilität enthalten und sollte nicht verwendet werden.
> SETUSER wird in einer künftigen Version von SQL Server möglicherweise
> nicht mehr unterstützt.
>
>
>
> Einen schönen Tag noch,
> Christoph
> --
> (Please post ALL replies to the newsgroup only unless indicated
> otherwise)
>
>



Relevant Pages

  • Re: SQL Security
    ... except I'm having problems making it work in a script. ... ;Set properties of DB objects and open connection to database ... > from Books Online (within the SQL Server program group): ... > communicate with SQL Server. ...
    (microsoft.public.sqlserver.server)
  • Re: ActiveX script works in DTS but not in job, why?
    ... Account that SQL Agent runs under and it is a Local Admin on the box. ... As another test I saved the script as a .vbs file and tried running it, ... Microsoft OLE DB Provider for SQL Server ... that would be since I need to be able to load DTS packages from either a SQL ...
    (microsoft.public.sqlserver.dts)
  • Re: ActiveX script works in DTS but not in job, why?
    ... Peter DeBetta, MVP - SQL Server ... As another test I saved the script as a .vbs file and tried running it, ... Microsoft OLE DB Provider for SQL Server ... 2000 databases including DTS packages. ...
    (microsoft.public.sqlserver.dts)
  • Re: Maintain production DB with changes from development DB
    ... Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP) www.SQLDTS.com - The site for all your DTS needs. ... Or will I have to write a script to update all 4 servers? ...
    (microsoft.public.sqlserver.dts)
  • Re: tsql script to invoke another script
    ... Wayne Snyder, MCDBA, SQL Server MVP ... I support the Professional Association of SQL Server and it's community of SQL Server professionals. ... > From the OSQL Utility topic in the latest SQL 2000 Books Online:> ... Another method to run multiple script files is with a FOR> command. ...
    (microsoft.public.sqlserver.programming)