You will need to obtain the character ID for the character whose second mark icon you want to update. You can use the following query to get the character ID from the database.
SELECT CharID FROM _OnlinePlayers WHERE CharName16 = 'character_name'
Note: To assign a specific icon to a character, you must first add the icon entry (ID and file path) into the _RefCharMark table.
Stored Procedure: _Char_UpdateIcon2Live
Parameters:
@CharID INT- Target character ID@IconID INT- Icon ID
Let us first test whether the command works by using the following code, which will update the second mark icon to icon #1 from the _RefCharMark table for a specific character.
USE [vPlus] GO DECLARE @CharID INT = (SELECT CharID FROM _OnlinePlayers WHERE CharName16 = 'character_name') EXEC _Char_UpdateIcon2Live @CharID, 1;
For real usage, use @CharID directly from your calling procedure.
EXEC _Char_UpdateIcon2Live @CharID, 1;