* fixed pk_violation on rename for MSSQLInventoryData

("le fix le plus ugly for le problem trés dumb")
0.6.0-stable
lbsa71 2008-03-28 14:19:17 +00:00
parent 2eda6a1296
commit 88a14c9a76
1 changed files with 6 additions and 0 deletions

View File

@ -424,6 +424,12 @@ namespace OpenSim.Framework.Data.MSSQL
/// <param name="item">The inventory item</param>
public void addInventoryItem(InventoryItemBase item)
{
if (getInventoryItem(item.inventoryID) != null)
{
updateInventoryItem(item);
return;
}
string sql = "INSERT INTO inventoryitems";
sql +=
"([inventoryID], [assetID], [assetType], [parentFolderID], [avatarID], [inventoryName], [inventoryDescription], [inventoryNextPermissions], [inventoryCurrentPermissions], [invType], [creatorID], [inventoryBasePermissions], [inventoryEveryOnePermissions]) VALUES ";