From: Cserna Z. <cs...@ho...> - 2003-12-01 11:34:21
|
Hi! I have a big problem. If I use the provider (RC7 in Windows XP, C# Builder), and my project has the provider, the speed is good Sample -------- Code 1.: FbConnection myConnection = new FbConnection( - Connection String - ); myConnection.Open(); FbTransaction myTransaction = MyConnection.BeginTransaction(); FbCommand myCommand = new FbCommand("select * from table", myConnection, myTransaction); FbDataReader myReader; myReader = myCommand.ExecuteReader(); while (myReader.Read()) { ... doing something ... } myReader.Close(); myTransaction.Commit(); myConnection.Close(); >> it's about 1.5 secound ------ But, if this code is in a Class Library (.dll), and my program call the class library's function, the program is very slow... I don't understand why ------ Code 2.: Class Library using System; using FirebirdSql.Data.Firebird; public class TestClass { public TestClass() { } public static void RunTest() { Code 1. } } Program public void myMethod() { TestClass.RunTest(); } >> it's takes me about 6 secounds ------- If you know the solution, please tell me. Thanks Zsombor Cserna (cs...@ho...) |