Server Error in '/' Application.

ERROR [42601] ERROR: syntax error at or near "vsya_sp_GetProjectsEntries";
Error while executing the query

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.Odbc.OdbcException: ERROR [42601] ERROR: syntax error at or near "vsya_sp_GetProjectsEntries";
Error while executing the query

Source Error:


Line 191:            if (dbconn.State == ConnectionState.Closed) { dbconn.Open(); }
Line 192:			OdbcCommand cmd = new OdbcCommand(sql, dbconn);
Line 193:			OdbcDataReader reader = cmd.ExecuteReader(CommandBehavior.CloseConnection);
Line 194:            DataTable dt = new DataTable();
Line 195:			dt.Load(reader);

Source File: c:\WEBROOT\AVerySeniorYearAbroad\App_Code\SQLServerAccessObject.cs    Line: 193

Stack Trace:


[OdbcException (0x80131937): ERROR [42601] ERROR: syntax error at or near "vsya_sp_GetProjectsEntries";
Error while executing the query]
   System.Data.Odbc.OdbcConnection.HandleError(OdbcHandle hrHandle, RetCode retcode) +41
   System.Data.Odbc.OdbcCommand.ExecuteReaderObject(CommandBehavior behavior, String method, Boolean needReader, Object[] methodArguments, SQL_API odbcApiMethod) +2933
   System.Data.Odbc.OdbcCommand.ExecuteReaderObject(CommandBehavior behavior, String method, Boolean needReader) +105
   System.Data.Odbc.OdbcCommand.ExecuteReader(CommandBehavior behavior) +92
   AVSYA.SQLServerAccessObject.GetDataTable(String sql) in c:\WEBROOT\AVerySeniorYearAbroad\App_Code\SQLServerAccessObject.cs:193
   AVSYA.SQLServerAccessObject.GetDataTable() in c:\WEBROOT\AVerySeniorYearAbroad\App_Code\SQLServerAccessObject.cs:188
   SiteMap.Page_Load(Object sender, EventArgs e) in c:\WEBROOT\AVerySeniorYearAbroad\SiteMap.aspx.cs:19
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +42
   System.Web.UI.Control.OnLoad(EventArgs e) +132
   System.Web.UI.Control.LoadRecursive() +66
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2428


Version Information: Microsoft .NET Framework Version:2.0.50727.8000; ASP.NET Version:2.0.50727.8001