Title: query SELECT from db about wp_post
Last modified: August 30, 2016

---

# query SELECT from db about wp_post

 *  [Bluekid](https://wordpress.org/support/users/bluekid/)
 * (@bluekid)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/query-select-from-db-about-wp_post/)
 * Hello guys
    please can you support me? Simply i need a query in the header of
   a page. in my sql i’ve this:
 * `INSERT INTO`wp_posts`(`ID`,`post_author`,`post_date`,`post_date_gmt`,`post_content`,`
 * so i need to call post_content.. how i must to do?
    i try this but nothing
 *     ```
       <?php
       function testme () {
       global $wpdb;
       $result = $wpdb->get_var("SELECT post_content FROM wp_posts");
       echo "<h1>".$cats."</h1>";
       }
   
       testme();
       ?>
       ```
   
 * where i wrong?

The topic ‘query SELECT from db about wp_post’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [Bluekid](https://wordpress.org/support/users/bluekid/)
 * Last activity: [10 years, 11 months ago](https://wordpress.org/support/topic/query-select-from-db-about-wp_post/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
