FeResPost Web Site                     FeResPost Online User Manual

IX.1.5 Saving and retrieving Results from an SQL database

This example is presented in the files “rehashDynamicResults.cs” and “deleteSomeResults.cs” of directory “TESTSAT/NET/EX20”, and corresponds exactly to the Ruby examples of section IV.2.6.

Access to the SQLite .NET assembly, which must be installed on the computer, is granted by the following statement:

    using System.Data.SQLite ;

Note also the binding of parameters to the SQLite command:

        cmd.CommandText = sql;
        cmd.Parameters.Clear();
        cmd.Parameters.AddWithValue("@lcName", id[0]);
        cmd.Parameters.AddWithValue("@scName", id[1]);
        cmd.Parameters.AddWithValue("@resName", id[2]);
        cmd.Parameters.AddWithValue("@tensorOrder", tensorOrder);
        cmd.Parameters.AddWithValue("@intId1", intId1);
        cmd.Parameters.AddWithValue("@intId2", intId2);
        cmd.Parameters.AddWithValue("@realId1", realId1);
        cmd.Parameters.AddWithValue("@realId2", realId2);
        cmd.Parameters.AddWithValue("@size", size);
        cmd.Parameters.AddWithValue("@result", resBlob);
        cmd.ExecuteNonQuery();