Project

General

Profile

Actions

Bug #663

closed

r14379 change makes new database default tables having wrong DEF_timestamp definition

Added by Anchi Cheng over 14 years ago. Updated over 14 years ago.

Status:
Closed
Priority:
High
Assignee:
Eric Hou
Category:
-
Start date:
06/16/2010
Due date:
% Done:

100%

Estimated time:
Affected Version:
Appion/Leginon 2.0.1
Show in known bugs:
No
Workaround:

Description

DEF_timestamp becomes allow null, current_timestamp is not the default, and the attribute "on update current_timestamp" is also gone. This caused leginondata.LaunchedApplicationData query to fail because it needs to query timestamp but timestamp is not automatically inserted without the right definition.

proposed change:

@ -59,7 +59,7 @
$fname = $v['attributes']['name'];
$ftype = $v['attributes']['type'];
$fnull = empty($v['attributes']['null']) ? 'null' : $v['attributes']['null'];
- $fextra = empty($v['attributes']['extra']) ? 'null' : $v['attributes']['extra'];
+ $fextra = empty($v['attributes']['extra']) ? '' : $v['attributes']['extra'];
$fields[] = "`$fname` $ftype $fnull $fextra";
$fieldtypes[$fname] = $ftype;
}

Actions #1

Updated by Anchi Cheng over 14 years ago

  • Status changed from Assigned to In Code Review
  • Assignee set to Eric Hou
  • % Done changed from 0 to 100

added null definition for leginondata.LaunchedApplicationData in r14380 in branch. had to do the same on a few projectdata tables, too. r14381 in branch so that default is not null.

Changed to my proposed fix for now so that people won't download the wrong code r14382 in branch. What I have works.
However, Eric, please decide if you want it differently.

Actions #2

Updated by Anchi Cheng over 14 years ago

error in myamiweb/inc/xmlapplicationimport.inc is in r14346

Actions #3

Updated by Amber Herold over 14 years ago

  • Status changed from In Code Review to Closed
Actions #4

Updated by Anchi Cheng over 14 years ago

  • Status changed from Closed to Assigned
  • Assignee changed from Eric Hou to Amber Herold
  • Priority changed from Immediate to High
  • Show in known bugs set to No

Found Bug #663 fix was never committed to trunk. Commit the branch fix r14382 to trunk as r14519. Maybe an overall check of the merging should be done now that the 2.0 branch is stable?

Actions #5

Updated by Amber Herold over 14 years ago

  • Status changed from Assigned to In Test
Actions #6

Updated by Amber Herold over 14 years ago

  • Assignee changed from Amber Herold to Eric Hou
Actions #7

Updated by Eric Hou over 14 years ago

  • Status changed from In Test to Closed
Actions

Also available in: Atom PDF