fixes node 4053, upgrade patch fails because wiki_pages table does not exist if wiki plugin has not been activated

Modified most of the SQL statements so they would not fail, but no easy
way to fix line 10.  To work around this patch.php was modified so it
continues to execute all SQL statements even if one fails.  A longer
term fix would be to include the table name as a separate parameter on
each line in the .sql patch files, then have patch.php verify that the
table exists before executing the sql statement.