Results 1 to 5 of 5
  1. #1
    Join Date
    Feb 2003
    Posts
    7

    Unanswered: Scheduled DTS + odbc with drive mapping

    Hi, thanks for reading my message.

    My company is running SQL Server 2000, and I need to have a DTS scheduled to run every night that extracts data from our other TimberLine database. The connection to this Timberline database is done through an ODBC which uses a mapped drive to the local database directory of the database.

    Now, this mapping is performed only when somebody logs onto the server, therefore manually running the DTS is no problem.

    The problem is that when I schedule the DTS, the system does not know where to find the local database directory of the TimberLine system, because the local database dir is not mapped to a drive. Therefore I get an error called "TimberLine ODBC drive is not activated".. This is because the ODBC cannot find the local dbase dir, because the drive is not mapped..

    Does anyone know a solution for this? Maybe something like mapping a drive as a system service or something?

  2. #2
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Did you try UNC file path?

    Why don't you have the drive mapped?

    And if it's a database, aren't you using named pipes or tcp/ip?
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  3. #3
    Join Date
    Jan 2004
    Posts
    1

    Re: Scheduled DTS + odbc with drive mapping

    Originally posted by sirorange
    Does anyone know a solution for this? Maybe something like mapping a drive as a system service or something?
    If the Workstation you are running this from is a Windows NT/2000/XP box, you could login, let the login script map the drive, and then lock the computer. You can lock the computer by pressing CTRL + ALT + DEL and then clicking "Lock Computer."

    This will not log you out, so your drives will still be present.

  4. #4
    Join Date
    Dec 2003
    Posts
    31
    1)configure the sql agent service to run under domain/user and not local system, create a sql job that execute the DTS using dtsrun utility, schedule the job.
    or
    2) run the DTS from windows schedule task as batch command or any other script

  5. #5
    Join Date
    Jan 2004
    Posts
    10

    Re: Scheduled DTS + odbc with drive mapping

    Originally posted by sirorange
    Hi, thanks for reading my message.

    My company is running SQL Server 2000, and I need to have a DTS scheduled to run every night that extracts data from our other TimberLine database. The connection to this Timberline database is done through an ODBC which uses a mapped drive to the local database directory of the database.

    Now, this mapping is performed only when somebody logs onto the server, therefore manually running the DTS is no problem.

    The problem is that when I schedule the DTS, the system does not know where to find the local database directory of the TimberLine system, because the local database dir is not mapped to a drive. Therefore I get an error called "TimberLine ODBC drive is not activated".. This is because the ODBC cannot find the local dbase dir, because the drive is not mapped..

    Does anyone know a solution for this? Maybe something like mapping a drive as a system service or something?
    create a batch file with following

    REM DELETE EXISTING MAP
    net use z: /delete
    REM CREATE Z: MAP DRIVE
    net use z: \\server\path /user:YOUR_NETWORK_ID password /delete



    Use a os command step in SQL AgentJob and call above batch file in it.
    and run it as first step before DTS step

    amit

Posting Permissions

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