• Resolved Dozen

    (@dozen12)


    Peter Hi !

    Thank you for being able to connect to remote databases in the third version !

    But I don’t even have a list of local databases yet.

    What needs to be corrected?

    Now I’m contacting them from php
    $wpdb2 = new wpdb( ‘name_DB’, ‘password’, ‘name_user’, ‘localhost’ );

    With respect, Dmitry

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Passionate Programmer Peter

    (@peterschulznl)

    Hi Dmitry,

    Local databases are only listed in the Data Explorer when your WordPress database user has access to them. If you need to connect as another database user, you can connect using a remote connection.

    With your example you can add a remote database connection like this:
    – Click on the Data Explorer
    – Click on the plus icon to create a remote database connection
    – Enter the following data:
    Database name: rdb:my_remote_db
    MySQL host: localhost
    MySQL username: name_user
    MySQL password: password
    MySQL port: 3306
    MySQL schema: name_DB
    – Test your connection
    – Save if it works

    You can add another database name if you want. Looks like you swicth the username and database, so make sure you have the right values.

    Let me know if this works Dmitry!

    Best regards,
    Peter

    Thread Starter Dozen

    (@dozen12)

    It’s local DB on localhost.

    I connect to all from one php-blocks:

    $wpdb = new wpdb( ‘name_DB_1’, ‘password_1’, ‘name_user’, ‘localhost’ );
    $wpdb2 = new wpdb( ‘name_DB_2’, ‘password_2’, ‘name_user’, ‘localhost’ );

    After “Test connection”:
    Preparing connection…
    Establishing connection…
    Connection established…
    Counting tables…
    Found 0 tables on remote host…

    Remote database connection valid

    Plugin Author Passionate Programmer Peter

    (@peterschulznl)

    Hi Dmitry,

    Looks like it works! You just need to save it.

    Unfortunately there is a bug. You need to add a database name (just rdb: is not enough). So add something like rdb:test and click on save. Your remote database should become available in your WordPress dashboard.

    Best regards,
    Peter

    Plugin Author Passionate Programmer Peter

    (@peterschulznl)

    Hi Dmitry,

    Other users were having the same problem. I uploaded a patch which solved the problem for them. I hope it solves your problem as well.

    You need to delete the plugin and then reinstall it. If you have stored any projects, publications, settings, etc, make sure you’re not losing your work! Before you delete the plugin:
    – Go to the Settings menu
    – Click submenu WP Data Access
    – Click tab Uninstall
    – Uncheck both checkboxes

    Please let me know if this solves the issue. Thanks!

    Best regards,
    Peter

    Plugin Author Passionate Programmer Peter

    (@peterschulznl)

    Hi Dmitry,

    This issue is fixed in version 3.0.1 which is now available from the WordPress plugin directry. Thank you for your patience.

    Best regards,
    Peter

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Listbox local DB is empty’ is closed to new replies.