Thanks for your help. It looks like when I select the TransactionId, it's returning the count of the root.
The inheritance tree is: Adjustment -> Issuance -> Transfer -> Transaction (root)
The correct counts are:
Transaction - 851857
Transfer - 461439
Issuance - 459167
Adjustment - 63194
In all cases (Transfer, Issuance, and Adjustment), the result is 851857 (incorrect).
(from i in new Old.LinqMetaData().Old_Transfer select i.TransactionId).Count();
// 851857
Generated Sql query:
Query: SELECT TOP(@p2) COUNT(*) AS [LPAV_] FROM (SELECT [LPA_L3].[TransactionId] FROM ( [Pointfolio].[dbo].[Transaction] [LPA_L2] LEFT JOIN [Pointfolio].[dbo].[Transfer] [LPA_L3] ON [LPA_L2].[TransactionId]=[LPA_L3].[TransactionId])) [LPA_L1]
Parameter: @p2 : Int64. Length: 0. Precision: 0. Scale: 0. Direction: Input. Value: 1.
It seems to be including null values. For example, if I actually select the ids into a list then 63194 are valid ids and the rest are empty GUIDS.
var ids = (from i in new Old.LinqMetaData().Old_Adjustment select i.TransactionId).ToList();
ids.Count // 851857
ids.Count(i => i == Guid.Empty) // 788663