Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2004
    Location
    BC - It's the place to be.
    Posts
    13

    Red face Unanswered: simple osql problem

    Hello people,

    I use SQL Server 7, and it's running ok under my Win2000 Pro. I have use most of everything fine until I used osql:

    I issue osql from the command prompt, it asks for my password and I give it then it strangely gives me a "login failed" error for my username.

    How come osql fails my login when I can do the rest of my actions in the Win2k GUI just fine?

    My Sql Server is set to use my Win2K user protocols so when I log into Win2K, SQL Server uses this login also.

    Thanks for your help.

  2. #2
    Join Date
    Jan 2004
    Location
    BC - It's the place to be.
    Posts
    13

    simple osql problem

    I was able to go around the problem by creating a SQL user account and asigning it the same roles but I still can't get osql to recognize my NT (win2k) log-in.

    I hope somebody can help.

  3. #3
    Join Date
    Sep 2003
    Posts
    522
    you need to specify -E switch for windows authentication to be used

  4. #4
    Join Date
    Jan 2004
    Location
    BC - It's the place to be.
    Posts
    13

    Wink

    Originally posted by ms_sql_dba
    you need to specify -E switch for windows authentication to be used


    So I have just read.

    osql uses SQL Server logins by default and authenticated (NT) logins can be served using

    C:>osql -E

    Life is good. Many thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •