linq的SelectParameters和WhereParameters有什么区别?
我想要做出两个表嵌套的那种效果,一个是从表. 刚开始见到的是主表,当点击主表某一行时,在该行的下面显示出对应的从表的信息.
可是用 linq 的这个WhereParameters属性 怎么都没有用!~哪位大虾帮帮忙!~
<uc:MyLinq ID="linq2" runat="server" ContextTypeName="BSC.PMS.BLL.mydb" TableName="sales" EnableDelete="True" EnableInsert="True" EnableUpdate="True" OrderBy="amount" Select="tenant_id=@tid"
<WhereParameters>
<asp:ControlParameter ControlID="grid" Name="tid" PropertyName="SelectedValue" DbType="Int32" />
</WhereParameters>
</uc:MyLinq>
linq 的Where都不会解析这个@tid ,就直接查询tenant_id=@tid
有谁知道什么原因吗????