Mysql query to output all event venue zip codes?

Home Forums Calendar Products Events Calendar PRO Mysql query to output all event venue zip codes?

  • This topic has 1 reply, 2 voices, and was last updated 8 years ago by Martin.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #1505950
    Martin
    Participant

    Can anyone point me in the right direction to do a mysql query to list all the venue zip codes? I was surprised to see there is no export to csv functionality (maybe add this in the future?)

    Long story short, I need a csv listing the zipcodes of all the events on my site that were created with the events calendar tool. Hoping someone here can save me hours of digging in the code to try to figure it out. Thanks!

    #1506955
    Patricia
    Member

    Hey Martin,

    Thank you for reaching out to us!

    You can use this query to select all distinct Venue Zipcodes in your database:

    SELECT DISTINCT meta_value FROM wp_posts AS t1 JOIN wp_postmeta AS t2 ON t1.ID=t2.post_id WHERE t2.meta_key='_VenueZip' AND t2.meta_value <> ''

    I hope this helps! If you have any other questions at all please feel free to let me know and I’d be happy to help as best I can!

    Cheers,

    Patricia

    #1523633
    Support Droid
    Keymaster

    Hey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.

    Thanks so much!
    The Events Calendar Support Team

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Mysql query to output all event venue zip codes?’ is closed to new replies.