Hello everybody,
I'm new in Firebird, but as much I can tell you, I like it. :-)
I started to write a small C# program to try Firebird, in order to use it later.
First step was embedded server, because it does not need anything,
only a DLL (I'm using Windows). But I immediately got a problem, which
I couldn't solve until now. I read every documents which looked like
connecting to this topic, but no success.
I created a table like this:
/* Table: PLACES, Owner: SYSDBA */
CREATE TABLE "PLACES"
(
"ID" INT64 NOT NULL,
"NAME" VARCHAR(256) CHARACTER SET ISO8859_2 NOT NULL COLLATE ISO_HUN,
"DESCRIPTION" VARCHAR(256) CHARACTER SET ISO8859_2 COLLATE ISO_HUN,
"AMOUNT" INT64 Default 0 NO NULL,
"VALID" CHAR(1) CHARACTER SET ISO8859_2 Default '1' NOT NULL COLLATE ISO_HUN,
PRIMARY KEY("ID")
);
So as you can see, nothing really special.
The code I used, also really simple:
DataSet dataSet = new DataSet();
FBConnection sqlConnection = new
FBConnection(@"Database=mysql.fdb;ServerType=1");
sqlConnection.Open();
FbDataAdapter sqlDataAdapter = new FBDataAdapter("select id, name from
places order by name", sqlConnection);
sqlDataAdapter.Fill(dataSet, "places");
sqlConnection.Close();
It is placed in a Windows.Forms.Form constructor.
The problem is: if I run this code, it goes to somewhere at
adapter.Fill and never returns. The VS IDE shows Running status, but
looses focus, like it tries to switch to the opening application, and
hangs.
What I already achieved: if I remove the "order by name" part, it
works! This is strange. I installed the standard Firebird server and
open the database through it ( FBConnection sqlConnection = new
FbConnection(@"User=SYSDBA;Password=masterkey;Database=c:\mysql.fdb;Datasource=localhost");
);
and the select is working. With or without the "order by" part.
Any ideas, what I missed, or what can be the problem?
Environment: Windows 2000, .NET Framework 2.0, Visual Studio 2005 C#,
FireBirdClient 2.0 stable.
Thanks in advance
Imre
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Firebird-net-provider mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider