Server Error in '/' Application.

Incorrect syntax near ','.

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.OleDb.OleDbException: Incorrect syntax near ','.

Source Error:


Line 50: 				  Dim sqlmmg As String = "select * from script where id=" & ids  
Line 51: 				  cmdmmg = New OleDbCommand(sqlmmg, cnmmg)
Line 52: 				  rdmmg = cmdmmg.ExecuteReader()
Line 53: 				  
Line 54: 				  While (rdmmg.Read())

Source File: \\smb-whst-www11\whst_www11$\8b7246544.hostnd\htdocs\www\appunti\scheda.aspx    Line: 52

Stack Trace:


[OleDbException (0x80040e14): Incorrect syntax near ','.]
   System.Data.OleDb.OleDbDataReader.ProcessResults(OleDbHResult hr) +1247602
   System.Data.OleDb.OleDbDataReader.NextResult() +433
   System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior behavior, String method) +241
   System.Data.OleDb.OleDbCommand.ExecuteReader(CommandBehavior behavior) +115
   System.Data.OleDb.OleDbCommand.ExecuteReader() +12
   ASP.appunti_scheda_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in \\smb-whst-www11\whst_www11$\8b7246544.hostnd\htdocs\www\appunti\scheda.aspx:52
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +270
   System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +14
   System.Web.UI.Page.Render(HtmlTextWriter writer) +30
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +67
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +101
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +27
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1342


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4700.0