get rid of parametrized query, in case this is the .NET issue (I hope not)

afrisby
Sean Dague 2007-11-14 15:52:39 +00:00
parent 870837d4a8
commit 02b6f6ca62
1 changed files with 5 additions and 5 deletions

View File

@ -269,15 +269,15 @@ namespace OpenSim.DataStore.MonoSqlite
double[,] terret = new double[256,256];
terret.Initialize();
String sql = "select RegionUUID, Revision, Heightfield from terrain" +
" where RegionUUID=:RegionUUID order by Revision desc limit 1";
" where RegionUUID='" + regionID.ToString() + "' order by Revision desc limit 1";
using (IDbCommand cmd = conn.CreateCommand())
{
cmd.CommandText = sql;
SqliteParameter param = new SqliteParameter(":RegionUUID", regionID.ToString());
param.SourceColumn = "RegionUUID";
param.SourceVersion = DataRowVersion.Current;
cmd.Parameters.Add(param);
// SqliteParameter param = new SqliteParameter(":RegionUUID", regionID.ToString());
// param.SourceColumn = "RegionUUID";
// param.SourceVersion = DataRowVersion.Current;
// cmd.Parameters.Add(param);
using (IDataReader row = cmd.ExecuteReader())
{