Class SubscriptionUnitRecordDataExtensions
Extension methods to make it easy to fetch SubscriptionUnitRecordData objects from the database,
using the TargetedSelect infrastructure
Inheritance
SubscriptionUnitRecordDataExtensions
Assembly: SoDataBase.dll
Syntax
public static class SubscriptionUnitRecordDataExtensions
Methods
FromRecord(TargetedDataRecord<SubscriptionUnitTableInfo>)
Declaration
public static SubscriptionUnitRecordData FromRecord(this TargetedDataRecord<SubscriptionUnitTableInfo> 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 { SubscriptionUnitItem = r.FromRecord(), /* fetch other fields here */ });
FromSelect(TargetedSelect<SubscriptionUnitTableInfo>)
From a TargetedSelect<SubscriptionUnitTableInfo>, execute it and return an IEnumerable<SubscriptionUnitRecordData> with the results
Declaration
public static IEnumerable<SubscriptionUnitRecordData> FromSelect(this TargetedSelect<SubscriptionUnitTableInfo> select)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
FromSelectAsync(TargetedSelect<SubscriptionUnitTableInfo>, CancellationToken)
From a TargetedSelect<SubscriptionUnitTableInfo>, execute it and return an IEnumerable<SubscriptionUnitRecordData> with the results
Declaration
[CreateSyncVersion(OmitNullableDirective = true)]
public static IAsyncEnumerable<SubscriptionUnitRecordData> FromSelectAsync(this TargetedSelect<SubscriptionUnitTableInfo> select, CancellationToken cancellationToken = default)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
ToInsertAsync(SubscriptionUnitRecordData, CancellationToken)
Extension methods to make it easy to fetch SubscriptionUnitRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static Task<Insert> ToInsertAsync(this SubscriptionUnitRecordData record, CancellationToken cancellationToken = default)
Parameters
Returns
ToInsertsAsync(IEnumerable<SubscriptionUnitRecordData>, CancellationToken)
Extension methods to make it easy to fetch SubscriptionUnitRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static IAsyncEnumerable<Insert> ToInsertsAsync(this IEnumerable<SubscriptionUnitRecordData> records, CancellationToken cancellationToken = default)
Parameters
Returns
ToRecordData(SubscriptionUnitRow)
Extension methods to make it easy to fetch SubscriptionUnitRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static SubscriptionUnitRecordData ToRecordData(this SubscriptionUnitRow row)
Parameters
Returns