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
  1. Home
  2. Database & SysAdmin
  3. Database
  4. Database Directory

Database Directory

Scheduled Pinned Locked Moved Database
databasesql-serversysadminquestion
8 Posts 6 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.
  • G Offline
    G Offline
    gmhanna
    wrote on last edited by
    #1

    Hi, I'm running SQL Server and I have an application that is creating a new database. However I'm not sure what directory I should store the database. Any suggestions? Thank you,

    Glenn

    M W P 3 Replies Last reply
    0
    • G gmhanna

      Hi, I'm running SQL Server and I have an application that is creating a new database. However I'm not sure what directory I should store the database. Any suggestions? Thank you,

      Glenn

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

      If the database is not server based then I would put it in either the users appdata folder or the applications install folder, although this may no longer be valid b/c of the UAC requirements. I think the appdata folder is where it should be.

      Never underestimate the power of human stupidity RAH

      R 1 Reply Last reply
      0
      • M Mycroft Holmes

        If the database is not server based then I would put it in either the users appdata folder or the applications install folder, although this may no longer be valid b/c of the UAC requirements. I think the appdata folder is where it should be.

        Never underestimate the power of human stupidity RAH

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

        I like the idea of using the application's install directory, somewhere far from the Windows default structures. That way, when Windows Update crashes the system and Windows has to be reinstalled, it isn't erased and replaced by empty folders. :-D

        Will Rogers never met me.

        M 1 Reply Last reply
        0
        • G gmhanna

          Hi, I'm running SQL Server and I have an application that is creating a new database. However I'm not sure what directory I should store the database. Any suggestions? Thank you,

          Glenn

          W Offline
          W Offline
          Wendelius
          wrote on last edited by
          #4

          As Mycroft said, it's more of a matter of opinion if this isn't a server installation. Personally I like to have the database files in an easy path so I use C:\Databases\... and a tree structure for different versions, databases etc. If you're going to create multiple databases you can change the default location for the new databases in the Management Studio / Server Properties / Database Settings and type a path you want. However, note that the Management Studio won't create a new folder for you so you have to create it separately and assign proper privileges.

          The need to optimize rises from a bad design.My articles[^]

          1 Reply Last reply
          0
          • R Roger Wright

            I like the idea of using the application's install directory, somewhere far from the Windows default structures. That way, when Windows Update crashes the system and Windows has to be reinstalled, it isn't erased and replaced by empty folders. :-D

            Will Rogers never met me.

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

            I used to be one of those people who would not accept the default installation locations for anyhting, I figured I can design a better file structure than any jumped up softie so I would always change the default. Partly b/c my file system was then completely non standard and no miserable robot/sniffer/@#$@# prick could find anything on MY system. This lasted till about the mid 90s when there were so many systems coming out of MS and other vendors that simply did not work if they could not find the information in the default folders. Yep I wimped out, I now treat the default folder like the EULA, accept it and move on.

            Never underestimate the power of human stupidity RAH

            R J 2 Replies Last reply
            0
            • M Mycroft Holmes

              I used to be one of those people who would not accept the default installation locations for anyhting, I figured I can design a better file structure than any jumped up softie so I would always change the default. Partly b/c my file system was then completely non standard and no miserable robot/sniffer/@#$@# prick could find anything on MY system. This lasted till about the mid 90s when there were so many systems coming out of MS and other vendors that simply did not work if they could not find the information in the default folders. Yep I wimped out, I now treat the default folder like the EULA, accept it and move on.

              Never underestimate the power of human stupidity RAH

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

              I know what you mean... I try to studiously change the defaults whenever I install new software, but then comes along a product written by idjits that won't let me change them. Microsoft is the single worst offender in that respect, but there are a host of others. Eventually I get lazy, and as the advice to rape victims goes, I lie back and accept the inevitable. But with each new system I try again, having just had to rebuild thousands of files because reinstalling Windows erased them. :sigh:

              Will Rogers never met me.

              1 Reply Last reply
              0
              • M Mycroft Holmes

                I used to be one of those people who would not accept the default installation locations for anyhting, I figured I can design a better file structure than any jumped up softie so I would always change the default. Partly b/c my file system was then completely non standard and no miserable robot/sniffer/@#$@# prick could find anything on MY system. This lasted till about the mid 90s when there were so many systems coming out of MS and other vendors that simply did not work if they could not find the information in the default folders. Yep I wimped out, I now treat the default folder like the EULA, accept it and move on.

                Never underestimate the power of human stupidity RAH

                J Offline
                J Offline
                Jorgen Andersson
                wrote on last edited by
                #7

                :-O I also joined that club in the 90s.

                List of common misconceptions

                1 Reply Last reply
                0
                • G gmhanna

                  Hi, I'm running SQL Server and I have an application that is creating a new database. However I'm not sure what directory I should store the database. Any suggestions? Thank you,

                  Glenn

                  P Offline
                  P Offline
                  PIEBALDconsult
                  wrote on last edited by
                  #8

                  Anywhere but under Program files. All Users App Data should work.

                  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