From 79d280aa1b772eb53fc5772341a79c8a34456767 Mon Sep 17 00:00:00 2001 From: Jiří Netolický Date: Mon, 23 Sep 2013 17:44:20 +0200 Subject: Bug 919475: [Oracle] Crash when non-mandatory free text custom fields are left empty on bug creation r=LpSolit a=justdave --- Bugzilla/DB/Schema/Oracle.pm | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Bugzilla/DB/Schema') diff --git a/Bugzilla/DB/Schema/Oracle.pm b/Bugzilla/DB/Schema/Oracle.pm index 9fafc4515..a61b1e323 100644 --- a/Bugzilla/DB/Schema/Oracle.pm +++ b/Bugzilla/DB/Schema/Oracle.pm @@ -219,6 +219,10 @@ sub get_add_column_ddl { } else { @sql = $self->SUPER::get_add_column_ddl(@_); + # Create triggers to deal with empty string. + if ($definition->{TYPE} =~ /varchar|TEXT/i && $definition->{NOTNULL}) { + push(@sql, _get_notnull_trigger_ddl($table, $column)); + } } return @sql; -- cgit v1.2.3-24-g4f1b