1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 00:42:41 +01:00

Minor, fix Paste SQL patch for databases with all warnings turned on.

This column has no default value and throws if you have maximum warnings activated:

  EXCEPTION: (AphrontQueryException) #1364: Field 'commentVersion' doesn't have a default value...

Auditors: btrahan
This commit is contained in:
epriestley 2013-08-04 11:32:32 -07:00
parent 0de3b351b2
commit ed9edc5d3a

View file

@ -21,8 +21,9 @@ foreach ($rows as $row) {
$conn_w, $conn_w,
'INSERT INTO %T (phid, authorPHID, objectPHID, viewPolicy, editPolicy, 'INSERT INTO %T (phid, authorPHID, objectPHID, viewPolicy, editPolicy,
transactionType, oldValue, newValue, transactionType, oldValue, newValue,
contentSource, metadata, dateCreated, dateModified) contentSource, metadata, dateCreated, dateModified,
VALUES (%s, %s, %s, %s, %s, %s, %ns, %ns, %s, %s, %d, %d)', commentVersion)
VALUES (%s, %s, %s, %s, %s, %s, %ns, %ns, %s, %s, %d, %d, %d)',
$x_table->getTableName(), $x_table->getTableName(),
$xaction_phid, $xaction_phid,
$row['authorPHID'], $row['authorPHID'],
@ -37,7 +38,8 @@ foreach ($rows as $row) {
array())->serialize(), array())->serialize(),
'[]', '[]',
$row['dateCreated'], $row['dateCreated'],
$row['dateCreated']); $row['dateCreated'],
0);
} }