1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768 |
- using System;
- using System.Collections.Generic;
- using System.Data;
- using System.Reflection;
- using System.Threading;
- using log4net;
- using OpenMetaverse;
- using OpenSim.Framework;
- using MySql.Data.MySqlClient;
- namespace OpenSim.Data.MySQL
- {
-
-
-
- public class MySQLAvatarData : MySQLGenericTableHandler<AvatarBaseData>,
- IAvatarData
- {
- public MySQLAvatarData(string connectionString, string realm) :
- base(connectionString, realm, "Avatar")
- {
- }
- public bool Delete(UUID principalID, string name)
- {
- using (MySqlCommand cmd = new MySqlCommand())
- {
- cmd.CommandText = String.Format("delete from {0} where `PrincipalID` = ?PrincipalID and `Name` = ?Name", m_Realm);
- cmd.Parameters.AddWithValue("?PrincipalID", principalID.ToString());
- cmd.Parameters.AddWithValue("?Name", name);
-
- if (ExecuteNonQuery(cmd) > 0)
- return true;
- }
- return false;
- }
- }
- }
|