Changeset 258 for Network


Ignore:
Timestamp:
Jul 26, 2011, 1:05:39 PM (13 years ago)
Author:
george
Message:
  • Minor modifications
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Network/CoolWeb/Persistence/USqlDatabase.pas

    r250 r258  
    312312    StringReplace(Value, '"', '\"', [rfReplaceAll]);
    313313    if Value = 'NOW()' then DbValues := DbValues + ',' + Value
    314     else DbValues := DbValues + ',' + Data.Keys[I] + '=' + '"' + Value + '"';
     314    else DbValues := DbValues + ',`' + Data.Keys[I] + '` =' + '"' + Value + '"';
    315315  end;
    316316  System.Delete(DbValues, 1, 1);
     
    318318    DbResult := TDbRows.Create;
    319319    if Schema <> '' then Schema := '`' + Schema + '`.';
    320     Query(DbResult, 'UPDATE ' + Schema + '`' + ATable + '` SET (' + DbValues + ') WHERE ' + Condition);
     320    Query(DbResult, 'UPDATE ' + Schema + '`' + ATable + '` SET ' + DbValues + ' WHERE ' + Condition);
    321321  finally
    322322    DbResult.Free;
Note: See TracChangeset for help on using the changeset viewer.