[rt-users] I forgot how to do this

James Moseley jmoseley at corp.xanadoo.com
Wed Aug 8 16:16:54 EDT 2007

I am sure you can do this by using a single mysql command, but...

To get the numeric id of the custom field:

mysql> select id from CustomFields where Name='<custom field name>';

Grab the id, then:

mysql> select * from CustomFieldValues where CustomField='<id>';

James Moseley

             Mathew Snyder                                                 
             <theillien at yahoo.                                             
             com>                                                       To 
             Sent by:                  RT Users                            
             rt-users-bounces@         <rt-users at lists.bestpractical.com>  
             lists.bestpractic                                          cc 
                                       [rt-users] I forgot how to do this  
             08/08/2007 02:40                                              

I need to get a list of all of the values for one particular custom field.
had a script which did this after about a week or two of banging my head
my desk.  However, I no longer have this script and am left banging my head
again as I've forgotten how to gather this list up.

I've tried using CustomFieldValue, CustomFieldValues, CustomField and
CustomFields.  I can't for the life of me figure out how to do this.  Can
someone point me in the right direction?

Keep up with me and what I'm up to: http://theillien.blogspot.com

Community help: http://wiki.bestpractical.com
Commercial support: sales at bestpractical.com

Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
Buy a copy at http://rtbook.bestpractical.com

More information about the rt-users mailing list