Need help? Check out our Support site, then


Query

  1. I need to build a Query based on my MySQLDB to pull in several data points. The issue I have now is how to add First_Name & get them to list. Thoughts? PLEASE HELP!!!!

    [php]
    global $wpdb;

    $res = $wpdb->get_results("SELECT Last_Name FROM football WHERE Team_Number = '22'");
    foreach ($res as $rs) {
    echo $rs->Last_Name;
    }
    [/php]

    The blog I need help with is iatoday.wordpress.com.

  2. Here at WordPress.com we cannot access the files containing the php for our blogs; only Staff can as this is a multiuser blogging platform. I believe you have posted to the wrong support forum.

    Please read this > http://support.wordpress.com/com-vs-org/ Then if you are asking about a wordpress.ORG install post to the correct forum for your software here > http://wordpress.ORG/support/

  3. Ok, how can I Pull MySQL data into my WordPress blog? I don't have to use PHP

    Thank you for quick reply.

  4. If you want to import blog content from a WordPress.org install into a WordPress.com free hosted blog see here please. > http://en.support.wordpress.com/moving-a-blog/#moving-from-wordpress-org

    If you want to accomplish anything else with respect to the database then that cannot be done.

  5. So I am not able to pulled stored data into my wordpress blog from MySQL?

  6. No.

  7. You are not able to do that.

  8. Thank you:

    Good News I am closer as I tinker: This works

    <table>
    <tr><td>First Name</td><td>Last Name</td><tr>
    [php]
    global $wpdb;
    $res = $wpdb->get_results("SELECT Last_Name FROM football WHERE Team_Number = '10'");
    foreach ($res as $rs) {
    echo "<tr><td>PUT FIRST NAME HERE</td><td>" . $rs->Last_Name . "</td></tr>";
    }
    [/php]
    </table>

  9. Do you recognize that you are posting to the wrong support forum? Please post to http://wordpress.ORG/support like I advised you to above.

  10. Sorry, I will move my question. Didn't mean to upset you

  11. No problem. I'm not upset. I'm simply concerned that free hosted WordPress.com bloggers who are supposed to post here, will read this thread and become confused and post to it, as that's what's happened in the past.

Topic Closed

This topic has been closed to new replies.

About this Topic