Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2003
    Location
    Irvine, CA
    Posts
    38

    Question Unanswered: Does MySQL have a sysdatabases equiv?

    I am trying to write a PHP Utility to backup MySQL databases.

    I have a working app, however the downside is that I need to either manually create a list of dbs to backup or I need to keep a seperate database of all databases.

    MSSQL hase a sysdatabases table in the master database.

    It would be nice to do something like:

    select name from sysdatabases
    order by name

    and get a complete list of all my databases to then process from.

    Thanks in advance
    Jeff Jones
    Software Architect
    http://www.linkedin.om/in/jeffjones1972
    jeff@lordjester.com
    425-345-8293

  2. #2
    Join Date
    Sep 2003
    Location
    London
    Posts
    56

    Re: Does MySQL have a sysdatabases equiv?

    Originally posted by jdierking
    .. get a complete list of all my databases to then process from..
    Code:
    show databases ;
    Matt.

  3. #3
    Join Date
    Jan 2003
    Location
    Irvine, CA
    Posts
    38
    Does that work from PHP or from the command line?
    Jeff Jones
    Software Architect
    http://www.linkedin.om/in/jeffjones1972
    jeff@lordjester.com
    425-345-8293

  4. #4
    Join Date
    Jan 2003
    Location
    Irvine, CA
    Posts
    38

    Found the answer...

    Not sure how it is achieved on the db side, but PHP has a function "mysql_list_dbs" that returns all dbs on the server.
    Jeff Jones
    Software Architect
    http://www.linkedin.om/in/jeffjones1972
    jeff@lordjester.com
    425-345-8293

Posting Permissions

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