CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Import (Moderator: Yashodha Chaku) »
  • Import Events
Pages: [1]

Author Topic: Import Events  (Read 3367 times)

lanetterm

  • Guest
Import Events
October 18, 2010, 09:30:58 am
The interface does not seem to provide a way to import events into civicrm. I am comfortable doing this kind of work at the database level. I was looking for documentation or someone with information on what tables besides the event table will need to be touched. Specifically, when an event is created what records in what tables are created?

thanks for any help

lanette

Kiran Jagtap

  • Ask me questions
  • ****
  • Posts: 533
  • Karma: 51
Re: Import Events
October 20, 2010, 01:35:49 am
Hello lanetterm,

We use civicrm_event table to store event data.

Instead of direct firing queries on db,  I'd recommend to take a look for our event api's
which would allow you to create events.

kiran
You Are Designed To Choose... Defined By Choice.

lanetterm

  • Guest
Re: Import Events
October 20, 2010, 07:08:47 am
If this was something I would be doing frequently the api would be the way to go. But this is just a one time import of events. Approximately 1500 of them, more than I want to manually add. I wanted to figure out what exactly is created when an event is created, so that I can recreate that.

thanks again

lanette

DerekL

  • I post frequently
  • ***
  • Posts: 132
  • Karma: 1
  • CiviCRM version: 4.5.5
  • CMS version: Drupal 7.34
  • MySQL version: 5.1.54
  • PHP version: 5.2.17
Re: Import Events
November 23, 2011, 10:43:48 am
I had a similar situation, ended up using D7's Batch API along with Civi's API3. End result was pretty nifty, and painless though it doesn't have the field matching,error handling, or progress bar niceties the built-in import tools show off.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Import Events
November 23, 2011, 02:10:50 pm

hey derek:

would be great if you could publish this code on github under a nice open source license :) I suspect a few people will be able to build on it and use it for their needs and potentially improve it

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

DerekL

  • I post frequently
  • ***
  • Posts: 132
  • Karma: 1
  • CiviCRM version: 4.5.5
  • CMS version: Drupal 7.34
  • MySQL version: 5.1.54
  • PHP version: 5.2.17
Re: Import Events
December 01, 2011, 08:24:51 am
I'm in the process of porting the lessons I learned over to participations and event contributions imports as well, when that's done I'll release so that it can be crowd-improved, my code is entry level but well documented.

jdaniluk

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
  • CiviCRM version: 4.2.0
  • CMS version: Drupal 7.14
  • MySQL version: 5.1
  • PHP version: 5.3
Re: Import Events
January 12, 2012, 10:33:30 am
Here's one person that would like a way to do a one-time import of events.  I'd like to import about 250 past events.  I don't need to import the participants, and I can ignore the fees, but I do need to be able to import some custom event fields.

sonicthoughts

  • Ask me questions
  • ****
  • Posts: 498
  • Karma: 10
Re: Import Events
December 27, 2012, 06:47:43 pm
Was wondering if there was ever an import event script written?  tempted to go right into the db :).

mwurpts

  • I’m new here
  • *
  • Posts: 2
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 7
  • MySQL version: 5.0
  • PHP version: 5.3.13
Re: Import Events
July 01, 2014, 07:34:46 am
Can anyone provide some guidance for us to do this? We have 140 past events that we need to import along with participants. We are not concerned with fees. We just want a consistent record of participation with contact information.

Can I just add a record to the civicrm_event table to add an event? All fields look pretty straight forward, except I'm not sure what to do with: loc_block_id. Or, are there more tables that are affected?

Thank you.
« Last Edit: July 01, 2014, 07:59:03 am by mwurpts »

Laryn

  • I post frequently
  • ***
  • Posts: 192
  • Karma: 4
    • CEDC
  • CiviCRM version: 4.6.x
  • CMS version: Drupal 7
Re: Import Events
November 26, 2014, 11:27:12 am
This extension may help anyone who comes to this thread looking for help on importing events:
API csv Import GUI
Quote
This extension facilitates uploading CSVs via the CiviCRM import interface. Useful for bulk uploading events or campaigns etc...
CEDC...social justice by design

*Get support on the new CiviCRM help site. /laryn

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Import (Moderator: Yashodha Chaku) »
  • Import Events

This forum was archived on 2017-11-26.