Errors when replying to a ticket with a very long subject

I’m getting the following errors in my apache error log whenever a
user replies via email to a ticket with a very long subject:

[Tue Mar 21 23:55:08 2006] [crit]: RT::Attachment->Create couldn’t, as you didn’t specify a transaction
(/usr/local/rt3/lib/RT/Attachment_Overlay.pm:147)
[Tue Mar 21 23:55:08 2006] [err]: RT::Ticket=HASH(0x9ce3304) couldn’t init a transaction Transaction Created (/usr/local/rt3/lib/RT/Ticket_Overlay.pm:2413)
[Tue Mar 21 23:55:08 2006] [crit]: Message could not be recorded (/usr/local/rt3/lib/RT/Interface/Email.pm:816)

It looks like the problem occurs with any subject that is longer than
110 characters. I can open a long subject ticket via email and open,
reply or comment on a long subject ticket through the web interface
without a problem. However, whenever I try to enter a reply to it via
email, I get the above errors. Has anyone seen/worked around this
error before, or should I open a bug on it?

Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services

I’m getting the following errors in my apache error log whenever a
user replies via email to a ticket with a very long subject:

What RT and SearchBuilder are you running? What database?

Jesse Vincent jesse@bestpractical.com writes:

I’m getting the following errors in my apache error log whenever a
user replies via email to a ticket with a very long subject:

What RT and SearchBuilder are you running? What database?

DBIx::SearchBuilder 1.38
RT 3.4.5

Database is postgresql 7.4.5.

[Tue Mar 21 23:55:08 2006] [crit]: RT::Attachment->Create couldn’t, as you didn’t specify a transaction
(/usr/local/rt3/lib/RT/Attachment_Overlay.pm:147)
[Tue Mar 21 23:55:08 2006] [err]: RT::Ticket=HASH(0x9ce3304) couldn’t init a transaction Transaction Created (/usr/local/rt3/lib/RT/Ticket_Overlay.pm:2413)
[Tue Mar 21 23:55:08 2006] [crit]: Message could not be recorded (/usr/local/rt3/lib/RT/Interface/Email.pm:816)

It looks like the problem occurs with any subject that is longer than
110 characters. I can open a long subject ticket via email and open,
reply or comment on a long subject ticket through the web interface
without a problem. However, whenever I try to enter a reply to it via
email, I get the above errors. Has anyone seen/worked around this
error before, or should I open a bug on it?


Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services


The rt-users Archives

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

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

We’re hiring! Come hack Perl for Best Practical: Careers — Best Practical Solutions

Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services

Jesse Vincent jesse@bestpractical.com writes:

I’m getting the following errors in my apache error log whenever a
user replies via email to a ticket with a very long subject:

What RT and SearchBuilder are you running? What database?

DBIx::SearchBuilder 1.38
RT 3.4.5

That should be recent enough to do the right thing. What are you seeing
in your database error logs?

Jesse Vincent jesse@bestpractical.com writes:

Jesse Vincent jesse@bestpractical.com writes:

I’m getting the following errors in my apache error log whenever a
user replies via email to a ticket with a very long subject:

What RT and SearchBuilder are you running? What database?

DBIx::SearchBuilder 1.38
RT 3.4.5

That should be recent enough to do the right thing. What are you seeing
in your database error logs?

Good question! That points right at the problem:
ERROR: value too long for type character varying(100)

My transactions table has data defined as a varchar(100), and in the
current schema for Pg, those fields are varchar(255).

Is anything going to break if I just change the type of the data field
to varchar(255) or text? Is there any reason those fields are varchar
instead of text?

I should have checked the DB error logs earlier.

Database is postgresql 7.4.5.

[Tue Mar 21 23:55:08 2006] [crit]: RT::Attachment->Create couldn’t, as you didn’t specify a transaction
(/usr/local/rt3/lib/RT/Attachment_Overlay.pm:147)
[Tue Mar 21 23:55:08 2006] [err]: RT::Ticket=HASH(0x9ce3304) couldn’t init a transaction Transaction Created (/usr/local/rt3/lib/RT/Ticket_Overlay.pm:2413)
[Tue Mar 21 23:55:08 2006] [crit]: Message could not be recorded (/usr/local/rt3/lib/RT/Interface/Email.pm:816)

