Support for Mono with dotconnect for postgresql

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
Posts: 4
Joined: Tue 01 Dec 2009 16:54

Support for Mono with dotconnect for postgresql

Post by Rascal1234 » Fri 10 Dec 2010 19:42

According to the documentation, dotconnect for postgresql should support mono 2.0. I have mono 2.4, while the program executes, the database access fails with the message below. This is a simple test program, when a button is pressed, does the following:

private void button1_Click(object sender, EventArgs e)


DataSourceModel1.DataSourceModel1Entities entities = new DataSourceModel1Entities();

var q = from a in entities.Tests select a;

dataGridView1.DataSource = q;



The entity was created using the Entity Developer 2.50.50. I used visual studio 2008 to compile the program. What is going on here? Is this a matter of assembly versions, or does dotconnect not work with mono?

mono TestDotconnectMono.exe

** (TestDotconnectMono.exe:31220): WARNING **: Method ':_getFiberPtrId ()' in assembly '/home/netadmin/Desktop/untitled folder 2/TestDotconnectMono/TestDotconnectMono/bin/Release/System.Data.dll' contains native code that cannot be executed by Mono on this platform. The assembly was probably created using C++/CLI.

Unhandled Exception: System.TypeInitializationException: An exception was thrown by the type initializer for System.Data.EntityClient.EntityConnection ---> System.TypeInitializationException: An exception was thrown by the type initializer for ---> .ModuleLoadException: The C++ module failed to load.
---> System.MissingMethodException: Method contains unsupported native code
at (wrapper managed-to-native) :_getFiberPtrId ()
at ..LanguageSupport._Initialize (.LanguageSupport* ) [0x00000] in :0
at ..LanguageSupport.Initialize (.LanguageSupport* ) [0x00000] in :0
--- End of inner exception stack trace ---
at ..LanguageSupport.Initialize (.LanguageSupport* ) [0x00000] in :0
at ..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at System.Data.EntityClient.EntityConnection..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at System.Data.Objects.ObjectContext.CreateEntityConnection (System.String connectionString) [0x00000] in :0
at System.Data.Objects.ObjectContext..ctor (System.String connectionString) [0x00000] in :0
at System.Data.Objects.ObjectContext..ctor (System.String connectionString, System.String defaultContainerName) [0x00000] in :0
at DataSourceModel1.DataSourceModel1Entities..ctor () [0x00000] in :0
at TestDotconnectMono.Form1.button1_Click (System.Object sender, System.EventArgs e) [0x00000] in :0
at System.Windows.Forms.Control.OnClick (System.EventArgs e) [0x00000] in :0
at System.Windows.Forms.Button.OnClick (System.EventArgs e) [0x00000] in :0
at System.Windows.Forms.ButtonBase.OnMouseUp (System.Windows.Forms.MouseEventArgs mevent) [0x00000] in :0
at System.Windows.Forms.Button.OnMouseUp (System.Windows.Forms.MouseEventArgs mevent) [0x00000] in :0
at System.Windows.Forms.Control.WmLButtonUp (System.Windows.Forms.Message& m) [0x00000] in :0
at System.Windows.Forms.Control.WndProc (System.Windows.Forms.Message& m) [0x00000] in :0
at System.Windows.Forms.ButtonBase.WndProc (System.Windows.Forms.Message& m) [0x00000] in :0
at System.Windows.Forms.Button.WndProc (System.Windows.Forms.Message& m) [0x00000] in :0
at System.Windows.Forms.Control+ControlWindowTarget.OnMessage (System.Windows.Forms.Message& m) [0x00000] in :0
at System.Windows.Forms.Control+ControlNativeWindow.WndProc (System.Windows.Forms.Message& m) [0x00000] in :0
at System.Windows.Forms.NativeWindow.WndProc (IntPtr hWnd, Msg msg, IntPtr wParam, IntPtr lParam) [0x00000] in :0
netadmin@mail1:~/Desktop/untitled folder 2/TestDotconnectMono/TestDotconnectMono/bin/Release>

Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Tue 14 Dec 2010 15:40

We have made several tests using both Mono on SUSE and Mono for Windows, and failed to reproduce the particular error you have reported.
However, we have received some other errors. None of these errors was associated with our provider, all of them are problems in .NET implementation. There wasn't any call stack containing Devart code.
The tests were performed using the latest Mono and dotConnect versions.

Post Reply