Forums / Bugs & Issues / Events: Ambiguous column name 'DateCreated'

Events: Ambiguous column name 'DateCreated'

3 posts, 0 answered
  1. Chanan Zass
    Chanan Zass avatar
    118 posts
    Registered:
    21 Aug 2012
    25 Apr 2009
    Link to this post
    Just upgraded from Version 3.5 to 3.6 SP1.
    Everything seems to be working fine. Except viewing of single events.
    List of events is created properly, but when I click to see a single events, I get this error:

    Ambiguous column name 'DateCreated'
    Exception Data: System.Data.SqlClient.SqlException: Ambiguous column name 'DateCreated'.

    Stack details:
    [SqlException (0x80131904): Ambiguous column name 'DateCreated'.]
       System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) +925466
       System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +800118
       System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +186
       System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +1932
       System.Data.SqlClient.SqlDataReader.ConsumeMetaData() +31
       System.Data.SqlClient.SqlDataReader.get_MetaData() +62
       System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) +297
       System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) +1005
       System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) +132
       System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) +32
       System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) +122
       System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) +12
       System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader() +9
       Nolics.ORMapper.DataProviders.SQLBlockBuilder.EndStatement(SQLCommandEventArgs args, DataRow row) +389
       Telerik.Cms.Engine.Data.Providers.GCSql2005Builder.EmitReversePriorityQuery(StmtContext context, DataRow queryData, Int32 maxRows, String groupName) +1753
       Telerik.Cms.Engine.Data.Providers.GCSql2005Builder.EmitQuery(StmtContext context, DataRow queryData, Int32 maxRows, String groupName) +324
       Nolics.ORMapper.DataProviders.SQLBlockBuilder.ExecuteQuery(StmtContext context, DataRow queryData, Int32 maxRows, String group) +106
       Nolics.ORMapper.DataProviders.SQLDataProvider.ExecQuery(DataSet queries) +512
       Nolics.ORMapper.Base.QueryBase`1.LoadQuery(Int32 maxElements, Int32 fromElement) +275
       Nolics.ORMapper.Base.QueryBase`1.LoadAll() +20
       Telerik.Cms.Engine.Data.Providers.DefaultProvider.GetComments(Guid itemId, Boolean showVisible, String sortExp) +319
       Telerik.Cms.Engine.ContentManager.GetComments(Guid itemId, Boolean showVisible, String sortExp) +173
       Telerik.Cms.Engine.WebControls.CommentsList.InitializeControls(Control controlContainer) +214
       Telerik.Cms.Web.UI.SimpleControl.CreateChildControls() +70
       System.Web.UI.Control.EnsureChildControls() +87
       System.Web.UI.Control.PreRenderRecursiveInternal() +50
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Control.PreRenderRecursiveInternal() +170
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2041

    -------------------------------------------------------------
    On our local server it works. On the production server, no.
    Both use the same version, same database.
    Question: If DateCreated is ambiguous when displaying the single event, how is it not ambiguous when displaying ALL the events?

    Any clue?


  2. Chanan Zass
    Chanan Zass avatar
    118 posts
    Registered:
    21 Aug 2012
    25 Apr 2009
    Link to this post
    All resolved.
    Problem was due to SQL 2005 Express compatibility level.
    Found out it was set to "SQL Server 2000 (80)" for some reason.
    Once I set it to "SQL Server 2005 (90)" all is bliss.

    Right-click your database and select Properties.
    Click "Options" and change "Compatibility Level".

    I've read on the Internet that in some cases doing the opposite (switching to lower level compatibility) fixes similar problems.

    Hope that helps someone.
  3. Ivan Dimitrov
    Ivan Dimitrov avatar
    16051 posts
    Registered:
    24 Sep 2012
    27 Apr 2009
    Link to this post
    Hello Chanan Zass,

    Thank you for sharing the solution to this problem to us. I hope this will help to the other community m embers if they have the same problems.

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Register for webinar
3 posts, 0 answered