A long time ago I made a PROPER script for wiping my vsro database.
This script is the proper way of wiping the database using existing procedures and primary index resets. This script WILL NOT fuck up fortress war like the other one everyone uses.
Included is account, shard and log database.
This script is the proper way of wiping the database using existing procedures and primary index resets. This script WILL NOT fuck up fortress war like the other one everyone uses.
Included is account, shard and log database.
Code:
USE [SRO_VT_ACCOUNT] GO TRUNCATE TABLE [dbo].[__SiegeFortressStatus__] TRUNCATE TABLE [dbo].[__TrijobRanking__] TRUNCATE TABLE [dbo].[__TrijobRankingStatus__] TRUNCATE TABLE [dbo].[_BlockedUser] TRUNCATE TABLE [dbo].[_CasData] TRUNCATE TABLE [dbo].[_CasGMChatLog] TRUNCATE TABLE [dbo].[_LoginLogoutStatistics] --[dbo].[_ModuleVersion] --[dbo].[_ModuleVersionFile] TRUNCATE TABLE [dbo].[_Notice] TRUNCATE TABLE [dbo].[_OldBlockedUser] TRUNCATE TABLE [dbo].[_PrivilegedIP] TRUNCATE TABLE [dbo].[_Punishment] TRUNCATE TABLE [dbo].[_RefCountryNameAndCode] --TRUNCATE TABLE [dbo].[_SecurityDescription] --TRUNCATE TABLE [dbo].[_SecurityDescriptionGroup] --TRUNCATE TABLE [dbo].[_SecurityDescriptionGroupAssign] TRUNCATE TABLE [dbo].[_ServiceManagerLog] TRUNCATE TABLE [dbo].[_Shard] TRUNCATE TABLE [dbo].[_ShardCurrentUser] --[dbo].[_ShardService] TRUNCATE TABLE [dbo].[_SMCLog] TRUNCATE TABLE [dbo].[_WriteOutResetPlayTime] TRUNCATE TABLE [dbo].[BOOKS] TRUNCATE TABLE [dbo].[QuaySoEpoint] TRUNCATE TABLE [dbo].[SK_CharRenameLog] TRUNCATE TABLE [dbo].[SK_DownLevelLog] TRUNCATE TABLE [dbo].[SK_ITEM_GuardLog] TRUNCATE TABLE [dbo].[SK_ItemSaleLog] TRUNCATE TABLE [dbo].[SK_PackageItemSaleLog] TRUNCATE TABLE [dbo].[SK_PK_UpdateLog] TRUNCATE TABLE [dbo].[SK_ResetSkillLog] TRUNCATE TABLE [dbo].[SK_SHL] TRUNCATE TABLE [dbo].[SK_Silk] -- item mall silk table, one row per user. TRUNCATE TABLE [dbo].[SK_SilkBuyList] TRUNCATE TABLE [dbo].[SK_SilkChange_BY_Web] TRUNCATE TABLE [dbo].[SK_SilkGoods] -- packages available to buy online TRUNCATE TABLE [dbo].[SK_SubtractSilk_VAS] TRUNCATE TABLE [dbo].[SR_CharNames] TRUNCATE TABLE [dbo].[SR_ShardCharNames] -- character names per shard id TRUNCATE TABLE [dbo].[TB_Net2e] TRUNCATE TABLE [dbo].[tb_partnerInfo] TRUNCATE TABLE [dbo].[tb_paygate_trans] TRUNCATE TABLE [dbo].[TB_Ref_ItemName] TRUNCATE TABLE [dbo].[TB_User] -- game account database TRUNCATE TABLE [dbo].[Test_HN] TRUNCATE TABLE [dbo].[tmp] DBCC CHECKIDENT (TB_User, RESEED, 0) SET IDENTITY_INSERT [dbo].[TB_User] ON INSERT INTO [dbo].[TB_User] ([JID],[StrUserID],[password],[sec_primary],[sec_content],[AccPlayTime],[LatestUpdateTime_ToPlayTime]) VALUES (-1,'Anonymous','password',3,3,0,0) SET IDENTITY_INSERT [dbo].[TB_User] OFF USE [SRO_VT_SHARD] GO TRUNCATE TABLE [dbo].[_Chest] TRUNCATE TABLE [dbo].[_ChestInfo] TRUNCATE TABLE [dbo].[_User] TRUNCATE TABLE [dbo].[_OpenMarket] DELETE FROM [dbo].[_AccountJID] TRUNCATE TABLE [dbo].[_GuildWar] TRUNCATE TABLE [dbo].[_GuildMember] TRUNCATE TABLE [dbo].[_GuildChest] DELETE FROM [dbo].[_SiegeFortressBattleRecord] DELETE FROM [dbo].[_SiegeFortressRequest] DELETE [dbo].[_SiegeFortressStoneState] EXEC _SiegeFortressResetStructUpgradeLevel_NoTx 1, 0 EXEC _SiegeFortressResetStructUpgradeLevel_NoTx 3, 0 EXEC _SiegeFortressResetStructUpgradeLevel_NoTx 6, 0 DELETE FROM [dbo].[_SiegeFortressStruct] WHERE RefObjID IN (SELECT [ID] FROM _RefObjCommon WITH (NOLOCK) WHERE TypeID1 = 1 AND TypeID2 = 2 AND TypeID3 = 5 AND TypeID4 = 6) TRUNCATE TABLE [dbo].[_SiegeFortressObject] TRUNCATE TABLE [dbo].[_SiegeFortressItemForge] UPDATE [dbo].[_SiegeFortress] SET [GuildID] = 0,[TaxRatio] = 0,[Tax] = 0,[NPCHired] = 0,[TempGuildID] = 0,[Introduction] = 'This fortress is free!',[CreatedDungeonTime] = NULL,[CreatedDungeonCount] = 0 UPDATE [dbo].[_AlliedClans] SET Ally1 = '0', Ally2 = '0', Ally3 = '0', Ally4 = '0', Ally5 = '0', Ally6 = '0', Ally7 = '0', Ally8 = '0' DELETE FROM [dbo].[_Guild] WHERE ID > 0 DELETE FROM [dbo].[_AlliedClans] WHERE ID > 0 TRUNCATE TABLE [dbo].[_InventoryForAvatar] TRUNCATE TABLE [dbo].[_TrainingCampSubMentorHonorPoint] TRUNCATE TABLE [dbo].[_BlockedWhisperers] TRUNCATE TABLE [dbo].[_TrainingCampMember] TRUNCATE TABLE [dbo].[_CharTrijobSafeTrade] DELETE FROM [dbo].[_CharTrijob] WHERE CharID > 0 TRUNCATE TABLE [dbo].[_TimedJob] TRUNCATE TABLE [dbo].[_StaticAvatar] TRUNCATE TABLE [dbo].[_Inventory] TRUNCATE TABLE [dbo].[_Memo] TRUNCATE TABLE [dbo].[_FleaMarketNetwork] TRUNCATE TABLE [dbo].[_Friend] TRUNCATE TABLE [dbo].[_CharSkillMastery] TRUNCATE TABLE [dbo].[_CharSkill] TRUNCATE TABLE [dbo].[_InvCOS] DELETE FROM [dbo].[_CharCOS] WHERE ID > 0 DELETE FROM [dbo].[_Char] WHERE CharID > 0 TRUNCATE TABLE [dbo].[_CharCollectionBook] TRUNCATE TABLE [dbo].[_CharInstanceWorldData] TRUNCATE TABLE [dbo].[_CharNameList] TRUNCATE TABLE [dbo].[_CharNickNameList] TRUNCATE TABLE [dbo].[_CharQuest] TRUNCATE TABLE [dbo].[_ClientConfig] TRUNCATE TABLE [dbo].[_DeletedChar] TRUNCATE TABLE [dbo].[_GPHistory] TRUNCATE TABLE [dbo].[_InventoryForLinkedStorage] TRUNCATE TABLE [dbo].[_ItemPool] DELETE FROM [dbo].[_Items] WHERE ID64 > 0 TRUNCATE TABLE [dbo].[_BindingOptionWithItem] TRUNCATE TABLE [dbo].[_Skill_BaoHiem_TNET] TRUNCATE TABLE [dbo].[_TimedJobForPet] TRUNCATE TABLE [dbo].[_Log_SEEK_N_DESTROY_ITEM_FAST] TRUNCATE TABLE [dbo].[_TrainingCampBuffStatus] TRUNCATE TABLE [dbo].[_TrainingCampHonorRank] INSERT INTO [dbo].[_TrainingCampHonorRank](Ranking) VALUES (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11),(12),(13),(14),(15),(16),(17),(18),(19),(20),(21),(22),(23),(24),(25),(26),(27),(28),(29),(30),(31),(32),(33),(34),(35),(36),(37),(38),(39),(40),(41),(42),(43),(44),(45),(46),(47),(48),(49),(50) EXEC [dbo].[_TRAINING_CAMP_UPDATEHONORRANK] DELETE FROM [dbo].[_TrainingCamp] TRUNCATE TABLE [dbo].[Tab_RefRanking_HunterContribution] TRUNCATE TABLE [dbo].[Tab_RefRanking_RobberContribution] TRUNCATE TABLE [dbo].[Tab_RefRanking_TraderContribution] TRUNCATE TABLE [dbo].[Tab_RefRanking_HunterActivity] TRUNCATE TABLE [dbo].[Tab_RefRanking_RobberActivity] TRUNCATE TABLE [dbo].[Tab_RefRanking_TraderActivity] TRUNCATE TABLE [dbo].[_TrijobRanking4WEB] UPDATE [dbo].[_TrijobRewards] SET [Reward] = 0 --TRUNCATE TABLE [dbo].[_BlackNameList] DBCC CHECKIDENT (_Guild, RESEED, 0) DBCC CHECKIDENT (_AlliedClans, RESEED, 0) DBCC CHECKIDENT (_Char, RESEED, 0) DBCC CHECKIDENT (_CharCOS, RESEED, 0) DBCC CHECKIDENT (_Items, RESEED, 0) DBCC CHECKIDENT (_TrainingCamp, RESEED, 0) USE [SRO_VT_LOG] GO TRUNCATE TABLE [dbo].[_LogCashItem] TRUNCATE TABLE [dbo].[_LogEventChar] TRUNCATE TABLE [dbo].[_LogEventItem] TRUNCATE TABLE [dbo].[_LogEventSiegeFortress] TRUNCATE TABLE [dbo].[_LogSchedule] TRUNCATE TABLE [dbo].[_LogServerEvent]