Server Error in '/' Application.

Syntax error: The IN keyword must be followed by a non-empty list of expressions separated by commas, and also must be enclosed in parentheses.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.SyntaxErrorException: Syntax error: The IN keyword must be followed by a non-empty list of expressions separated by commas, and also must be enclosed in parentheses.

Source Error:


Line 23:         }
Line 24:         DataTable dt = KindUtils.GetAllFrontDisplay();
Line 25:         DataRow[] lv1 = dt.Select("n_sj=0 and id in("+k1+")", "n_order asc");//查詢一級欄目
Line 26:         title = lv1[0]["C_KIND_NAME"].ToString();
Line 27:     }

Source File: c:\111\wwwroot\Controllers\lanmu.ascx.cs    Line: 25

Stack Trace:


[SyntaxErrorException: Syntax error: The IN keyword must be followed by a non-empty list of expressions separated by commas, and also must be enclosed in parentheses.]
   System.Data.FunctionNode.Check() +1286533
   System.Data.FunctionNode.Bind(DataTable table, List`1 list) +27
   System.Data.BinaryNode.Bind(DataTable table, List`1 list) +48
   System.Data.BinaryNode.Bind(DataTable table, List`1 list) +48
   System.Data.DataExpression.Bind(DataTable table) +84
   System.Data.DataExpression..ctor(DataTable table, String expression, Type type) +5314983
   System.Data.Select..ctor(DataTable table, String filterExpression, String sort, DataViewRowState recordStates) +73
   System.Data.DataTable.Select(String filterExpression, String sort) +59
   aspx_Controllers_lanmu.Page_Load(Object sender, EventArgs e) in c:\111\wwwroot\Controllers\lanmu.ascx.cs:25
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +51
   System.Web.UI.Control.OnLoad(EventArgs e) +92
   System.Web.UI.Control.LoadRecursive() +54
   System.Web.UI.Control.LoadRecursive() +145
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.18408
http://a26l3bta.juhua576848.cn| http://29v3okun.juhua576848.cn| http://ji8h6.juhua576848.cn| http://rfk9qfe.juhua576848.cn| http://2sgpr.juhua576848.cn| | | | |