Turning a Wordpress post_meta table into an easier to use View
===

I'm using Wordpress and trying to create a view to make reviewing and analyzing my resort data a little easier. Resort data is stored in the post_meta table in Wordpress and referenced in a custom post type known as "resorts". The following query gives me the result set I want to parse:

    SELECT a.id, a.post_type, a.post_title, b.post_id, b.meta_key, b.meta_value
    FROM alpinezone_postmeta b
    INNER JOIN alpinezone_posts a ON a.id = b.post_id
    WHERE a.post_type = "resorts" 

What I want to do with this result set is have each unique meta_key of a set I define become a column and then each row should be a unique b.post_id (or a.id), which corresponds to an individual resort's record. 

So ultimately I end up with: 

    post_title |   phone_num      | state         |
    resort1    |   800-200-1111   | Vermont       |
    resort2    |   800-200-2222   | New Hampshire |
    resort 3   |   800-200-2323   | Maine         |

Basically ...... I'm not that great at MySQL so trying to figure out the best way to handle this. I do have a list of all the meta_key I want to place into columns, there are 36 of them capturing a range of information. 

