Unit:ZDbcGenericResolver. procedure TZGenericCachedResolver.

In this forum we will discuss things relating the ZEOSLib 6.6.x stable versions

Moderators: gto, EgonHugeist

Post Reply
DestinyR
Fresh Boarder
Fresh Boarder
Posts: 9
Joined: 10.03.2010, 16:59

Unit:ZDbcGenericResolver. procedure TZGenericCachedResolver.

Post by DestinyR »

Code: Select all

procedure TZGenericCachedResolver.DefineCalcColumns(Columns: TObjectList;
  RowAccessor: TZRowAccessor);
var
  I: Integer;
begin
  for I := 1 to Metadata.GetColumnCount do
  begin
    if RowAccessor.IsNull(I) and (Metadata.GetTableName(I) <> '')
      and (Metadata.GetDefaultValue(I) <> '') then
    begin
      Columns.Add(TZResolverParameter.Create(I,
        Metadata.GetColumnName(I), Metadata.GetColumnType(I),
        True, Metadata.GetDefaultValue(I)));
    end;
  end;
end;
It is bug? Or why TableName used through ColumnCount.
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

Not 100% sure, but I believe this is just to make sure the tablename of the column is known before retrieiving a default value. If not, there's no way zeoslib can fill a column in the database anyway.

Mark
Image
Post Reply