Title: display a sql query
Last modified: August 21, 2016

---

# display a sql query

 *  [Adevy](https://wordpress.org/support/users/adevy/)
 * (@adevy)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/display-a-sql-query/)
 * Hi,
 * I would like to know if somebody know what plugin I can use to display a sql 
   query of a database in wordpress.
 * Indeed, my target is that visitors give their opinion about things like fruits,
   book… (I think use a plugin form, like contact form 7 or an other, tell me if
   you have an opinion). I want these data in a database.
    And I want that visitors
   see a table that they can filter in order to see the best fruit sorted by price,
   taste…
 * Thank you for your response,
 * Adevy

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Moderator [cubecolour](https://wordpress.org/support/users/numeeja/)
 * (@numeeja)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/display-a-sql-query/#post-4430045)
 * I don’t think it would be a good idea to allow people to enter sql queries directly
   on your data. If you are using taxonomies for price, taste etc, you should be
   able to return items with a combinations of values for these using a plugin to
   provide faceted search such as facetious: [http://wordpress.org/plugins/facetious/](http://wordpress.org/plugins/facetious/)
   or one of a number of alternatives: [http://wordpress.org/plugins/search.php?q=faceted](http://wordpress.org/plugins/search.php?q=faceted)
 *  Thread Starter [Adevy](https://wordpress.org/support/users/adevy/)
 * (@adevy)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/display-a-sql-query/#post-4430059)
 * Thank you very much for your answer.
 * I understand what you say but I don’t understand how i Can, fisrtly, display 
   a table in order to show results of the database ?
 * Even if visitors can’t touch the sql database, how can them see it ?
 *  Moderator [cubecolour](https://wordpress.org/support/users/numeeja/)
 * (@numeeja)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/display-a-sql-query/#post-4430087)
 * Adding a table for this is not the recommended way to do it in WordPress.
 * Using a custom post type would probably be appropriate then each fruit would 
   be added like a post, but in the ‘fruit’ custom post type.
 * [http://codex.wordpress.org/Post_Types#Custom_Post_Types](http://codex.wordpress.org/Post_Types#Custom_Post_Types)
 *  Thread Starter [Adevy](https://wordpress.org/support/users/adevy/)
 * (@adevy)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/display-a-sql-query/#post-4430133)
 * I have already created the custom post type (called book) and custom fields (
   Mark for price, quality,…), thanks to you. But I don’t know visitor’s answers
   can change automatically the custom fields of the good book.
 * For example, I want to mark the book number 14, with a 6/10 for price and a 9/
   10 for quality. Is there a plug in to change the average? (If I have to write
   the formula, it’s better).
    I have downloaded ninja forms to collect answers.
 * In a second step, I didn’t find any plug in wich can display automatically all
   of the custom post type. (Of course, I don’t want to add every book one by one.
   
   After I will use taxonomy to filter.
 * Thank you again!!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘display a sql query’ is closed to new replies.

## Tags

 * [database](https://wordpress.org/support/topic-tag/database/)
 * [display](https://wordpress.org/support/topic-tag/display/)
 * [sorted](https://wordpress.org/support/topic-tag/sorted/)
 * [sql](https://wordpress.org/support/topic-tag/sql/)

 * 4 replies
 * 2 participants
 * Last reply from: [Adevy](https://wordpress.org/support/users/adevy/)
 * Last activity: [12 years, 3 months ago](https://wordpress.org/support/topic/display-a-sql-query/#post-4430133)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
