Install & database config

(5 posts) (2 voices)
  • Started by aestheticdesign
  • Latest reply from aestheticdesign

Tags:

No tags yet.

  1. aestheticdesign, Member

    I went through the auto install and it never asked for the database info that I want to report from. I set up a separate database for myDBR and that is working.

    The help files mention that the database info for reporting is held in the config.php file, but I can't seem to locate that file anywhere either in the installed files or in the original zip I downloaded.

    "Once the login process has been completed, all the operations in the database are done using the username/password stored in the admin preferences (section Database connection info: Username/Password). These are stored in the config.php (entries admin_username and admin_password). These are referred here as 'myDBR credentials'. myDBR credentials must have full access to the mydbr-database and read access to the user database objects."

    How do I enter the credentials for the database I want to report from?

  2. myDBR Team, Key Master

    Hi,
    myDBR uses the login specified in the config.php to access the database. If your myDBR user is 'mydbr', you grant the user read access to the database you want to report from. Assuming you are using MySQL and your myDBR is running in same server as your database, you grant select acesss by issuing a command:

    mysql> grant select on mydatabase.* to 'mydbr'@'localhost';

    After this you can report from 'mydatabase':

    select column
    from mydatabase.mytable;

    You can report from any database in your server.

    --
    myDBR Team

  3. aestheticdesign, Member

    The database I want to report from is bandgaps_zncr1 with a user of bandgaps_zncr1.

    When installing myDBR, I created a new database, bandgaps_mydbr, with a user of bandgaps_mydbr.

    They are both on the same server.

    I tried the SQL command

    grant select on bandgaps_zncr1.* to 'bandgaps_mydbr'@'localhost';

    I got the error #1044 - Access denied for user 'bandgaps'@'localhost' to database 'bandgaps_zncr1'

    I've tried it both with using the account prefix bandgaps and without it. Same error either way. I'm not sure why the error message comes back as bandgaps in the error message rather than bandgaps_mydbr.

    Also assuming I am able to get the right syntax and the SQL command gets processed ok, do I need to do this one time or each session?

  4. myDBR Team, Key Master

    What you are doing is that you grant bandgaps_mydbr user select perimissions to the bandgaps_zncr1 database. The bandgaps_zncr1 username you may have does not have anything to do with this.

    You only need to grant select rights only once. What is the username you are logged in when executing the grant command? Where do you run the grant command from (MySQL command line, something else)?

    You should log in as a user with grant privileges. Easiest is to use the root user.

    --
    myDBR Team

  5. aestheticdesign, Member

    I was trying to do it from the myPHPadmin command line. I got it set up using CPANEL.


Reply

You must log in to post.