Adding columns, changing variable names for rt2 table

  1. I would like to add several columns to the “rt2.Ticket” table. I
    assume that the mysql statements used (inserts, selects, etc) are
    written based on variable name rather than order the columns are in
    (because if they’re not adding columns would be problematic). Am I
    correct in assuming that column order doesn’t matter?

  2. I would like to change the name of the variable “id” to “job_num” and
    fix all references to “id” to use “job_num” instead as well as
    references to “Ticket” table to use “jobreq” table instead. Is there
    one central configuration file I use can change to do that? If not
    which files would I need to modify?

  3. Also what is the difference between “id” and “EffectiveID”?

Why am I doing this you ask?
I am adding RT to our existing custom “job request” (mysql PHP) system.
I would like the numbering to be consistent and allow RT to update
"Tickets" on our original system and allow our original system to update
RT. The only way I can think to do that is to add the RT tables to our
"job request" database and make it use one shared column for numbering
(e.g. if we get “job request” to original system it gets assigned Ticket
#1013, another request to RT gets #1014, etc…).

Help regarding locations of these files or better yet a better way to do
that are appreciated (e.g. can I do the equivalent of
symlinking/aliasing tables and column names from mysql itself rather
than changing DB structure and perl scripts that reference it?)

snippet of rt2.Tickets table pasted below:
mysql> desc Tickets;
| Field | Type | Null | Key | Default | Extra
| id | int(11) | | PRI | NULL | auto_increment
| EffectiveId| int(11) | YES | MUL | NULL |

  1. I would like to change the name of the variable “id” to "job_num"
    and fix all references to “id” to use “job_num” instead as well as
    references to “Ticket” table to use “jobreq” table instead. Is there
    one central configuration file I use can change to do that? If not
    which files would I need to modify?

DBIx::SearchBuilder requires that the primary key in a table be named
’id’, so you’re out of luck here (unless you are willing to hack on
DBIx::searchBuilder).

  1. Also what is the difference between “id” and “EffectiveID”?

I believe that EffectiveId is for when you merge tickets together – the
"effective" id of the ticket you are merging becomes that of the ticket
merged into.

(darren)

All extreme positions are wrong.
– Erann Gat