开发者

How to Group By on the Vector Field

I am working Linq Query, but I am not able to Group by with Vector field.

and my Linq Query is like this..

var Query = (from a in Helper.db.AccountStatement
                             join b in Helper.db.BankAccount on a.BankAccId equals b.BankAccId
                             join c in Helper.db.BankBranch on b.BankBranchId equals c.BankBranchId
                             join d in Helper.db.Bank on c.BankId equals d.BankId
                             where b.AccType == AccType && a.ActiveStatement == true && b.ActiveAccount == true && b.UserId == UserId
             开发者_如何学运维                group new{ a,b,d} by new {b.BankAccId,d.Name,b.AccNumber,a.ClosingBalance,d.Logo} into h
                             select new clsFillBankSymmary
                             {

                                 BankAccountId = h.Key.BankAccId,
                                 BankName = h.Key.Name,
                                 BankAccountNo =h.Key.AccNumber,
                                 ClosingBalance = h.Key.ClosingBalance,
                                 BankLogo = (byte[])h.Key.VectorLogo.ToArray()
                             });


                    return Query;`

Thanks...!!!


As of LINQ, changing the DB type of the Vector column to varbinary(MAX) should do the trick.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