SitePoint Sponsor

User Tag List

Results 1 to 8 of 8

Hybrid View

  1. #1
    SitePoint Enthusiast
    Join Date
    Oct 2009
    Location
    Tokyo
    Posts
    36
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Where are the mysql files on my Mac?

    I'm working through the sitepoint book "Build Your Own Database Driven Web Site using PHP and MySQL."

    I installed MySQL directly and all the examples I've gone through so far are working fine.

    We have been using a database called "ijdb" (a joke database). I was wondering where the actual "ijdb" database itself resides. If I wanted to put it up on an external server somewhere I would need to know that, but can't seem to find it.

    Is it perhaps buried somewhere in /usr/local/mysql/data? It looks like there is a folder called ijdb in there, but beyond that I'm not sure what is the actual database file - or even what MySQL database file naming conventions are.

    Thanks,

    doug

  2. #2
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,016
    Mentioned
    53 Post(s)
    Tagged
    2 Thread(s)
    you should not need to know

    if you want to post your database on some other server, you will need to dump it

    see the information on the mysqldump utility in da manual

    the only database file that you can manipulate or move around with impunity is a microsoft access mdb file
    r937.com | rudy.ca | Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  3. #3
    SitePoint Enthusiast
    Join Date
    Oct 2009
    Location
    Tokyo
    Posts
    36
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I will check out mysqldump. But now you've made me curious. If somebody tells me I shouldn't need to know something I want to know it.

    doug

  4. #4
    dooby dooby doo silver trophybronze trophy
    spikeZ's Avatar
    Join Date
    Aug 2004
    Location
    Manchester UK
    Posts
    13,788
    Mentioned
    151 Post(s)
    Tagged
    3 Thread(s)
    Macintosh HD > Applications > MAMP > db > mysql

    Mike Swiffin - Community Team Advisor
    Only a woman can read between the lines of a one word answer.....

  5. #5
    SitePoint Enthusiast
    Join Date
    Oct 2009
    Location
    Tokyo
    Posts
    36
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That's if you're running MAMP. The instructions in the book for installing MAMP actually didn't work well (I posted about that elsewhere) and so I followed the better instructions in the book for downloading and installing MySQL directly. That works fine. But naturally the files are located in some other place.

    doug

  6. #6
    dooby dooby doo silver trophybronze trophy
    spikeZ's Avatar
    Join Date
    Aug 2004
    Location
    Manchester UK
    Posts
    13,788
    Mentioned
    151 Post(s)
    Tagged
    3 Thread(s)
    I based that on the basic default installation on my iMac. Search your Mac for the folder called mysql and it will give you the correct location.
    Mike Swiffin - Community Team Advisor
    Only a woman can read between the lines of a one word answer.....

  7. #7
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,016
    Mentioned
    53 Post(s)
    Tagged
    2 Thread(s)
    once you find the files, would you kindly give us an update here on what you end up doing with them?
    r937.com | rudy.ca | Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  8. #8
    SitePoint Enthusiast
    Join Date
    Oct 2009
    Location
    Tokyo
    Posts
    36
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Like I said, I am just curious - what the filenames are, whether they are openable in BBEdit and, if so, what is visible inside. I might not do anything at all with them. But knowing about them seems better than not knowing about them.

    About "finding the mysql" folder, as mentioned in my original post, I already found /usr/local/mysql and there is a data folder in there which contains what appears to be another folder called ijdb. So it's probably in there somewhere. But the data folder is locked and hard to look around and see what the contents are. The database itself is one file, right? Does it have a naming convention like "ijdb.db" or something like that?

    Thanks,

    doug


Bookmarks

Posting Permissions

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