The following code yeilds zero results.
DECLARE @SEQNO Varbinary(100)
SET @SEQNO = (select CONVERT(VARBINARY,LAST_POSITION) FROM DI_CDCTest.dbo.AL_CDC_CHECKPOINT where CDC_TABLE = 'JDEGAACCOUNTBALANCES')
SELECT com.xact_seqno, tr.entry_time, com.partial_command, com.command
FROM MSrepl_transactions tr, MSrepl_commands com
WHERE com.publisher_database_id = 2
AND com.article_id = 10
AND com.xact_seqno = @SEQNO
ORDER BY com.xact_seqno, com.command_id
If I hard code @SEQNO with 0x0000272C0000111E0001 It works.
Why does a conversion from the varchar field of value 0000272C0000111E0001 return this 0x3030303032373243303030303131314530303031. ????
I have a varchar field that contains 0000272C0000111E0001 I need to compare this to xact_seqno in msrepl_commands. How can I do this? Any help is Much appreciated. Thanks