<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>article Qlik Replicate: SQL Server Active/Backup presence state is kLSN_PRESENCE_NOWEHRE in Official Support Articles</title>
    <link>https://community.qlik.com/t5/Official-Support-Articles/Qlik-Replicate-SQL-Server-Active-Backup-presence-state-is-kLSN/ta-p/1902692</link>
    <description>&lt;DIV class="lia-message-template-content-zone"&gt;
&lt;P&gt;When using SQL Server source and you set SOURCE_CAPTURE to TRACE level and you see this type of message:&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp;[SOURCE_CAPTURE ]T: LSN 'xxxxxxxx:xxxxxxxx:0001' Active/Backup presence state is kLSN_PRESENCE_NOWEHRE (sqlserver_endpoint_capture.c:806)&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The LSN specified in the message was the last LSN that was read by Replicate. This message means that it was not in the online and not in any backup that was read and Qlik&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;Replicate will keep on searching for an LSN that doesn't exist.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;To verify that the LSN you are looking for is not waiting on the online log you can run:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;select top 10 * from ::fn_dblog('xxxxxxx:xxxxxxxx:0001, null)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; Please replace xxxxxxx:xxxxxxxx with a valid LSN&lt;BR /&gt;&lt;BR /&gt;If the LSN is in the backup you should get an error and if not, then that means the LSN has not reached the backup yet.&lt;BR /&gt;&lt;BR /&gt;To verify if the LSN is in the backup, run:&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;select
[dbo].[attrep_fn_NumericLsnToHexa](bs.first_lsn),
[dbo].[attrep_fn_NumericLsnToHexa](bs.last_lsn),
bmf.* , bs.*
from msdb.dbo.backupmediafamily bmf, msdb.dbo.backupset bs
where bmf.media_set_id = bs.media_set_id
and bs.database_name=db_name() and bs.type='L'
and cast([dbo].[attrep_fn_NumericLsnToHexa](bs.first_lsn) collate SQL_Latin1_General_CP1_CI_AS as varchar (24) ) &amp;lt;=cast( 'xxxxxxx:xxxxxxxx:0001' collate SQL_Latin1_General_CP1_CI_AS as varchar (24) )
and cast('xxxxxxx:xxxxxxxx:0001' collate SQL_Latin1_General_CP1_CI_AS as varchar (24) ) &amp;lt; cast( [dbo].[attrep_fn_NumericLsnToHexa](bs.last_lsn) collate SQL_Latin1_General_CP1_CI_AS as varchar (24) );&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;</description>
    <pubDate>Mon, 14 Mar 2022 14:40:13 GMT</pubDate>
    <dc:creator>lyka</dc:creator>
    <dc:date>2022-03-14T14:40:13Z</dc:date>
    <item>
      <title>Qlik Replicate: SQL Server Active/Backup presence state is kLSN_PRESENCE_NOWEHRE</title>
      <link>https://community.qlik.com/t5/Official-Support-Articles/Qlik-Replicate-SQL-Server-Active-Backup-presence-state-is-kLSN/ta-p/1902692</link>
      <description>&lt;DIV class="lia-message-template-content-zone"&gt;
&lt;P&gt;When using SQL Server source and you set SOURCE_CAPTURE to TRACE level and you see this type of message:&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp;[SOURCE_CAPTURE ]T: LSN 'xxxxxxxx:xxxxxxxx:0001' Active/Backup presence state is kLSN_PRESENCE_NOWEHRE (sqlserver_endpoint_capture.c:806)&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The LSN specified in the message was the last LSN that was read by Replicate. This message means that it was not in the online and not in any backup that was read and Qlik&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;Replicate will keep on searching for an LSN that doesn't exist.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;To verify that the LSN you are looking for is not waiting on the online log you can run:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;select top 10 * from ::fn_dblog('xxxxxxx:xxxxxxxx:0001, null)&lt;/LI-CODE&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; Please replace xxxxxxx:xxxxxxxx with a valid LSN&lt;BR /&gt;&lt;BR /&gt;If the LSN is in the backup you should get an error and if not, then that means the LSN has not reached the backup yet.&lt;BR /&gt;&lt;BR /&gt;To verify if the LSN is in the backup, run:&lt;/SPAN&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;select
[dbo].[attrep_fn_NumericLsnToHexa](bs.first_lsn),
[dbo].[attrep_fn_NumericLsnToHexa](bs.last_lsn),
bmf.* , bs.*
from msdb.dbo.backupmediafamily bmf, msdb.dbo.backupset bs
where bmf.media_set_id = bs.media_set_id
and bs.database_name=db_name() and bs.type='L'
and cast([dbo].[attrep_fn_NumericLsnToHexa](bs.first_lsn) collate SQL_Latin1_General_CP1_CI_AS as varchar (24) ) &amp;lt;=cast( 'xxxxxxx:xxxxxxxx:0001' collate SQL_Latin1_General_CP1_CI_AS as varchar (24) )
and cast('xxxxxxx:xxxxxxxx:0001' collate SQL_Latin1_General_CP1_CI_AS as varchar (24) ) &amp;lt; cast( [dbo].[attrep_fn_NumericLsnToHexa](bs.last_lsn) collate SQL_Latin1_General_CP1_CI_AS as varchar (24) );&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;</description>
      <pubDate>Mon, 14 Mar 2022 14:40:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Official-Support-Articles/Qlik-Replicate-SQL-Server-Active-Backup-presence-state-is-kLSN/ta-p/1902692</guid>
      <dc:creator>lyka</dc:creator>
      <dc:date>2022-03-14T14:40:13Z</dc:date>
    </item>
  </channel>
</rss>

