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 CiviEvent (Moderator: Yashodha Chaku) »
  • civicrm_email table is not working
Pages: [1]

Author Topic: civicrm_email table is not working  (Read 650 times)

prachi.tamrakar

  • Guest
civicrm_email table is not working
June 17, 2009, 02:23:31 am
Hi
When i am joining drupal users table with civicrm_email table it is not working  :(

Sunil

  • I post frequently
  • ***
  • Posts: 131
  • Karma: 23
  • The community around a product more important than the product itself?
    • CiviCRM
Re: civicrm_email table is not working
June 17, 2009, 05:32:56 am
You need to use the database prefix:
e.g.
$query = "SELECT a.field1, b.field1 FROM database1.table1 as a, database2.table1 as b WHERE database1.table1.field2='' AND ..... ";

HTh
The community around a product more important than the product itself?

Kiran Jagtap

  • Ask me questions
  • ****
  • Posts: 533
  • Karma: 51
Re: civicrm_email table is not working
June 17, 2009, 06:33:17 am
hi prachi,

As sunil replied query would also trigger a case of having different db tables for civicrm and drupal.
but more interesting thing is why you require to join these table in single query ? what is your use case ?

Better would be take a time and have a look of civicrm schema and check how civicrm communicate w/ drupal ( basically w/ cms )

kiran
« Last Edit: June 17, 2009, 06:34:54 am by kiran »
You Are Designed To Choose... Defined By Choice.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • civicrm_email table is not working

This forum was archived on 2017-11-26.