From 4880bd121e737e0a5c384fddf61bd220c77ef88a Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Wed, 13 Feb 2008 13:39:51 +0000 Subject: * Split out MSSQLManager Test/Init into each provider. * Made regions table name configurable (MSSQL only) * Added a note in ini.example pointing out that the sql resources have to change if you change table names * Removed duplicate picker method from GridData interface [Provided by openlifegrid.com] --- OpenSim/Framework/Data.MSSQL/MSSQLLogData.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'OpenSim/Framework/Data.MSSQL/MSSQLLogData.cs') diff --git a/OpenSim/Framework/Data.MSSQL/MSSQLLogData.cs b/OpenSim/Framework/Data.MSSQL/MSSQLLogData.cs index c3ec7c6..1e83496 100644 --- a/OpenSim/Framework/Data.MSSQL/MSSQLLogData.cs +++ b/OpenSim/Framework/Data.MSSQL/MSSQLLogData.cs @@ -25,6 +25,9 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * */ +using System.Collections.Generic; +using System.Data; + namespace OpenSim.Framework.Data.MSSQL { /// @@ -52,6 +55,18 @@ namespace OpenSim.Framework.Data.MSSQL database = new MSSQLManager(settingDataSource, settingInitialCatalog, settingPersistSecurityInfo, settingUserId, settingPassword); + + IDbCommand cmd = database.Query("select top 1 * from logs", new Dictionary()); + try + { + cmd.ExecuteNonQuery(); + cmd.Dispose(); + } + catch + { + database.ExecuteResourceSql("Mssql-logs.sql"); + } + } /// -- cgit v1.1