Search found 3 matches

by fcasado
Thu 03 Sep 2009 09:00
Forum: dotConnect for PostgreSQL
Topic: Bug with linq to postgresql with mono
Replies: 5
Views: 3450

Ok, thank you for your answer.

Maybe you can help me with telling which other database I can use with linq from a mono application?
Can I access a sql server express one using linq? Or maybe MySQL...
My issue, is that I bought the dotconnect for postgreSQL specially for this...
by fcasado
Wed 02 Sep 2009 13:03
Forum: dotConnect for PostgreSQL
Topic: Bug with linq to postgresql with mono
Replies: 5
Views: 3450

Maybe that can help, in the autogenerated DataContext file, if I replace all the private properties _prop to public properties:

I get this:
Bad Storage property: '_TSId' on member 'AXISTaskSetManager.Models.TaskSet.TSId'

Description: HTTP 500. Error processing request.

Stack Trace:

System.InvalidOperationException: Bad Storage property: '_TSId' on member 'AXISTaskSetManager.Models.TaskSet.TSId'
at Devart.Data.Linq.Mapping.f..ctor (Devart.Data.Linq.Mapping.h,System.Reflection.MemberInfo,int)
at Devart.Data.Linq.Mapping.h.e ()
at Devart.Data.Linq.Mapping.h..ctor (System.Data.Linq.Mapping.MetaModel,System.Data.Linq.Mapping.MetaTable,System.Type,System.Data.Linq.Mapping.MetaType)
at Devart.Data.Linq.Mapping.p..ctor (Devart.Data.Linq.Mapping.d,Devart.Data.Linq.Mapping.a,System.Type)
at Devart.Data.Linq.Mapping.a..ctor (Devart.Data.Linq.Mapping.d,System.Data.Linq.Mapping.TableAttribute,System.Type)
at Devart.Data.Linq.Mapping.d.d (System.Type)
at Devart.Data.Linq.Mapping.d.b (System.Type)
at Devart.Data.Linq.DataContext.GetTable ()
at AXISTaskSetManager.Models.MacroFarmDataBaseDataContext.get_TaskSets ()
at AXISTaskSetManager.Controllers.TaskSetController.Index ()
at (wrapper dynamic-method) System.Runtime.CompilerServices.ExecutionScope.lambda_method (System.Runtime.CompilerServices.ExecutionScope,System.Web.Mvc.ControllerBase,object[])
at System.Web.Mvc.ActionMethodDispatcher.Execute (System.Web.Mvc.ControllerBase,object[])
at System.Web.Mvc.ReflectedActionDescriptor.Execute (System.Web.Mvc.ControllerContext,System.Collections.Generic.IDictionary`2)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod (System.Web.Mvc.ControllerContext,System.Web.Mvc.ActionDescriptor,System.Collections.Generic.IDictionary`2)
at System.Web.Mvc.ControllerActionInvoker/c__DisplayClassa.b__7 ()
at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter (System.Web.Mvc.IActionFilter,System.Web.Mvc.ActionExecutingContext,System.Func`1)
by fcasado
Wed 02 Sep 2009 10:39
Forum: dotConnect for PostgreSQL
Topic: Bug with linq to postgresql with mono
Replies: 5
Views: 3450

Bug with linq to postgresql with mono

Hi,
I know it's not the easiest configuration to run but here it is:

mono 2.4.2.3 and mod_mono 2.4.2 manually compiled
apache 2.2.11
PostgreSQL 8.3

The application is an ASP.NET MVC application which is running perfectly under windows debug server.

Under apache (and the configuration descripbed), pages works while they don't access to the database throught LinqToSQL model generated with Entity Developer for dotConnect 2.20.35.

Once a page is accessing to the datamodel, here is the stacktrace sample:

Server Error in '/macrofarm' Application
Field `AXISTaskSetManager.Models.Workflow:_WorkflowId' is inaccessible from method `(wrapper dynamic-method) object:xget__WorkflowId_55 (AXISTaskSetManager.Models.Workflow)'

Description: HTTP 500. Error processing request.

Stack Trace:

System.FieldAccessException: Field `AXISTaskSetManager.Models.Workflow:_WorkflowId' is inaccessible from method `(wrapper dynamic-method) object:xget__WorkflowId_55 (AXISTaskSetManager.Models.Workflow)'

at (wrapper managed-to-native) System.Delegate:CreateDelegate_internal (System.Type,object,System.Reflection.MethodInfo)
at System.Delegate.CreateDelegate (System.Type type, System.Object firstArgument, System.Reflection.MethodInfo method, Boolean throwOnBindFailure) [0x00251] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/corlib/System/Delegate.cs:256
at System.Delegate.CreateDelegate (System.Type type, System.Reflection.MethodInfo method, Boolean throwOnBindFailure) [0x00000] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/corlib/System/Delegate.cs:278
at System.Delegate.CreateDelegate (System.Type type, System.Reflection.MethodInfo method) [0x00000] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/corlib/Assembly/AssemblyInfo.cs:1
at System.Reflection.Emit.DynamicMethod.CreateDelegate (System.Type delegateType) [0x00029] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/corlib/System.Reflection.Emit/DynamicMethod.cs:176
at Devart.Data.Linq.Mapping.m.a (System.Type A_0, System.Reflection.FieldInfo A_1) [0x00000]
at Devart.Data.Linq.Mapping.f.a (System.Type A_0, System.Reflection.MemberInfo A_1, System.Data.Linq.Mapping.MetaAccessor A_2) [0x00000]
at Devart.Data.Linq.Mapping.f.a () [0x00000]
at Devart.Data.Linq.Mapping.f.i () [0x00000]
at Devart.Data.Linq.Provider.Query.ao.a (Devart.Data.Linq.Provider.Query.f A_0, System.Data.Linq.Mapping.MetaType A_1, System.Collections.Generic.List`1& A_2, System.Collections.Generic.List`1& A_3, Devart.Data.Linq.Provider.Query.SqlExpression& A_4, IList`1 A_5) [0x00000]
at Devart.Data.Linq.Provider.Query.ao.b (Devart.Data.Linq.Provider.Query.f A_0, System.Data.Linq.Mapping.MetaType A_1, System.Collections.Generic.List`1& A_2, System.Collections.Generic.List`1& A_3, Devart.Data.Linq.Provider.Query.SqlExpression& A_4, IList`1 A_5) [0x00000]
at Devart.Data.Linq.Provider.Query.ao.a (Devart.Data.Linq.Provider.Query.f A_0, IList`1 A_1) [0x00000]
at Devart.Data.Linq.Provider.Query.ao.a (System.Data.Linq.Mapping.MetaType A_0, ITable A_1, IList`1 A_2) [0x00000]
at Devart.Data.Linq.Provider.Query.ao.a (System.Data.Linq.Mapping.MetaType A_0, ITable A_1) [0x00000]
at Devart.Data.Linq.Provider.Query.bk.a (ITable A_0) [0x00000]
at Devart.Data.Linq.Provider.Query.bk.a (System.Linq.Expressions.ConstantExpression A_0) [0x00000]
at Devart.Data.Linq.Provider.Query.bk.j (System.Linq.Expressions.Expression A_0) [0x00000]
at Devart.Data.Linq.Provider.Query.bk.i (System.Linq.Expressions.Expression A_0) [0x00000]
at Devart.Data.Linq.Provider.DataProvider.a (System.Linq.Expressions.Expression A_0) [0x00000]
at Devart.Data.Linq.Provider.DataProvider.i (System.Linq.Expressions.Expression A_0) [0x00000]
at Devart.Data.Linq.Table`1[AXISTaskSetManager.Models.Workflow].b () [0x00000]
at Devart.Data.Linq.Table`1[AXISTaskSetManager.Models.Workflow].GetEnumerator () [0x00000]
at Devart.Data.Linq.Table`1[AXISTaskSetManager.Models.Workflow].j () [0x00000]
at ASP.views_workflow_index_aspx.__Render_Content2 (System.Web.UI.HtmlTextWriter __output, System.Web.UI.Control parameterContainer) [0x0000b] in /var/www/macrofarm/Views/Workflow/Index.aspx:22
at System.Web.UI.Control.RenderChildren (System.Web.UI.HtmlTextWriter writer) [0x0000b] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1129
at System.Web.UI.Control.Render (System.Web.UI.HtmlTextWriter writer) [0x00000] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1118
at System.Web.UI.Control.RenderControl (System.Web.UI.HtmlTextWriter writer) [0x0005f] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1310
at ASP.views_shared_site_master.__RenderTree (System.Web.UI.HtmlTextWriter __output, System.Web.UI.Control parameterContainer) [0x000d4] in /tmp/www-data-temp-aspnet-0/af7f4991/App_Web_17ad5a0_1.cs:148
at System.Web.UI.Control.RenderChildren (System.Web.UI.HtmlTextWriter writer) [0x0000b] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1129
at System.Web.UI.Control.Render (System.Web.UI.HtmlTextWriter writer) [0x00000] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1118
at System.Web.UI.Control.RenderControl (System.Web.UI.HtmlTextWriter writer) [0x0005f] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1310
at System.Web.UI.Control.RenderChildren (System.Web.UI.HtmlTextWriter writer) [0x0006d] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1143
at System.Web.UI.Control.Render (System.Web.UI.HtmlTextWriter writer) [0x00000] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1118
at System.Web.UI.Page.Render (System.Web.UI.HtmlTextWriter writer) [0x00172] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Page.cs:1136
at System.Web.Mvc.ViewPage.Render (System.Web.UI.HtmlTextWriter writer) [0x00000]
at System.Web.UI.Control.RenderControl (System.Web.UI.HtmlTextWriter writer) [0x0005f] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Control.cs:1310
at System.Web.UI.Page.RenderPage () [0x00032] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Page.cs:1679
at System.Web.UI.Page.InternalProcessRequest () [0x001d7] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Page.cs:1544
at System.Web.UI.Page.ProcessRequest (System.Web.HttpContext context) [0x0005b] in /home/speeral/Desktop/mono-2.4.2.3/mcs/class/System.Web/System.Web.UI/Page.cs:1353

Version information: Mono Version: 2.0.50727.1433; ASP.NET Version: 2.0.50727.1433








The bug is on pages accessing to