Exemple #1
0
    public static void CreateDatabase(string connectionString, int pageSize = 4096, bool forcedWrites = true, bool overwrite = false)
    {
        var options = new ConnectionString(connectionString);

        options.Validate();

        try
        {
            var db = new FbConnectionInternal(options);
            try
            {
                db.CreateDatabase(pageSize, forcedWrites, overwrite);
            }
            finally
            {
                db.Disconnect();
            }
        }
        catch (IscException ex)
        {
            throw FbException.Create(ex);
        }
    }