Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Database & SysAdmin
  3. Database
  4. Trying to add data connection but sql doesn't like me tonight

Trying to add data connection but sql doesn't like me tonight

Scheduled Pinned Locked Moved Database
databasesql-serversysadminhelp
5 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    tonyonlinux
    wrote on last edited by
    #1

    For some reason I can't add my dataconnect. I click on add connection select sql server then I browse to the programfiles/...sqlserver/data and click on books.mdf it tells me every single time that the file is in use. But I don't know of any program that would be using it. I'm running the server on my desktop simply to try and learn it and do a little programming with it. i can't seem to understand why it will not access that database. Any help would be great thanks...

    W M R 3 Replies Last reply
    0
    • T tonyonlinux

      For some reason I can't add my dataconnect. I click on add connection select sql server then I browse to the programfiles/...sqlserver/data and click on books.mdf it tells me every single time that the file is in use. But I don't know of any program that would be using it. I'm running the server on my desktop simply to try and learn it and do a little programming with it. i can't seem to understand why it will not access that database. Any help would be great thanks...

      W Offline
      W Offline
      WoutL
      wrote on last edited by
      #2

      With ProcMon[^] you can investigate which process has the file in use.

      Wout Louwers

      1 Reply Last reply
      0
      • T tonyonlinux

        For some reason I can't add my dataconnect. I click on add connection select sql server then I browse to the programfiles/...sqlserver/data and click on books.mdf it tells me every single time that the file is in use. But I don't know of any program that would be using it. I'm running the server on my desktop simply to try and learn it and do a little programming with it. i can't seem to understand why it will not access that database. Any help would be great thanks...

        M Offline
        M Offline
        Mycroft Holmes
        wrote on last edited by
        #3

        At a guess the database has a connection that is still live, it may be left over from debugging or a corrupt connection. Also Access may be corrupt and refusing the connection, try repair and rebuild via the Access UI.

        Never underestimate the power of human stupidity RAH

        1 Reply Last reply
        0
        • T tonyonlinux

          For some reason I can't add my dataconnect. I click on add connection select sql server then I browse to the programfiles/...sqlserver/data and click on books.mdf it tells me every single time that the file is in use. But I don't know of any program that would be using it. I'm running the server on my desktop simply to try and learn it and do a little programming with it. i can't seem to understand why it will not access that database. Any help would be great thanks...

          R Offline
          R Offline
          Roger Wright
          wrote on last edited by
          #4

          Is there a new file in the directory holding your database, specifically a lock file? I'm new to SQL Server, but in Access a file is created when a connection is established that locks out other users. Sometimes when connections are not correctly closed, the file defining the lock is not deleted, blocking any subsequent access attempts. Deleting the locking file eliminates the problem. Is there an equivalent locking file in SQL Server? If so, deleting it may restore your access to the database.

          "A Journey of a Thousand Rest Stops Begins with a Single Movement"

          T 1 Reply Last reply
          0
          • R Roger Wright

            Is there a new file in the directory holding your database, specifically a lock file? I'm new to SQL Server, but in Access a file is created when a connection is established that locks out other users. Sometimes when connections are not correctly closed, the file defining the lock is not deleted, blocking any subsequent access attempts. Deleting the locking file eliminates the problem. Is there an equivalent locking file in SQL Server? If so, deleting it may restore your access to the database.

            "A Journey of a Thousand Rest Stops Begins with a Single Movement"

            T Offline
            T Offline
            tonyonlinux
            wrote on last edited by
            #5

            I finally got it resolved. I actually had the server manager running connected to the sql server. So I took and closed that and refreshed the datasource and worked fine. thanks for the help all

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups