Subject Embedded Server Forced Writes Not Working
Author WKANDE
Firebird 1.5.3
.Net Provider 1.7
Windos XP SP2

I am notable to see forced writes actually cause writes until my app
shuts down. My understanding is that Forced Write is turned on by
default and infact if I move the database to a superserver and perform
SHOW DATABASE using isql it shows Forced Writes as true. The
DatabaseInfo class of the provider shows that Forced Write is enabled as
well.

Here is a quick test from an application that creates a database, a
table and adds 5000 rows. As soon as the database is created the
filesystem shows a new file of around 620K. After the insert the size is
still the same. Once the app is closed the file then grows to 824K or
so.

Has anyway seem this issue with EMBEDDED server or have any insight to
the problem.

private void buttonCreateAndRun_Click(object sender, EventArgs
e)
{
try
{
FbConnectionStringBuildercs = new
FbConnectionStringBuilder();
cs.Database = "DATA.FDB";
cs.ServerType = 1;
FbConnection.CreateDatabase(cs.ToString());

FbConnectioncon = new FbConnection(cs.ToString());
FbCommandcmd = new FbCommand("CREATE TABLE \"COLORS\" " +
"(idinteger not null," +
"colorchar(10))",con);
con.Open();
cmd.ExecuteNonQuery();



// Insert
for (int i = 0; i < 5000; i++)
{
cmd= new FbCommand(" INSERT into colors " +
"VALUES " +
"("+i+", 'Red') ", con);
introwCount = (int)cmd.ExecuteNonQuery();
}
con.Close();

}
catch (Exception ex) { Console.WriteLine(ex.ToString()); }
}