Subject | Embedded for Super Server speed |
---|---|
Author | mfakkel |
Post date | 2005-03-25T08:52:03Z |
Using Firebird 1.5...
In my application I have an option to use embedded or super server
as the database engine. When I use the super server option it runs
like the wind. 5000 records in a view gets displayed
instantaneously. When I use the embedded version it looks a lot
slower (by a factor of 3 or 4 probably).
I think the problem is not with the SQL statement that returns a
datareader as this is fast also with the embedded version. However
after getting the data I then have a loop of:
While drDataReader.Read()
....get data using vrDataReader(i) where i is column
End While
I think the speed slowdown is happening in this loop i.e. the data
fetching. Is this expected? Does anyone have similar experiences and
possible solution?
The SELECT statement is simple get everything from table. Connection
used is as follows:
Select Case miEngineType
Case Types.FirebirdClassicServer, Types.FirebirdEmbedded,
Types.FirebirdSuperServer
Select Case miEngineType
Case Types.FirebirdClassicServer,
Types.FirebirdSuperServer
conn.DataSource = "localhost"
conn.Port = 3050%
conn.ServerType = FirebirdServerTypes.Server
Case Types.FirebirdEmbedded
conn.DataSource = "local connect"
'conn.Port = 3050%
conn.ServerType = FirebirdServerTypes.Embedded
End Select
conn.Charset = "NONE"
conn.Database = msFileName
conn.Dialect = 3
conn.PacketSize = 32767
conn.Password = msPassword
conn.UserID = msUserName
End Select
Thanks in advance
Marc
In my application I have an option to use embedded or super server
as the database engine. When I use the super server option it runs
like the wind. 5000 records in a view gets displayed
instantaneously. When I use the embedded version it looks a lot
slower (by a factor of 3 or 4 probably).
I think the problem is not with the SQL statement that returns a
datareader as this is fast also with the embedded version. However
after getting the data I then have a loop of:
While drDataReader.Read()
....get data using vrDataReader(i) where i is column
End While
I think the speed slowdown is happening in this loop i.e. the data
fetching. Is this expected? Does anyone have similar experiences and
possible solution?
The SELECT statement is simple get everything from table. Connection
used is as follows:
Select Case miEngineType
Case Types.FirebirdClassicServer, Types.FirebirdEmbedded,
Types.FirebirdSuperServer
Select Case miEngineType
Case Types.FirebirdClassicServer,
Types.FirebirdSuperServer
conn.DataSource = "localhost"
conn.Port = 3050%
conn.ServerType = FirebirdServerTypes.Server
Case Types.FirebirdEmbedded
conn.DataSource = "local connect"
'conn.Port = 3050%
conn.ServerType = FirebirdServerTypes.Embedded
End Select
conn.Charset = "NONE"
conn.Database = msFileName
conn.Dialect = 3
conn.PacketSize = 32767
conn.Password = msPassword
conn.UserID = msUserName
End Select
Thanks in advance
Marc