NotesWhat is notes.io?

Notes brand slogan

Notes - notes.io

USE [SRO_VT_SHARD]
GO
/****** Object: StoredProcedure [dbo].[_STRG_DEL_ITEM_NoTX] Script Date: 8.11.2021 02:38:45 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

ALTER procedure [dbo].[_STRG_DEL_ITEM_NoTX]
@DelFromPC_Inv AS TINYINT,
@CharID AS BIGINT, -- vsrodestek.com
@Slot AS TINYINT

as
declare @Rvalue int
declare @ItemToDel bigint

if (@DelFromPC_Inv = 1)
select @ItemToDel = ItemID FROM _Inventory WHERE CharID = @CharID AND Slot = @Slot
else if ( @DelFromPC_Inv = 2 )
select @ItemToDel = ItemID FROM _InventoryForLinkedStorage WHERE LinkedItemID = @CharID AND Slot = @Slot
else
select @ItemToDel = ItemID FROM _InvCOS WHERE COSID = @CharID AND Slot = @Slot

if (@ItemToDel IS NULL or @ItemToDel = 0)
return -1

declare @BoundCOS int
declare @RefItemID int
select @RefItemID = RefItemID, @BoundCOS = Data from _Items where ID64 = @ItemToDel
if (@@ROWCOUNT = 0)
return -2

declare @TypeID1 tinyint
declare @TypeID2 tinyint
declare @TypeID3 tinyint
select @TypeID1 = TypeID1, @TypeID2 = TypeID2, @TypeID3 = TypeID3 from _RefObjCommon where ID = @RefItemID
if (@TypeID1 = 3 and @TypeID2 = 2 and @TypeID3 = 1 )
begin

if (@BoundCOS <> 0)
begin
exec @Rvalue = _DeleteCharCOS_NoTX @BoundCOS
if (@Rvalue < 0)
return @Rvalue
end
end


else if( @TypeID1 = 3 and @TypeID2 = 2 and @TypeID3 = 3 )
begin

if (@BoundCOS <> 0)
begin
IF( NOT EXISTS( select LinkedItemID from _InventoryForLinkedStorage where LinkedItemID = @ItemToDel ) )
BEGIN return -1000 END
IF( EXISTS( select top 1 ItemID from _InventoryForLinkedStorage where LinkedItemID = @ItemToDel and ItemID <> 0 and ItemID IS NOT NULL ) )
BEGIN
update _ItemPool Set InUse = 0 from _ItemPool as IP join _InventoryForLinkedStorage as IFLS on IP.ItemID = IFLS.ItemID
where IFLS.LinkedItemID = @ItemToDel AND IFLS.ItemID <> 0
END
DELETE FROM _InventoryForLinkedStorage where LinkedItemID = @ItemToDel
IF( @@ERROR <> 0 )
BEGIN return -2 END
end
end


if (@DelFromPC_Inv = 1 )
update _Inventory SET ItemID = 0 WHERE CharID = @CharID AND Slot = @Slot
else if (@DelFromPC_Inv = 2 )
update _InventoryForLinkedStorage SET ItemID = 0 WHERE LinkedItemID = @CharID AND Slot = @Slot
else
update _InvCOS SET ItemID = 0 WHERE COSID = @CharID AND Slot = @Slot

if (@@error <> 0 OR @@rowcount = 0)
return -3

if exists (select 1 from _RentItemInfo with (nolock) where nItemDBID = @ItemToDel)
begin
delete from _RentItemInfo where nItemDBID = @ItemToDel
if (@@ERROR <> 0 OR @@ROWCOUNT = 0)
begin
rollback transaction
return -6
end
end

exec @Rvalue = _STRG_FREE_ITEM_NoTX @ItemToDel
if (@Rvalue < 0)
return -4

return 1







     
 
what is notes.io
 

Notes.io is a web-based application for taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000 notes created and continuing...

With notes.io;

  • * You can take a note from anywhere and any device with internet connection.
  • * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
  • * You can quickly share your contents without website, blog and e-mail.
  • * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
  • * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.

Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.

Easy: Notes.io doesn’t require installation. Just write and share note!

Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )

Free: Notes.io works for 12 years and has been free since the day it was started.


You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;


Email: [email protected]

Twitter: http://twitter.com/notesio

Instagram: http://instagram.com/notes.io

Facebook: http://facebook.com/notesio



Regards;
Notes.io Team

     
 
Shortened Note Link
 
 
Looding Image
 
     
 
Long File
 
 

For written notes was greater than 18KB Unable to shorten.

To be smaller than 18KB, please organize your notes, or sign in.