Edgewall Software

Opened 3 years ago

Last modified 12 months ago

#12893 new defect

Empty time values should be stored as NULL

Reported by: Ryan J Ollos Owned by:
Priority: normal Milestone: next-dev-1.5.x
Component: general Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description (last modified by Ryan J Ollos)

Empty time values in the ticket system are stored as 0. They should probably be stored as NULL instead. Example: Version.update

sqlite> SELECT time FROM version;

The issue is caused by behavior of to_utimestamp. We should add a helper function:

def _to_timestamp(time):
    return to_utimestamp(time) if time else None

Timestamps are stored in the following fields:

  • attachment.time
  • wiki.time
  • revision.time
  • ticket.time
  • ticket.changetime
  • ticket_change.time
  • milestone.due
  • milestone.completed
  • version.time
  • notification_subscription.time
  • notification_subscription.changetime

Attachments (0)

Change History (4)

comment:1 by Ryan J Ollos, 2 years ago

Description: modified (diff)

comment:2 by Ryan J Ollos, 12 months ago

See also comment:20:ticket:11018. Empty time ticket custom field values are stored as NULL rather than an empty string.

comment:3 by Ryan J Ollos, 12 months ago

Milestone: next-dev-1.3.xnext-dev-1.5.x

Milestone renamed

comment:4 by Ryan J Ollos, 12 months ago

Description: modified (diff)

Modify Ticket

Change Properties
Set your email in Preferences
as new The ticket will remain with no owner.
The ticket will be disowned.
as The resolution will be set. Next status will be 'closed'.
The owner will be changed from (none) to anonymous. Next status will be 'assigned'.

Add Comment

E-mail address and name can be saved in the Preferences .
Note: See TracTickets for help on using tickets.