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 CiviReport (Moderator: Dave Greenberg) »
  • Customising column names in data export - how do I get BIRT to do this?
Pages: [1]

Author Topic: Customising column names in data export - how do I get BIRT to do this?  (Read 5862 times)

Chris Burgess

  • Ask me questions
  • ****
  • Posts: 675
  • Karma: 59
Customising column names in data export - how do I get BIRT to do this?
March 03, 2008, 10:40:00 pm
We've got CiviReport up and running, but our BIRT install does a few things oddly.

If I query for two columns of the same name (eg civicrm_membership_status.name and civicrm_membership_type.name), BIRT will always export the first as "name" and the second as "name_3". The number "3" is derived from the number of columns - if x.name is preceded by another column of the same name, and it is the third column, it will appear as name_3.

I've attempted to prevent BIRT doing this by both using SQL's "AS" alias, and by using the "Alias" and "Display Name" settings in BIRT's "Edit Data Set => Output Columns". Neither of these approaches works. BIRT does the same thing both installed via Tomcat as a web viewer, and in Eclipse on my desktop.

This is frustrating, because it's so easy to alias the column names in SQL, but the results just don't come out of BIRT! I've verified that the column names are correctly displayed if I copy the query from BIRT's query editor and paste it into MySQL CLI.

Looking forward to sharing tips and advice with other users who are newly familiar with BIRT!
@xurizaemon ● www.fuzion.co.nz

Michał Mach

  • Ask me questions
  • ****
  • Posts: 748
  • Karma: 59
    • CiviCRM site
  • CiviCRM version: latest
  • CMS version: Drupal and Joomla latest
  • MySQL version: numerous
  • PHP version: 5.3 and 5.2
Re: Customising column names in data export - how do I get BIRT to do this?
March 04, 2008, 06:45:50 am
Sorry for not being very useful here, but did you try posting that question thrugh one of BIRT specific channels (http://www.eclipse.org/birt/phoenix/community.php)? Might be worth to do it to get useful response quicker...

Thx,
m
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

My absolute favourite: Wordpress Integration!.

Donate Now!

Chris Burgess

  • Ask me questions
  • ****
  • Posts: 675
  • Karma: 59
Re: Customising column names in data export - how do I get BIRT to do this?
March 04, 2008, 01:43:30 pm
I did, yes. The response was,

Quote
I haven't found your issue in 2.2.1.r221_v20070924 build. The column name is as the alias which defined in SQL but not a name with automatically suffix. If the column name are same with out define alias in SQL, it will add a number suffix and the number is will be the index of the columns' sequence. So would you like to try another build to reproduce it?

Thanks

Tianli

I'm using the same version and see this issue on both our OSX desktop, and Linux server.

Am I missing something w.r.t SQL's "AS"? Is that what Tianli would mean by "with out define alias in SQL", or is there some other syntax for alias definitions that I'm not aware of?
@xurizaemon ● www.fuzion.co.nz

Michał Mach

  • Ask me questions
  • ****
  • Posts: 748
  • Karma: 59
    • CiviCRM site
  • CiviCRM version: latest
  • CMS version: Drupal and Joomla latest
  • MySQL version: numerous
  • PHP version: 5.3 and 5.2
Re: Customising column names in data export - how do I get BIRT to do this?
March 05, 2008, 03:43:46 am
Quote from: xurizaemon on March 04, 2008, 01:43:30 pm
Am I missing something w.r.t SQL's "AS"? Is that what Tianli would mean by "with out define alias in SQL", or is there some other syntax for alias definitions that I'm not aware of?

Ehm, I personally don't know any other way for aliasing columns, but I'm not SQL guru...

m
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

My absolute favourite: Wordpress Integration!.

Donate Now!

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviReport (Moderator: Dave Greenberg) »
  • Customising column names in data export - how do I get BIRT to do this?

This forum was archived on 2017-11-26.