Class BusinessRecordDataExtensions
Extension methods to make it easy to fetch BusinessRecordData objects from the database,
using the infrastructure
Inheritance
BusinessRecordDataExtensions
Assembly: SoDataBase.dll
Syntax
public static class BusinessRecordDataExtensions : Object
Methods
FromRecord(TargetedDataRecord<BusinessTableInfo>)
From a TargetedDataRecord<BusinessTableInfo>, create and populate a BusinessRecordData POCO object
Declaration
public static BusinessRecordData FromRecord(this TargetedDataRecord<BusinessTableInfo> record)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
/* add joins, return fields etc. as you wish */
s.ReturnFields.Add(s.Table.All);
var result = s.Records().Select(r => new { BusinessItem = r.FromRecord(), /* fetch other fields here */ });
FromSelect(TargetedSelect<BusinessTableInfo>)
From a TargetedSelect<BusinessTableInfo>, execute it and return an IEnumerable<BusinessRecordData> with the results
Declaration
public static IEnumerable<BusinessRecordData> FromSelect(this TargetedSelect<BusinessTableInfo> select)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
ToInsert(BusinessRecordData)
Extension methods to make it easy to fetch BusinessRecordData objects from the database,
using the infrastructure
Declaration
public static Insert ToInsert(this BusinessRecordData record)
Parameters
Returns
ToInserts(IEnumerable<BusinessRecordData>)
Extension methods to make it easy to fetch BusinessRecordData objects from the database,
using the infrastructure
Declaration
public static IEnumerable<Insert> ToInserts(this IEnumerable<BusinessRecordData> records)
Parameters
Returns
ToRecordData(BusinessRow)
Extension methods to make it easy to fetch BusinessRecordData objects from the database,
using the infrastructure
Declaration
public static BusinessRecordData ToRecordData(this BusinessRow row)
Parameters
Returns