Ignore:
Timestamp:
Nov 24, 2011, 2:06:10 PM (13 years ago)
Author:
chronos
Message:
  • Modified: Report loading is now done by TChronisClient.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Application/Clients/UChronisClientMySQL.pas

    r33 r34  
    6161      Filter := '';
    6262      for I := 0 to AList.ColumnsFilter.Count - 1 do
    63         Filter := Filter + AList.ColumnsFilter[I] + ',';
    64       Delete(Filter, Length(Filter), 1);
     63        Filter := Filter + '`' + AList.ColumnsFilter[I] + '`, ';
     64      Delete(Filter, Length(Filter) - 1, 2);
    6565    end else Filter := '*';
    6666    if AList.ConditionUse then Condition := '`' + AList.ConditionColumn + '` = "' +
    6767      AList.ConditionValue + '"'
    6868      else Condition := '1';
    69     Database.Select(DbRows, AList.ObjectName, Filter, Condition);
     69    Database.Query(DbRows, 'SELECT ' + Filter + ' FROM `' + AList.SchemaName + '`.`' +
     70      AList.ObjectName + '` WHERE ' + Condition);
    7071    AList.Objects.Clear;
    71     for I := 0 to DbRows.Count - 1 do
     72    for I := 0 to DbRows.Count - 1 do begin
    7273      NewObject := TObjectProxy.Create;
    7374      NewObject.Client := AList.Client;
    7475      NewObject.Properties.Assign(TDictionaryStringString(DbRows[I]));
    7576      AList.Objects.Add(NewObject);
     77    end;
    7678  finally
    7779    DbRows.Free;
Note: See TracChangeset for help on using the changeset viewer.