pg_query error on ticket create -- PostgreSQL
guodskrap - July 1, 2009 - 14:48
| Project: | Trouble ticketing system to support Computer Network Operations |
| Version: | 6.x-3.0-rc2 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
I receive the following error when attempting to create a ticket.
warning: pg_query() [function.pg-query]: Query failed: ERROR: null value in column "description" violates not-null constraint in /srv/sites/siv3/includes/database.pgsql.inc on line 139.
user warning: query: INSERT INTO ticket_event (tid, reassigned, created, status_id) VALUES (4, 3, 1246450904, 1) in /srv/sites/siv3/sites/all/modules/ticketing/ticket.pages.inc on line 832.
Versions:
Drupal 6.12
Ticketing 6.x-3.0-rc2

#1
#2
I am not using PGSQL, but I have an idea. Please try to change the original sql commant at the problematic line:
Old:
$SQL = "INSERT INTO {ticket_event} (tid, reassigned, created, status_id) VALUES (%d, %d, %d, %d)";New:
$SQL = "INSERT INTO {ticket_event} (tid, reassigned, created, status_id, description) VALUES (%d, %d, %d, %d, '')";If it is working then please report it back.