It looks like the problem occurs with any subject that is longer than
110 characters. I can open a long subject ticket via email and open,
reply or comment on a long subject ticket through the web interface
without a problem. However, whenever I try to enter a reply to it via
email, I get the above errors. Has anyone seen/worked around this
error before, or should I open a bug on it?


Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services


The rt-users Archives

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

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

We’re hiring! Come hack Perl for Best Practical: Careers — Best Practical Solutions


Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services

Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services

I think this was changed in some early releases of the RT 3.0, but
this was never add to the upgrade scripts or may be there were no such
scripts that time.

Carbon60: Managed Cloud Services looks as related.

Ted, you can alter Tickets table and set length of the Subject field to 200.

We also need this ALTER TABLE queries in etc/upgrade/3.4.6/schema.*
files. Ted, could you make patch for this? :)On 3/23/06, Ted Cabeen ted@impulse.net wrote:

Jesse Vincent jesse@bestpractical.com writes:

On Wed, Mar 22, 2006 at 03:06:55PM -0800, Ted Cabeen wrote:

Jesse Vincent jesse@bestpractical.com writes:

On Tue, Mar 21, 2006 at 04:05:35PM -0800, Ted Cabeen wrote:

I’m getting the following errors in my apache error log whenever a
user replies via email to a ticket with a very long subject:

What RT and SearchBuilder are you running? What database?

DBIx::SearchBuilder 1.38
RT 3.4.5

That should be recent enough to do the right thing. What are you seeing
in your database error logs?

Good question! That points right at the problem:
ERROR: value too long for type character varying(100)

My transactions table has data defined as a varchar(100), and in the
current schema for Pg, those fields are varchar(255).

Is anything going to break if I just change the type of the data field
to varchar(255) or text? Is there any reason those fields are varchar
instead of text?

I should have checked the DB error logs earlier.

Database is postgresql 7.4.5.

[Tue Mar 21 23:55:08 2006] [crit]: RT::Attachment->Create couldn’t, as you didn’t specify a transaction
(/usr/local/rt3/lib/RT/Attachment_Overlay.pm:147)
[Tue Mar 21 23:55:08 2006] [err]: RT::Ticket=HASH(0x9ce3304) couldn’t init a transaction Transaction Created (/usr/local/rt3/lib/RT/Ticket_Overlay.pm:2413)
[Tue Mar 21 23:55:08 2006] [crit]: Message could not be recorded (/usr/local/rt3/lib/RT/Interface/Email.pm:816)

It looks like the problem occurs with any subject that is longer than
110 characters. I can open a long subject ticket via email and open,
reply or comment on a long subject ticket through the web interface
without a problem. However, whenever I try to enter a reply to it via
email, I get the above errors. Has anyone seen/worked around this
error before, or should I open a bug on it?


Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services


The rt-users Archives

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

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

We’re hiring! Come hack Perl for Best Practical: Careers — Best Practical Solutions


Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services


Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services


The rt-users Archives

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

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

We’re hiring! Come hack Perl for Best Practical: Careers — Best Practical Solutions

Best regards, Ruslan.

“Ruslan Zakirov” ruslan.zakirov@gmail.com writes:

I think this was changed in some early releases of the RT 3.0, but
this was never add to the upgrade scripts or may be there were no such
scripts that time.

Carbon60: Managed Cloud Services looks as related.

Ted, you can alter Tickets table and set length of the Subject field to 200.

I went to a VARCHAR(255). We could probably use a TEXT field, but I
figured I’d stick with VARCHAR for now.

We also need this ALTER TABLE queries in etc/upgrade/3.4.6/schema.*
files. Ted, could you make patch for this? :slight_smile:

Sure. Here’s the alter table statements you’ll need:

ALTER TABLE transactions ADD COLUMN temp VARCHAR(255);
UPDATE transactions SET temp = data;
ALTER TABLE transactions RENAME COLUMN data TO deleteme;
ALTER TABLE transactions RENAME COLUMN temp TO data;
ALTER TABLE transactions DROP COLUMN deleteme;

Ted Cabeen
Sr. Systems/Network Administrator
Impulse Internet Services LLC