aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MSSQL/MSSQLGridData.cs
diff options
context:
space:
mode:
authorJustin Clarke Casey2009-02-19 18:09:10 +0000
committerJustin Clarke Casey2009-02-19 18:09:10 +0000
commit07609565617aa7936758acba5fd625877564a10d (patch)
tree73123e37f14fea5f171cbe04753c21758f25afc1 /OpenSim/Data/MSSQL/MSSQLGridData.cs
parent* Okay, so finally got my head around this. Problem is that upstream Prebuild... (diff)
downloadopensim-SC_OLD-07609565617aa7936758acba5fd625877564a10d.zip
opensim-SC_OLD-07609565617aa7936758acba5fd625877564a10d.tar.gz
opensim-SC_OLD-07609565617aa7936758acba5fd625877564a10d.tar.bz2
opensim-SC_OLD-07609565617aa7936758acba5fd625877564a10d.tar.xz
* Apply http://opensimulator.org/mantis/view.php?id=3142
* Changes varchar(36) columns to UUID type in MSSQL - this will be much more efficient * ===As always, please, please backup your database before applying this patch=== * Thanks Ruud Lathrop (for the patch) and StrawberryFride (for the review)
Diffstat (limited to 'OpenSim/Data/MSSQL/MSSQLGridData.cs')
-rw-r--r--OpenSim/Data/MSSQL/MSSQLGridData.cs20
1 files changed, 11 insertions, 9 deletions
diff --git a/OpenSim/Data/MSSQL/MSSQLGridData.cs b/OpenSim/Data/MSSQL/MSSQLGridData.cs
index eec2091..027796a 100644
--- a/OpenSim/Data/MSSQL/MSSQLGridData.cs
+++ b/OpenSim/Data/MSSQL/MSSQLGridData.cs
@@ -395,17 +395,17 @@ namespace OpenSim.Data.MSSQL
395 395
396 retval.regionHandle = tmp64; 396 retval.regionHandle = tmp64;
397 397
398 UUID tmp_uuid; 398// UUID tmp_uuid;
399 if (!UUID.TryParse((string)reader["uuid"], out tmp_uuid)) 399// if (!UUID.TryParse((string)reader["uuid"], out tmp_uuid))
400 { 400// {
401 return null; 401// return null;
402 } 402// }
403 403
404 retval.UUID = tmp_uuid; 404 retval.UUID = new UUID((Guid)reader["uuid"]); // tmp_uuid;
405 405
406 // non-critical parts 406 // non-critical parts
407 retval.regionName = reader["regionName"].ToString(); 407 retval.regionName = reader["regionName"].ToString();
408 retval.originUUID = new UUID((string)reader["originUUID"]); 408 retval.originUUID = new UUID((Guid)reader["originUUID"]);
409 409
410 // Secrets 410 // Secrets
411 retval.regionRecvKey = reader["regionRecvKey"].ToString(); 411 retval.regionRecvKey = reader["regionRecvKey"].ToString();
@@ -443,8 +443,10 @@ namespace OpenSim.Data.MSSQL
443 retval.regionUserSendKey = reader["regionUserSendKey"].ToString(); 443 retval.regionUserSendKey = reader["regionUserSendKey"].ToString();
444 444
445 // World Map Addition 445 // World Map Addition
446 UUID.TryParse((string)reader["regionMapTexture"], out retval.regionMapTextureID); 446 retval.regionMapTextureID = new UUID((Guid)reader["regionMapTexture"]);
447 UUID.TryParse((string)reader["owner_uuid"], out retval.owner_uuid); 447 retval.owner_uuid = new UUID((Guid)reader["owner_uuid"]);
448// UUID.TryParse((string)reader["regionMapTexture"], out retval.regionMapTextureID);
449// UUID.TryParse((string)reader["owner_uuid"], out retval.owner_uuid);
448 450
449 return retval; 451 return retval;
450 } 452 }