<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Stéphane Haby, auteur/autrice sur dbi Blog</title>
	<atom:link href="https://www.dbi-services.com/blog/author/stephane-haby/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.dbi-services.com/blog/author/stephane-haby/</link>
	<description></description>
	<lastBuildDate>Thu, 06 Aug 2026 13:10:26 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/05/cropped-favicon_512x512px-min-32x32.png</url>
	<title>Stéphane Haby, auteur/autrice sur dbi Blog</title>
	<link>https://www.dbi-services.com/blog/author/stephane-haby/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Green SQL Server DBA Tips #3 – The hidden cost of forgotten databases</title>
		<link>https://www.dbi-services.com/blog/green-sql-server-dba-tips-3-the-hidden-cost-of-forgotten-databases/</link>
					<comments>https://www.dbi-services.com/blog/green-sql-server-dba-tips-3-the-hidden-cost-of-forgotten-databases/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Thu, 06 Aug 2026 13:10:24 +0000</pubDate>
				<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=46270</guid>

					<description><![CDATA[<p>How many times have I found, during a migration, that I also have to clean up the databases no more used?Why keep them for so long if we’re not going to use them? This is something we often see among our customers. If we assume that we carry out a migration project roughly every five [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-3-the-hidden-cost-of-forgotten-databases/">Green SQL Server DBA Tips #3 – The hidden cost of forgotten databases</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">How many times have I found, during a migration, that I also have to clean up the databases no more used?<br>Why keep them for so long if we’re not going to use them?</p>



<p class="wp-block-paragraph">This is something we often see among our customers. If we assume that we carry out a migration project roughly every five years, this means we’re keeping databases that are taking up space for no reason.</p>



<p class="wp-block-paragraph">We, however, are Green SQL Server DBA; we’ll look to manage it correctly.</p>



<h2 id="h-the-audit" class="wp-block-heading">The AUDIT</h2>



<p class="wp-block-paragraph">First of all, what do we need to analyse?</p>



<p class="wp-block-paragraph">This does not apply to all databases, but only to those that are obsolete.</p>



<p class="wp-block-paragraph">They can be categorised into two types:</p>



<ul class="wp-block-list">
<li><strong>Databases Never Accessed</strong>
<ul class="wp-block-list">
<li>No application connections detected</li>



<li>No recent transactions or queries after a period (3 months for exemple)</li>
</ul>
</li>



<li><strong>Abandoned Databases</strong>
<ul class="wp-block-list">
<li>Linked to cancelled projects</li>



<li>No activity and nobody tell it</li>
</ul>
</li>
</ul>



<p class="wp-block-paragraph">To see databases never accessed and abandoned databases I use the DMV sys.dm_db_index_usage_stats to see if I have an access to the database (read or write):</p>



<pre class="wp-block-code"><code>SELECT d.name AS DatabaseName, MAX(ius.last_user_seek) AS LastSeek,MAX(ius.last_user_scan) AS LastScan,
    MAX(ius.last_user_lookup) AS LastLookup,

    (
        SELECT MAX(v.ActivityDate)
        FROM (VALUES
                (MAX(ius.last_user_seek)),
                (MAX(ius.last_user_scan)),
                (MAX(ius.last_user_lookup))
             ) v(ActivityDate)
    ) AS LastReadActivity,

    MAX(ius.last_user_update) AS LastWriteActivity,

    DATEDIFF(DAY,
        (
            SELECT MAX(v.ActivityDate)
            FROM (VALUES
                    (MAX(ius.last_user_seek)),
                    (MAX(ius.last_user_scan)),
                    (MAX(ius.last_user_lookup))
                 ) v(ActivityDate)
        ),
        GETDATE()
    ) AS DaysSinceLastRead,

    DATEDIFF(DAY,
        MAX(ius.last_user_update),
        GETDATE()
    ) AS DaysSinceLastWrite

FROM sys.databases d
LEFT JOIN sys.dm_db_index_usage_stats ius
    ON d.database_id = ius.database_id
WHERE d.database_id &gt; 4  -- Exclude system databases
GROUP BY d.name
ORDER BY LastWriteActivity ASC;
</code></pre>



<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1024" height="591" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/blog_green_dba_3_01-1024x591.png" alt="" class="wp-image-46272" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/blog_green_dba_3_01-1024x591.png 1024w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/blog_green_dba_3_01-300x173.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/blog_green_dba_3_01-768x443.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/blog_green_dba_3_01.png 1201w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p class="wp-block-paragraph">We can see on the first databases in the list, that we have null everywhere&#8230; This means that the databases were not solicited since the last restart&#8230; Good candidate for unused databases!</p>



<p class="wp-block-paragraph">This brings us to the next point.</p>



<h2 id="h-the-analisys" class="wp-block-heading">The ANALISYS</h2>



<p class="wp-block-paragraph">If we can see that there is little activity on the database, we can, of course, carry out an initial analysis using criteria such as these:</p>



<p class="wp-block-paragraph">&lt; 30 days &#8211;&gt; the database is still active</p>



<p class="wp-block-paragraph">30–180 days &#8211;&gt; the database is on hold pending to be dropped</p>



<p class="wp-block-paragraph">&gt; 180 days &#8211;&gt; the database is a strong candidate to be dropped</p>



<p class="wp-block-paragraph">Of course, it also depends on your environment – whether it’s dev, test or prod – and the criteria will vary accordingly.</p>



<h2 id="h-the-impact" class="wp-block-heading">The IMPACT</h2>



<p class="wp-block-paragraph">Like in my precedent post, we will have same impacts but not for queries of courses!</p>



<p class="wp-block-paragraph"><strong>The first impact is the storage and the backup</strong></p>



<p class="wp-block-paragraph">If the database represents ~100 GB on the disk , it’s also 100 GB backed up unnecessarily.</p>



<p class="wp-block-paragraph">If you have Dev, Test, PreProd &amp; Prod and all in HA… I let you do the calculation but it’s more 1 TB!</p>



<p class="wp-block-paragraph"><strong>The third impact is on the maintenance plan</strong></p>



<p class="wp-block-paragraph">The following operations must also handle the unused database:</p>



<p class="wp-block-paragraph">– CheckDB<br>– Backups<br><br>As the database is not used, the index rebuild/reorg &amp; update Stats will be fast!</p>



<p class="wp-block-paragraph">Each unused database extends the maintenance windows for the checkdb and backups…</p>



<h2 id="h-the-advise" class="wp-block-heading">The ADVISE</h2>



<p class="wp-block-paragraph">The first advice would be to plan well in advance.</p>



<p class="wp-block-paragraph">Indeed, when creating or restoring a database, it is important to know its lifecycle.</p>



<p class="wp-block-paragraph">Don’t hesitate to challenge the application owners on a deadline and make sure to add it to your calendar +1day.</p>



<p class="wp-block-paragraph">The second advice is to set up a monthly monitoring process prior to Windows or SQL Server patch cycles so that you can identify these unnecessary databases.</p>



<p class="wp-block-paragraph">And before dropping a database, I advice you to put the database offline and see if after some days somebody complaints&#8230;</p>



<p class="wp-block-paragraph">In the majority of cases, you will not have reactions, believe me! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<h2 id="h-the-green-sql-server-dba-score" class="wp-block-heading">The Green SQL Server DBA Score</h2>



<p class="wp-block-paragraph">Like for my precedent post, I setup a ‘SQL Server DBA Score’ to use for my tips on the subject:</p>



<figure class="wp-block-table"><table class="has-fixed-layout"><tbody><tr><td><strong><strong>Database unused per instance per 3 months</strong></strong></td><td><strong>Score</strong></td></tr><tr><td>0 to 2</td><td>10</td></tr><tr><td>3 to 5</td><td>8</td></tr><tr><td>6 to 10</td><td>5</td></tr><tr><td>11 to 20</td><td>2</td></tr><tr><td>&gt; 20</td><td>0</td></tr></tbody></table></figure>



<h2 id="h-conclusion" class="wp-block-heading">Conclusion</h2>



<p class="wp-block-paragraph">A traditional SQL Server DBA or system administrator will let the unused databases until the next migration.</p>



<p class="wp-block-paragraph">A Green SQL Server DBA will check it periodically and manage it.</p>



<p class="wp-block-paragraph">An unused database is like a car that never leaves the garage.<br> It still costs money, requires maintenance, and consumes resources.<br>The Green SQL Server DBA notices it before it becomes waste&#8230;</p>



<p class="wp-block-paragraph"><br>Think about it and begin now to see to monitor your unused databases!</p>



<p class="wp-block-paragraph">See you soon for the next one!&nbsp;</p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-3-the-hidden-cost-of-forgotten-databases/">Green SQL Server DBA Tips #3 – The hidden cost of forgotten databases</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/green-sql-server-dba-tips-3-the-hidden-cost-of-forgotten-databases/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server:  msdb is in Suspect State</title>
		<link>https://www.dbi-services.com/blog/sql-server-msdb-is-in-suspect-state/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-msdb-is-in-suspect-state/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Mon, 03 Aug 2026 10:00:17 +0000</pubDate>
				<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=46190</guid>

					<description><![CDATA[<p>This Monday morning, we begin our SLA Support with a customer call.He cannot do a select on a table in his database&#8230; After creating the Ticket, I connect to the instance and see that the msdb system database is in a Suspect State: After taking a deep breath because I don’t see that every day, [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-msdb-is-in-suspect-state/">SQL Server:  msdb is in Suspect State</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">This Monday morning, we begin our <a href="https://www.dbi-services.com/services/sla/">SLA Support</a> with a customer call.<br>He cannot do a select on a table in his database&#8230;</p>



<p class="wp-block-paragraph">After creating the Ticket, I connect to the instance and see that the msdb system database is in a Suspect State:</p>



<figure class="wp-block-image size-full"><img decoding="async" width="415" height="389" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect01.png" alt="" class="wp-image-46191" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect01.png 415w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect01-300x281.png 300w" sizes="(max-width: 415px) 100vw, 415px" /></figure>



<p class="wp-block-paragraph">After taking a deep breath because I don’t see that every day, I begin my investigation by asking the state with the system view sys.databases first:</p>



<figure class="wp-block-image size-full"><img decoding="async" width="623" height="531" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect02.png" alt="" class="wp-image-46192" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect02.png 623w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect02-300x256.png 300w" sizes="(max-width: 623px) 100vw, 623px" /></figure>



<p class="wp-block-paragraph">msdb is really in a suspect mode&#8230;</p>



<p class="wp-block-paragraph">Now, to begin the analysis, I go to read the error log.:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="646" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect03-1024x646.png" alt="" class="wp-image-46193" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect03-1024x646.png 1024w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect03-300x189.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect03-768x484.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect03.png 1169w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p class="wp-block-paragraph">The Error Log give me the error that I comments in SSMS query to read it better:</p>



<p class="wp-block-paragraph">Error: 3314, Severity: 21, State: 1.<br>During undoing of a logged operation in database &#8216;msdb&#8217;, an error occurred at log record ID (821931:128397:5).<br>Typically, the specific failure is logged previously as an error in the Windows Event Log service. Restore the database or file from a backup, or repair the database.</p>



<p class="wp-block-paragraph">If you have this error message, the best is to restore the msdb;<br>As the information of the backups is in the msdb, I cannot do a right-click to restore the database&#8230;  <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/2639.png" alt="☹" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph">I looked for the latest backup in the error log and find it:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="453" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect04-1024x453.png" alt="" class="wp-image-46194" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect04-1024x453.png 1024w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect04-300x133.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect04-768x340.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect04.png 1223w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p class="wp-block-paragraph">But I also sse that the checkdb before each backup give 12 errors&#8230;</p>



<p class="wp-block-paragraph">My question is at this point: Wasn’t there an alert saying that the database was corrupted?<br><br>As the users are blocked, I need to react quickly.<br>This is why, I do my restore and a CHECKDB with  REPAIR_ALLOW_DATA_LOSS:</p>



<pre class="wp-block-code"><code>RESTORE DATABASE msdb FROM DISK = 'xxx\msdb\msdb_fullbackup_xxxx20260801xxxx.BAK' WITH REPLACE;
GO
 ALTER DATABASE msdb SET SINGLE_USER WITH ROLLBACK IMMEDIATE;
GO
DBCC CHECKDB ('msdb', REPAIR_ALLOW_DATA_LOSS) WITH NO_INFOMSGS, ALL_ERRORMSGS;
GO
ALTER DATABASE msdb SET MULTI_USER;
</code></pre>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="562" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect05-1024x562.png" alt="" class="wp-image-46195" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect05-1024x562.png 1024w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect05-300x165.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect05-768x422.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect05.png 1067w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p class="wp-block-paragraph">The commands completed successfully! YES!</p>



<p class="wp-block-paragraph">The database msdb is online and working fine. SUPER!</p>



<p class="wp-block-paragraph">To be sure, I go in the errorlog to see the restore and the checkdb with REPAIR_ALLOW_DATA_LOSS:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="570" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect06-1024x570.png" alt="" class="wp-image-46196" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect06-1024x570.png 1024w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect06-300x167.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect06-768x428.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/08/Blog_msdb_suspect06.png 1508w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p class="wp-block-paragraph">The restore was successful and in the checkDB with can see 12 errors and repaired 12 errors.</p>



<p class="wp-block-paragraph">If I will investigate deeper, I will go the dump file and analyse it.</p>



<p class="wp-block-paragraph">I finally managed to sort out and resolve the critical alert on monday morning.<br>Users can connect and read their tables again&#8230;<br>The customer knows why he comes to us for an SLA&#8230; <br></p>



<p class="wp-block-paragraph">A good victory for a monday morning in our <a href="https://www.dbi-services.com/services/sla/">support SLA dbi-services</a>!<br>See you soon for sharing again customer cases! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-msdb-is-in-suspect-state/">SQL Server:  msdb is in Suspect State</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-msdb-is-in-suspect-state/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Green SQL Server DBA Tips #2 – When logs and history records cause your database to growth and crash</title>
		<link>https://www.dbi-services.com/blog/green-sql-server-dba-tips-2-when-logs-and-history-records-cause-your-database-to-growth-and-crash/</link>
					<comments>https://www.dbi-services.com/blog/green-sql-server-dba-tips-2-when-logs-and-history-records-cause-your-database-to-growth-and-crash/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Thu, 30 Jul 2026 06:30:38 +0000</pubDate>
				<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[Development & Performance]]></category>
		<category><![CDATA[Enterprise content management]]></category>
		<category><![CDATA[Non classifié(e)]]></category>
		<category><![CDATA[SQL Server]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=46040</guid>

					<description><![CDATA[<p>How often do I come across this sort of problem when visiting clients? Even more with our customers’ service desk (support) SLAs. We turn up on a Monday morning and there are alerts from the weekend saying [MSSQL] &#8211; Instance Dark_Vador-Data(F:): Disk space in GB on server Death_Star is critical Info: NOT OK &#8211; Free [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-2-when-logs-and-history-records-cause-your-database-to-growth-and-crash/">Green SQL Server DBA Tips #2 – When logs and history records cause your database to growth and crash</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">How often do I come across this sort of problem when visiting clients? Even more with our customers’ service desk (support) SLAs.</p>



<p class="wp-block-paragraph">We turn up on a Monday morning and there are alerts from the weekend saying</p>



<p class="wp-block-paragraph"><em>[MSSQL] &#8211; Instance Dark_Vador-Data(F:): Disk space in GB on server Death_Star is critical</em></p>



<p class="wp-block-paragraph"><em>Info: NOT OK &#8211; Free space: 20 MB out of 200 GB</em></p>



<p class="wp-block-paragraph">The storage is almost full and:<br> &#8211; no projects were deployed over the weekend<br> &#8211; no exceptional data loads were scheduled<br> &#8211; nobody works at the weekend</p>



<p class="wp-block-paragraph">A strange phenomenon to come across on a Monday morning&#8230;.</p>



<p class="wp-block-paragraph">On closer inspection, the findings are surprising; we can see that a database within the instance has been undergoing regular autogrowth for weeks&#8230;</p>



<p class="wp-block-paragraph">Every day, there are several regular autogrowth on the data file for this database until the saturation of the disk.</p>



<p class="wp-block-paragraph">Who is the culprit?</p>



<p class="wp-block-paragraph">Not the business data, but one or more tables named xxxxLog or Historyxxx, or the combination of both HistoryLog!</p>



<p class="wp-block-paragraph">PS: It’s an example but in the reality before the weekend, we will have Warnings and in the majority of the cases we react before the critical alert of course!</p>



<p class="wp-block-paragraph">Data created to diagnose a problem, track an activity or maintain a history, which is then never cleaned up or has a default retention period that is too long and unsuitable for the context, is not always easy to detect.</p>



<p class="wp-block-paragraph">On the other hand, it’s always easier to expand disk capacity without too much effort, and everything runs smoothly in an ideal world…</p>



<p class="wp-block-paragraph">We, however, are Green SQL Server DBA; we’ll look deeper.<br>Our curiosity will lead us to challenge the business on these points.</p>



<h2 id="h-the-audit" class="wp-block-heading">The AUDIT</h2>



<p class="wp-block-paragraph">First, you need to know the autogrowth settings for these databases and how the data file growth. <br>Here is a simple script that shows the settings:</p>



<pre class="wp-block-code"><code>SELECT
    DB_NAME(database_id) AS DatabaseName,
    name AS LogicalFileName,
    type_desc AS FileType,
    physical_name AS PhysicalFileName,
    size / 128.0 AS CurrentSizeMB,
    CASE
        WHEN is_percent_growth = 1
            THEN CAST(growth AS VARCHAR(10)) + ' %'
        ELSE CAST(growth / 128 AS VARCHAR(10)) + ' MB'
    END AS AutoGrowth,
    max_size,
    CASE
        WHEN max_size = -1 THEN 'Unlimited'
        ELSE CAST(max_size / 128 AS VARCHAR(20)) + ' MB'
    END AS MaxSize
FROM sys.master_files where type_desc='ROWS' AND database_id &gt; 4
ORDER BY
    DatabaseName,
    FileType,
    LogicalFileName;
</code></pre>



<p class="wp-block-paragraph">Like for my precedent blog “<strong><a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-1-are-unnecessary-indexes-cluttering-up-your-database/">Green SQL Server DBA Tips  #1 – Are unnecessary indexes cluttering up your database?</a></strong>”, I use the Dynamics database as example:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="892" height="556" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth01.png" alt="" class="wp-image-46041" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth01.png 892w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth01-300x187.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth01-768x479.png 768w" sizes="auto, (max-width: 892px) 100vw, 892px" /></figure>



<p class="wp-block-paragraph">In my script, I exclude all system databases and the Log File to be concentrated to the Data File.</p>



<p class="wp-block-paragraph">Now, I need to have the data file growth. This is through the default trace file and the event 92:</p>



<pre class="wp-block-code"><code>DECLARE @TraceFile NVARCHAR(500);

SELECT @TraceFile = path
FROM sys.traces
WHERE is_default = 1;

IF @TraceFile IS NULL
BEGIN
    RAISERROR('Default Trace is disabled.',16,1);
    RETURN;
END

;WITH GrowthEvents AS
(
    SELECT
        DB_NAME(DatabaseID) AS DatabaseName, FileName, CAST(StartTime AS DATE) AS GrowthDate,
        DATEPART(YEAR, StartTime) AS YearNum, DATEPART(WEEK, StartTime) AS WeekNum,
        DATEPART(MONTH, StartTime) AS MonthNum, IntegerData * 8.0 / 1024 AS GrowthMB
    FROM fn_trace_gettable(@TraceFile, DEFAULT)
    WHERE EventClass IN (92) -- 92 is data growth
)

SELECT DatabaseName,FileName,GrowthDate,COUNT(*) AS GrowthEvents,SUM(GrowthMB) AS TotalGrowthMB
FROM GrowthEvents GROUP BY DatabaseName,FileName,GrowthDate ORDER BY DatabaseName, GrowthDate
</code></pre>



<p class="wp-block-paragraph">As I don’t have any growth on the dynamicsBC database, I switch to the M-Files database for my example:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="723" height="685" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth02.png" alt="" class="wp-image-46042" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth02.png 723w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth02-300x284.png 300w" sizes="auto, (max-width: 723px) 100vw, 723px" /></figure>



<p class="wp-block-paragraph">We have here some daily growth&#8230;</p>



<p class="wp-block-paragraph">Go to see if we have historical or log tables in M-Files with this simple script who give us  the table and the row count and MB:</p>



<pre class="wp-block-code"><code>SELECT s.name AS Schema_Name,t.name AS Table_Name,
    SUM(p.rows) AS Row_Count, CAST(SUM(a.total_pages) * 8.0 / 1024 AS DECIMAL(18,2)) AS SizeMB
FROM sys.tables t INNER JOIN sys.schemas s     ON t.schema_id = s.schema_id
INNER JOIN sys.indexes i ON t.object_id = i.object_id
INNER JOIN sys.partitions p ON i.object_id = p.object_id  AND i.index_id = p.index_id
INNER JOIN sys.allocation_units a ON p.partition_id = a.container_id
WHERE t.name LIKE 'Histor%' OR t.name LIKE '%Log'
GROUP BY s.name, t.name ORDER BY SizeMB DESC;
</code></pre>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="714" height="291" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth03.png" alt="" class="wp-image-46043" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth03.png 714w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/autogrowth03-300x122.png 300w" sizes="auto, (max-width: 714px) 100vw, 714px" /></figure>



<h2 id="h-the-analisys" class="wp-block-heading">The ANALISYS</h2>



<p class="wp-block-paragraph">In my case, we can see that we have 383550 lignes (19.73Mb) on the table named OBJECTTYPECHANGELOG for a M-Files database.</p>



<p class="wp-block-paragraph">It’s only ~20MB here but in few months perhaps 20 GB or more&#8230;<br></p>



<p class="wp-block-paragraph">As a Green SQL Server DBA, I will contact the owner of M-Files project otherwise don&#8217;t forget that dbi services has also the expertise in ECM tools like M-Files.</p>



<h2 id="h-the-impact" class="wp-block-heading">The IMPACT</h2>



<p class="wp-block-paragraph">Like in my precedent post, we will have the same impacts</p>



<p class="wp-block-paragraph"><strong>The first impact is on DML INSERT operations.</strong></p>



<p class="wp-block-paragraph">With every insertion, the log or historical information is written to the table and update perhaps also index and at the end is never used by a query.</p>



<p class="wp-block-paragraph"><strong>The second impact is the storage and the backup</strong></p>



<p class="wp-block-paragraph">If the log table represents ~20 GB of the database.</p>



<p class="wp-block-paragraph">It’s 20 GB backed up unnecessarily, 20 GB restored unnecessarily and, above all, 20 GB stored unnecessarily and just for one environment.</p>



<p class="wp-block-paragraph">If you have Dev, Test, PreProd &amp; Prod and all in HA… I let you do the calculation but it’s more 100 GB!</p>



<p class="wp-block-paragraph"><strong>The third impact is on the maintenance plan</strong></p>



<p class="wp-block-paragraph">The following operations must also handle the log/historical tables:<br>– Rebuild Index<br>– Reorganise Index<br>– CheckDB<br>– Backups<br>– Restores</p>



<p class="wp-block-paragraph">Each growth of log/historical tables extends the maintenance windows…</p>



<h2 id="h-the-advise" class="wp-block-heading">The ADVISE</h2>



<p class="wp-block-paragraph">You really need to be careful before deleting anything in these table.</p>



<p class="wp-block-paragraph">Don’t Truncate the table because you see it!</p>



<p class="wp-block-paragraph">First see with the vendor if a purge or a retention parameter exists through the application.&nbsp;</p>



<p class="wp-block-paragraph">In my case with M-Files and the table OBJECTTYPECHANGELOG, in the administration interface, you can configure the retention. Go to challenge your M-Files team on it! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph">Finally, for every large log or historical table, you need to ask yourself the following questions:<br>– Who uses it?<br>– How often?<br>– Is there a legal obligation?<br>– What retention period is required?<br>– Can it be archived?<br>– Can it be purged?</p>



<h2 id="h-the-green-sql-server-dba-score" class="wp-block-heading">The Green SQL Server DBA Score</h2>



<p class="wp-block-paragraph">Like for my precedent post, I setup a ‘SQL Server DBA Score’ to use for my tips on the subject:</p>



<figure class="wp-block-table"><table class="has-fixed-layout"><tbody><tr><td><strong>Data growth per month</strong></td><td><strong>Score</strong></td></tr><tr><td>0 to 2</td><td>10</td></tr><tr><td>3 to 5</td><td>8</td></tr><tr><td>6 to 10</td><td>5</td></tr><tr><td>11 to 20</td><td>2</td></tr><tr><td>&gt; 20</td><td>0</td></tr></tbody></table></figure>



<h2 id="h-conclusion" class="wp-block-heading">Conclusion</h2>



<p class="wp-block-paragraph">A traditional SQL Server DBA or system administrator will see a data disk full and says:</p>



<p class="wp-block-paragraph"><strong>&#8220;How much GB need we to extend the disk?&#8221;</strong></p>



<p class="wp-block-paragraph">A Green SQL Server DBA sees a data disk full and says:</p>



<p class="wp-block-paragraph"><strong>&#8220;Why is my disk full and what can I do?&#8221;</strong></p>



<p class="wp-block-paragraph">Just like adding a larger trunk doesn&#8217;t make a car more efficient, adding more GB doesn&#8217;t make a database healthier.</p>



<p class="wp-block-paragraph">The greenest SQL Server DBA is not the one with the largest disks but it&#8217;s the one that keeps only data that continues to deliver value. <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f680.png" alt="🚀" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph">Think about it and begin now to see if you have cases!</p>



<p class="wp-block-paragraph">See you soon for the next one!&nbsp;</p>
<p>L’article <a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-2-when-logs-and-history-records-cause-your-database-to-growth-and-crash/">Green SQL Server DBA Tips #2 – When logs and history records cause your database to growth and crash</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/green-sql-server-dba-tips-2-when-logs-and-history-records-cause-your-database-to-growth-and-crash/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Green SQL Server DBA Tips  #1 – Are unnecessary indexes cluttering up your database?</title>
		<link>https://www.dbi-services.com/blog/green-sql-server-dba-tips-1-are-unnecessary-indexes-cluttering-up-your-database/</link>
					<comments>https://www.dbi-services.com/blog/green-sql-server-dba-tips-1-are-unnecessary-indexes-cluttering-up-your-database/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Tue, 21 Jul 2026 15:32:49 +0000</pubDate>
				<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[MS Teams]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Technology Survey]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=45650</guid>

					<description><![CDATA[<p>This summer I start a series of blog posts on the ‘green SQL Server DBA’, as it’s a topic that continues to interest me and one that hasn’t been covered very much so far. I hope you’ll enjoy my tips, starting with this one on unused indexes. When discussing SQL Server performance, we often hear [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-1-are-unnecessary-indexes-cluttering-up-your-database/">Green SQL Server DBA Tips  #1 – Are unnecessary indexes cluttering up your database?</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">This summer I start a series of blog posts on the ‘green SQL Server DBA’, as it’s a topic that continues to interest me and one that hasn’t been covered very much so far. I hope you’ll enjoy my tips, starting with this one on unused indexes.</p>



<p class="wp-block-paragraph">When discussing SQL Server performance, we often hear our performance tool say, ‘<em>An index is missing</em>’, but never ‘<em>There are too many indexes</em>’.</p>



<p class="wp-block-paragraph">However, in many databases, certain indexes are never used by business queries and they are maintained with every INSERT, UPDATE or DELETE operation.</p>



<p class="wp-block-paragraph">The question is really simple:</p>



<ul class="wp-block-list">
<li>How much does an unused index actually cost?</li>



<li>Why is an unused index a problem?</li>
</ul>



<p class="wp-block-paragraph">Every time there is a change to the data, SQL Server must also update all the relevant indexes, and that is not free.</p>



<p class="wp-block-paragraph">As an example, I’m going to use a widely recognised database: the famous DynamicsBC.</p>



<h2 id="h-the-audit" class="wp-block-heading">The AUDIT</h2>



<p class="wp-block-paragraph">The first step in any study is always to carry out an inventory to gather all the data required for the analysis. I need the size of the database, size of each data file, size of the data and size of the indexes</p>



<p class="wp-block-paragraph">I will use a query using the DMV: <a href="https://learn.microsoft.com/en-us/sql/relational-databases/system-dynamic-management-objects/sys-dm-db-partition-stats-transact-sql?view=sql-server-ver17" data-type="link" data-id="https://learn.microsoft.com/en-us/sql/relational-databases/system-dynamic-management-objects/sys-dm-db-partition-stats-transact-sql?view=sql-server-ver17">sys.dm_db_partition_stats</a></p>



<pre class="wp-block-code"><code>USE DynamicsBC;
GO

SELECT
DB_NAME() AS DatabaseName,
CAST(SUM(reserved_page_count) * 8.0 / 1024 AS DECIMAL(18,2)) AS TotalSizeMB,
CAST(SUM(used_page_count) * 8.0 / 1024 AS DECIMAL(18,2)) AS UsedSizeMB,
CAST((SUM(reserved_page_count) - SUM(used_page_count)) * 8.0 / 1024 AS DECIMAL(18,2)) AS FreeSizeMB,
CAST(SUM(
CASE
WHEN index_id &lt; 2 THEN in_row_data_page_count
+ lob_used_page_count
+ row_overflow_used_page_count
ELSE 0
END
) * 8.0 / 1024 AS DECIMAL(18,2)) AS DataSizeMB,
CAST(SUM(
CASE
WHEN index_id &gt;= 2 THEN used_page_count
ELSE 0
END
) * 8.0 / 1024 AS DECIMAL(18,2)) AS IndexSizeMB
FROM sys.dm_db_partition_stats;
GO
</code></pre>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="818" height="561" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-02.png" alt="" class="wp-image-45651" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-02.png 818w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-02-300x206.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-02-768x527.png 768w" sizes="auto, (max-width: 818px) 100vw, 818px" /></figure>



<p class="wp-block-paragraph">If we look at the ratio between the indexes and the data, we get:</p>



<p class="wp-block-paragraph">64966.91/92898.87 × 100 = ~70 %</p>



<p class="wp-block-paragraph">A ratio exceeding 50–60 % often requires an analysis of unused indexes, index overlap and compression.</p>



<p class="wp-block-paragraph"><strong>YES, we are good with this database! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></strong></p>



<p class="wp-block-paragraph">Now, let see if we have unused Indexes I use a script that I created years ago for DWH audit:</p>



<pre class="wp-block-code"><code>/******************************************************************************************/
--Summary
/******************************************************************************************/
USE &#091;master];

DECLARE @sqlcmd NVARCHAR(max);
DECLARE @ExcludeFlag BIT = 0;
DECLARE @IncludeDB VARCHAR(1000);
DECLARE @ExcludeDB VARCHAR(1000);


SET  @IncludeDB = 'DynamicsBC'

SELECT @ExcludeFlag = 0;
--SELECT @ExcludeDB = 'distribution,master,model,msdb,tempdb';
 

DECLARE @InDBList TABLE (indb SYSNAME);
DECLARE @ExDBList TABLE (exdb SYSNAME);
DECLARE @dbList TABLE (dbID INT NOT NULL PRIMARY KEY, dbName SYSNAME NOT NULL);


IF (@ExcludeFlag = 0)
BEGIN
	INSERT INTO @InDBList SELECT * FROM string_split(@IncludeDB,',');
	INSERT INTO @dbList (dbID, dbName) 
		SELECT d.database_id, d.name 
		FROM sys.databases d 
		WHERE d.name IN (SELECT indb FROM @InDBList);
END
ELSE
BEGIN
--	INSERT INTO @ExDBList SELECT * FROM string_split(@ExcludeDB,',');
	INSERT INTO @dbList (dbID, dbName) 
		SELECT d.database_id, d.name 
		FROM sys.databases d 
--		WHERE d.name NOT IN (SELECT exdb FROM @ExDBList);
--		WHERE d.name NOT IN ('distribution','master','model','msdb','tempdb');

END

/*********************************************************************
Creation of the result table variable to store the information
--*********************************************************************/

IF (SELECT OBJECT_ID('tempdb.dbo.#dbUnUsedIndex')) IS NOT NULL  
	DROP TABLE dbo.#dbUnUsedIndex
CREATE TABLE #dbUnUsedIndex (
	dbID INT NOT NULL,
	dbName SYSNAME NOT NULL,
	objName SYSNAME NULL,
	idxName SYSNAME NULL,
	idxID INT NULL,
	UserSeek BIGINT NULL,
	UserScans BIGINT NULL,
	UserLookups BIGINT NULL,
	UserUpdates BIGINT NULL,
	nbRows BIGINT NULL,
	dropStatement NVARCHAR(1000) NULL)

DECLARE @dbID INT;
DECLARE @dbName SYSNAME;
DECLARE cur_dblst CURSOR 
  LOCAL STATIC READ_ONLY FORWARD_ONLY
FOR 
SELECT dbID, dbName
FROM @dbList;

OPEN cur_dblst
FETCH NEXT FROM cur_dblst INTO @dbID, @dbName
WHILE @@FETCH_STATUS = 0
BEGIN 
    --Do something with Id here

	SELECT @sqlcmd = N'
		USE &#091;' + @dbName + ']'
		+ ' SELECT
			@dbID
			, @dbName			
			, o.name AS objName
			, i.name AS idxName
			, i.index_id AS idxID
			, dm_ius.user_seeks AS UserSeek
			, dm_ius.user_scans AS UserScans
			, dm_ius.user_lookups AS UserLookups
			, dm_ius.user_updates AS UserUpdates
			, p.TableRows AS nbRows
			, ''DROP INDEX '' + QUOTENAME(i.name)
			+ '' ON '' + QUOTENAME(s.name) + ''.''
			+ QUOTENAME(OBJECT_NAME(dm_ius.OBJECT_ID)) AS ''dropStatement''
		FROM sys.dm_db_index_usage_stats dm_ius
			INNER JOIN sys.indexes i ON i.index_id = dm_ius.index_id AND dm_ius.OBJECT_ID = i.OBJECT_ID
			INNER JOIN sys.objects o ON dm_ius.OBJECT_ID = o.OBJECT_ID
			INNER JOIN sys.schemas s ON o.schema_id = s.schema_id
			INNER JOIN (SELECT SUM(p.rows) TableRows, p.index_id, p.OBJECT_ID
			FROM sys.partitions p GROUP BY p.index_id, p.OBJECT_ID) p
			ON p.index_id = dm_ius.index_id AND dm_ius.OBJECT_ID = p.OBJECT_ID
		WHERE OBJECTPROPERTY(dm_ius.OBJECT_ID,''IsUserTable'') = 1
			AND dm_ius.database_id = DB_ID()
			AND i.type_desc = ''nonclustered''
			AND i.is_primary_key = 0
			AND i.is_unique_constraint = 0
		ORDER BY (dm_ius.user_seeks + dm_ius.user_scans + dm_ius.user_lookups) ASC; '

	INSERT INTO #dbUnUsedIndex (
					dbID,
					dbName,
					objName,
					idxName,
					idxID,
					UserSeek,
					UserScans,
					UserLookups,
					UserUpdates,
					nbRows,
					dropStatement)
	EXEC sp_executesql  @sqlCmd, N'@dbID INT, @dbName SYSNAME', @dbID, @dbName

    FETCH NEXT FROM cur_dblst INTO @dbID, @dbName
END
CLOSE cur_dblst
DEALLOCATE cur_dblst

SELECT Count(*) FROM #dbUnUsedIndex

SELECT * FROM #dbUnUsedIndex
ORDER BY dbName, objName


 IndexInfo;
GO
</code></pre>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="617" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-04-1024x617.png" alt="" class="wp-image-45655" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-04-1024x617.png 1024w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-04-300x181.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-04-768x463.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-04.png 1153w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p class="wp-block-paragraph">For the total number of Indexes, we use this simple query:</p>



<pre class="wp-block-code"><code>SELECT COUNT(*) AS TotalIndexes
FROM dynamicsBC.sys.indexes i
INNER JOIN sys.tables t
ON i.object_id = t.object_id
WHERE i.index_id &gt; 0;</code></pre>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="351" height="249" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-05.png" alt="" class="wp-image-45656" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-05.png 351w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2026/07/unused-index-05-300x213.png 300w" sizes="auto, (max-width: 351px) 100vw, 351px" /></figure>



<p class="wp-block-paragraph">We have 998 unused Index for a total of 19494 Index. This is 5% of the Indexes.<br>In this case, we will not win a lot. 5% is good but we can have a look because we never known&#8230;</p>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph"></p>



<h2 id="h-the-impact" class="wp-block-heading">The IMPACT</h2>



<p class="wp-block-paragraph"><strong>The first impact is on DML INSERT and UPDATE operations.</strong></p>



<p class="wp-block-paragraph">INSERT</p>



<p class="wp-block-paragraph">With every insertion, the data is written to the table and several index structures must also be updated, even when one of these indexes is never used by a query.</p>



<p class="wp-block-paragraph">So we have the following sequence:</p>



<p class="wp-block-paragraph">INSERT &#8211;&gt; write to the table &#8211;&gt; update index 1&nbsp; &#8211;&gt; update index 2&nbsp; &#8211;&gt; update index 3&nbsp; &#8211;&gt; update index 4 &#8230;.</p>



<p class="wp-block-paragraph">This is even more costly for this command because, for each operation, the sequence is as follows:</p>



<p class="wp-block-paragraph">UPDATE</p>



<p class="wp-block-paragraph">UPDATE &#8211;&gt; Delete the old index entry + Create the new entry for each index</p>



<p class="wp-block-paragraph">The result of all of this is more I/O, more CPU usage and also more entries in the Transaction Log</p>



<p class="wp-block-paragraph">On heavily used transactional tables, a few unused indexes can account for several per cent of additional load.</p>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph"><strong>The second impact is the storage and the backup</strong></p>



<p class="wp-block-paragraph">If the unused index represents ~100B of the database.</p>



<p class="wp-block-paragraph">If 100 GB of indexes are never used, that’s 100 GB backed up unnecessarily, 100 GB restored unnecessarily and, above all, 100 GB stored unnecessarily and just for one environment.</p>



<p class="wp-block-paragraph">If you have Dev, Test, PreProd &amp; Prod and all in HA&#8230; I let you do the calculation but it’s near 1 TB!</p>



<p class="wp-block-paragraph"><strong>The third impact is on the maintenance plan</strong></p>



<p class="wp-block-paragraph">The following operations must also handle unused indexes:<br>&#8211; Rebuild Index<br>&#8211; Reorganise Index<br>&#8211; CheckDB<br>&#8211; Backups<br>&#8211; Restores</p>



<p class="wp-block-paragraph">Each additional index extends the maintenance windows&#8230;</p>



<p class="wp-block-paragraph"></p>



<h2 id="h-the-advise" class="wp-block-heading">The ADVISE</h2>



<p class="wp-block-paragraph">You really need to be careful before deleting anything, as an unused index is not necessarily useless.</p>



<p class="wp-block-paragraph">You should check several factors before you delete unused indexes:<br> &#8211; Full business cycle<br> &#8211; End/Begin of month<br> &#8211; Annual processing<br> &#8211; Reporting<br> &#8211; ETL<br> &#8211; SQL Agent jobs</p>



<p class="wp-block-paragraph">I generally recommend observing the index between 1 and 3 months before deleting it and without restart. A restart will reset the DMV used for the stats&#8230; And always keep the script for recreating the index to hand!</p>



<p class="wp-block-paragraph"></p>



<h2 id="h-the-green-sql-server-dba-score" class="wp-block-heading">The Green SQL Server DBA Score</h2>



<p class="wp-block-paragraph">Just for fun, we’re going to set up a ‘SQL Server DBA Score’ to use for my tips on the subject:</p>



<figure class="wp-block-table"><table class="has-fixed-layout"><tbody><tr><td>Unused index rates (unused index/total index)</td><td>Score</td></tr><tr><td>&lt; 5%</td><td>10/10</td></tr><tr><td>5 to 10%</td><td>8/10</td></tr><tr><td>10 to 20 %</td><td>5/10</td></tr><tr><td>&gt; 20 %</td><td>2/10</td></tr></tbody></table></figure>



<p class="wp-block-paragraph"></p>



<h2 id="h-conclusion" class="wp-block-heading">Conclusion</h2>



<p class="wp-block-paragraph">An unused index is a bit like car that never gets driven:<br>it takes up space;it costs money;it requires maintenance;but it produces no value.</p>



<p class="wp-block-paragraph">The Green SQL Server DBA doesn’t just seek to add indexes.<br>They aim to retain only those that deliver measurable business value.</p>



<p class="wp-block-paragraph">See you soon for the next one!</p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/green-sql-server-dba-tips-1-are-unnecessary-indexes-cluttering-up-your-database/">Green SQL Server DBA Tips  #1 – Are unnecessary indexes cluttering up your database?</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/green-sql-server-dba-tips-1-are-unnecessary-indexes-cluttering-up-your-database/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server’s LinkedIn Posts catch-up!</title>
		<link>https://www.dbi-services.com/blog/sql-servers-linkedin-posts-catch-up/</link>
					<comments>https://www.dbi-services.com/blog/sql-servers-linkedin-posts-catch-up/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Thu, 30 Oct 2025 13:38:40 +0000</pubDate>
				<category><![CDATA[Azure]]></category>
		<category><![CDATA[Business Intelligence]]></category>
		<category><![CDATA[Cloud]]></category>
		<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[Development & Performance]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Technology Survey]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=41386</guid>

					<description><![CDATA[<p>You may not have followed all my posts this summer about what we are doing with Microsoft SQL Server technology and the BI stack like Power BI and Azure Data Fabric. So, I thought I&#8217;d write a little catch-up blog post, to help you to find all LinkedIn Posts! First, a bit of humour with [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-servers-linkedin-posts-catch-up/">SQL Server’s LinkedIn Posts catch-up!</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">You may not have followed all my posts this summer about what we are doing with Microsoft SQL Server technology and the BI stack like Power BI and Azure Data Fabric.</p>



<p class="wp-block-paragraph">So, I thought I&#8217;d write a little catch-up blog post, to help you to find all LinkedIn Posts!</p>



<p class="wp-block-paragraph">First, a bit of humour with this image of SQL Server scrolling through LinkedIn and wondering if anyone still loves it&#8230; Meanwhile, Power BI and Azure Data Fabric are stealing the show. </p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="602" height="903" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/Picture1.png" alt="" class="wp-image-41388" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/Picture1.png 602w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/Picture1-200x300.png 200w" sizes="auto, (max-width: 602px) 100vw, 602px" /></figure>



<p class="wp-block-paragraph">Let&#8217;s talk about SQL Server, and in particular all tests done on SQL Server 2025:  </p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_sql-server-2025-retirement-of-sql-server-activity-7343210645720317975-_eYk?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk">SSRS Deprecation – It’s time to rethink your reporting architecture</a></strong> explain you how with our Team, we can help you to go forward!</p>



<p class="wp-block-paragraph"><strong>d<a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_sqlserver2025-activity-7367160196273545221-mnBV?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk">bi services’ blog on fire for SQL Server 2025<img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f525.png" alt="🔥" class="wp-smiley" style="height: 1em; max-height: 1em;" /></a></strong> with this Tips to find all our SQL Server blogs : just Google: <strong>site:<a href="http://dbi-services.com/blog">dbi-services.com/blog</a> SQL Server 2025</strong></p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_sqlserver2025-alwayson-activity-7335937244957982720-RnZi?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f575-1f3fb.png" alt="🕵🏻" class="wp-smiley" style="height: 1em; max-height: 1em;" />Exploring SQL Server 2025 blogs</a></strong> with tests on SQL Server 2025 new features</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_microsoft-price-increase-for-on-premises-activity-7370734793887498240-7x9z?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk">Time to review your SQLServer licenses</a></strong> with 10% price increase for SQL Server licences, we can help you to optimize your SQL Server Architecture!</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_dbi-blog-activity-7361055722178023425-RxJO?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk">SQL Server 2025: AI, Performance… and real-world Lessons</a></strong> with a lot of deep tests and new thinking about  Tuning, Performance &amp; AI</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_sql-server-security-updates-activity-7379426832149954560-Jp0P?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/26a0.png" alt="⚠" class="wp-smiley" style="height: 1em; max-height: 1em;" /> Your SQL Server might be exposed right now</a></strong> is a very important topic because Microsoft put in Augaust and Septembre critical patches in High importance</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_sqlserver2025-activity-7343974921234001920-UtLO?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk">SQL Server 2025 – What’s new &amp; What’s next?</a></strong> withgood feedback and ideas from SQLBits 2025  in London</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_sqlserver2025-microsoftfabric-ai-activity-7363084169750478848-WnMp?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk">It&#8217;s time to rethink your data strategy with SQL Server 2025 <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f914.png" alt="🤔" class="wp-smiley" style="height: 1em; max-height: 1em;" /></a></strong>with the end of DQS, MDS and Synapse Link, it’s  the opportunity to see our expertise in Microsoft Fabic </p>



<p class="wp-block-paragraph">And also, publications about how we can help beside SQL Server and share these experiences &amp; expertise:</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_azure-powerbi-datafabric-activity-7375849857544130560-Az-_?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f4a1.png" alt="💡" class="wp-smiley" style="height: 1em; max-height: 1em;" /> Struggling with rising Azure Data Fabric &amp; Power BI costs?</a></strong> with our experience to help to optimize the cost of your Azure Platform using the BI stack</p>



<p class="wp-block-paragraph"><strong><a href="https://www.linkedin.com/posts/st%C3%A9phane-haby-4481b633_mfiles-sqlserver-activity-7359190630989713409-GFHU?utm_source=social_share_send&amp;utm_medium=member_desktop_web&amp;rcm=ACoAAAb4YfgBKm8-2tQBY5Bec74LclUAp9YYckk"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f4a1.png" alt="💡" class="wp-smiley" style="height: 1em; max-height: 1em;" /> When M-Files meets SQL Server</a></strong> with our SQL Server &amp; M-Files expertise, we are on the top to help you to configure, customize, optimize, secure  your M-File infrastructure</p>



<p class="wp-block-paragraph">Continue to follow us in our blogs and linkedIn posts!</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-servers-linkedin-posts-catch-up/">SQL Server’s LinkedIn Posts catch-up!</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-servers-linkedin-posts-catch-up/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server: Do you know how to use SERVERPROPERTY()  function in a useful way?</title>
		<link>https://www.dbi-services.com/blog/sql-server-do-you-know-how-to-use-serverproperty-function-in-a-useful-way/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-do-you-know-how-to-use-serverproperty-function-in-a-useful-way/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Wed, 22 Oct 2025 09:04:11 +0000</pubDate>
				<category><![CDATA[Azure]]></category>
		<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=41130</guid>

					<description><![CDATA[<p>The SERVERPROPERTY() function is so nice to use to have information about the instance and server very quickly. Sometimes it’s good to come back to basis&#8230; How to begin? Read the documentation of course here but you will see a lot of informations&#8230; After reading the documentation, how to have the first useful information? The [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-do-you-know-how-to-use-serverproperty-function-in-a-useful-way/">SQL Server: Do you know how to use SERVERPROPERTY()  function in a useful way?</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">The SERVERPROPERTY() function is so nice to use to have information about the instance and server very quickly. Sometimes it’s good to come back to basis&#8230;</p>



<p class="wp-block-paragraph">How to begin? Read the documentation of course <a href="https://learn.microsoft.com/en-us/sql/t-sql/functions/serverproperty-transact-sql?view=sql-server-ver17">here</a> but you will see a lot of informations&#8230;</p>



<p class="wp-block-paragraph">After reading the documentation, how to have the first useful information?</p>



<p class="wp-block-paragraph">The first information will be about the <strong>SQL Server installed</strong> like the server name, instance name, build and version with also some advanced information like last update date, the KB or CU.</p>



<p class="wp-block-paragraph">Here this first query:</p>



<pre class="wp-block-code"><code>SELECT  
  SERVERPROPERTY('MachineName') AS &#091;Server_Name],
  SERVERPROPERTY('InstanceName') AS &#091;Instance_Name], 
  SERVERPROPERTY('Edition') AS &#091;Edition],
  SERVERPROPERTY('ProductVersion') AS &#091;Product_Version], 
  SERVERPROPERTY('ProductLevel') AS &#091;Product _Level],
  SERVERPROPERTY('ProductBuild') AS &#091;Product _Build],
   SERVERPROPERTY('ProductMajorVersion') AS &#091;Advanced_Product_ Major_Version],
  SERVERPROPERTY('ProductMinorVersion') AS &#091;Advanced_Product_Minor_Version],
   SERVERPROPERTY('ProductUpdateReference ') AS &#091;Advanced_KB_Version],
  SERVERPROPERTY('ProductUpdateLevel') AS &#091;Advanced_Update _Level],
  SERVERPROPERTY(' ResourceLastUpdateDateTime ') AS &#091;Advanced_Last_Update_Date]
</code></pre>



<p class="wp-block-paragraph">Result of a test:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="263" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-8.png" alt="" class="wp-image-41131" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-8.png 940w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-8-300x84.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-8-768x215.png 768w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p class="wp-block-paragraph">I run all queries on my sql server container under Visual Studio Code and sql server 2025 CPT2.1.</p>



<p class="wp-block-paragraph">You can have more info about it here (<a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-without-docker-command/">dbi Blog</a>)</p>



<p class="wp-block-paragraph">After, some other useful information will be if the instance has <strong>features installed</strong> like Polybase or Full-Text seach but also some <strong>configuration</strong> like filestream or HA.</p>



<p class="wp-block-paragraph">&nbsp;Here the query:</p>



<pre class="wp-block-code"><code>SELECT 
  SERVERPROPERTY('MachineName') AS &#091;Server_Name],
  SERVERPROPERTY('InstanceName') AS &#091;Instance_Name], 
  SERVERPROPERTY('IsPolyBaseInstalled') AS &#091;Is_Polybase_Installed],  
  SERVERPROPERTY('IsFullTextInstalled') AS &#091;Is_Full-Text_Search_Installed],
  SERVERPROPERTY('IsAdvancedAnalyticsInstalled') AS &#091;Is_Advanced_Analytics_Installed],
  SERVERPROPERTY('FilestreamConfiguredLevel') AS &#091;is_Filestream_enabled],  
  SERVERPROPERTY('IsBigDataCluster') AS &#091;Is_BigData_Cluster_enabled],
  SERVERPROPERTY('IsClustered') AS &#091;Is_Clustered],  
  SERVERPROPERTY('IsHadrEnabled') AS &#091;Is_HADR_enabled],
   SERVERPROPERTY('IsTempDbMetadataMemoryOptimized') AS &#091;Is_TempDB_for_Memory_Optimized_Tables_Enabled],  
  SERVERPROPERTY('IsXTPSupported') AS &#091;Is_IN_Memory_OLTP_Supported],
  SERVERPROPERTY('IsExternalGovernanceEnabled') AS &#091;Is_External_Governance_Enabled];
</code></pre>



<p class="wp-block-paragraph">Result of a test:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="242" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-9.png" alt="" class="wp-image-41132" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-9.png 940w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-9-300x77.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-9-768x198.png 768w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p class="wp-block-paragraph">You can notice that the last property is the External governance. This is linked to the &nbsp;<a href="https://learn.microsoft.com/en-us/azure/purview/how-to-policies-data-owner-arc-sql-server">Microsoft Purview access policies</a>. &nbsp;</p>



<p class="wp-block-paragraph">The next useful information will be about the <strong>security</strong>.</p>



<p class="wp-block-paragraph">Here the query:</p>



<pre class="wp-block-code"><code>SELECT 
  SERVERPROPERTY('MachineName') AS &#091;Server_Name],
  SERVERPROPERTY('InstanceName') AS &#091;Instance_Name], 
  SERVERPROPERTY('IsIntegratedSecurityOnly') AS &#091;Is_Integrated_Security_Only],
  SERVERPROPERTY('IsSingleUser') AS &#091;Is_Single_User],
  SERVERPROPERTY('IsExternalAuthenticationOnly') AS &#091;s_External_Authentication_Only];
</code></pre>



<p class="wp-block-paragraph">Result of a test:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="354" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-10.png" alt="" class="wp-image-41133" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-10.png 940w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-10-300x113.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-10-768x289.png 768w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p class="wp-block-paragraph">The External Authentication concerns the <a href="https://learn.microsoft.com/en-us/azure/azure-sql/database/authentication-azure-ad-only-authentication">Microsoft Entra-only authentication</a>  for Azure SQL Database &amp; Azure SQL Managed Instance. </p>



<p class="wp-block-paragraph">The last information package is the <strong>collation/character set</strong> with this query:</p>



<pre class="wp-block-code"><code>SELECT 
  SERVERPROPERTY('MachineName') AS &#091;Server_Name],
  SERVERPROPERTY('InstanceName') AS &#091;Instance_Name], 
  SERVERPROPERTY('Collation') AS &#091;Collation], 
  SERVERPROPERTY('LCID') AS &#091;Windows_Locale_Identifier], 
  SERVERPROPERTY('SqlCharSetName') AS &#091;SQL_Character_Set_Name], 
  SERVERPROPERTY('SqlSortOrderName') AS &#091;SQL_Sort_Order_Name];
</code></pre>



<p class="wp-block-paragraph">Result of a test:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="602" height="191" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-11.png" alt="" class="wp-image-41134" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-11.png 602w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/10/image-11-300x95.png 300w" sizes="auto, (max-width: 602px) 100vw, 602px" /></figure>



<p class="wp-block-paragraph">To conclude, you have now in this blog <strong>4 useful queries to find information on the server level</strong>.<br>Don’t hesitate to add your comments or give me other useful property that you use.!</p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-do-you-know-how-to-use-serverproperty-function-in-a-useful-way/">SQL Server: Do you know how to use SERVERPROPERTY()  function in a useful way?</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-do-you-know-how-to-use-serverproperty-function-in-a-useful-way/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server: New SQL Server Management Studio (SSMS)  landing page</title>
		<link>https://www.dbi-services.com/blog/sql-server-new-sql-server-management-studio-ssms-landing-page/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-new-sql-server-management-studio-ssms-landing-page/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Tue, 01 Jul 2025 06:37:45 +0000</pubDate>
				<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[Database management]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Technology Survey]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=39355</guid>

					<description><![CDATA[<p>After the new connectivity and drivers landing page for SQL Server with .Net, Java, Python, C++, Go and PHP languages, you have a new landing page for SQL Server Management Studio (SSMS) : https://learn.microsoft.com/en-us/ssms You will see 6 parts in the main panel: If you have a look on the left menu, you will find [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-new-sql-server-management-studio-ssms-landing-page/">SQL Server: New SQL Server Management Studio (SSMS)  landing page</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">After the new <a href="https://www.dbi-services.com/blog/sql-server-new-connectivity-and-drivers-landing-page/">connectivity and drivers landing page for SQL Server with .Net, Java, Python, C++, Go and PHP languages</a>, you have a new landing page for <strong>SQL Server Management Studio (SSMS)</strong> :</p>



<p class="wp-block-paragraph"><a href="https://learn.microsoft.com/en-us/ssms">https://learn.microsoft.com/en-us/ssms</a></p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="456" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image.png" alt="" class="wp-image-39356" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image.png 940w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-300x146.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-768x373.png 768w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p class="wp-block-paragraph">You will see 6 parts in the main panel:</p>



<ul class="wp-block-list">
<li>Overview</li>



<li>Get Started</li>



<li>Install</li>



<li>Customize SSMS</li>



<li>What’s new in SSMS?</li>



<li>Troubleshoot</li>
</ul>



<p class="wp-block-paragraph">If you have a look on the left menu, you will find more like <strong>Copilot in SQL Server Management Studio (Preview) </strong>and have a deep dive into this subject:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="938" height="648" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-1.png" alt="" class="wp-image-39357" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-1.png 938w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-1-300x207.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-1-768x531.png 768w" sizes="auto, (max-width: 938px) 100vw, 938px" /></figure>



<p class="wp-block-paragraph">To follow how to enable and use it, follow the blog of <strong><a href="https://www.dbi-services.com/blog/author/stevennaudet/">Steven Naudet</a></strong>: <strong><a href="https://www.dbi-services.com/blog/step-by-step-guide-to-enabling-copilot-in-ssms/">Step-by-Step Guide to Enabling Copilot in SSMS</a></strong></p>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph">One part I like in the documentation is the “<strong>Tips and Tricks</strong>” in “<strong>Get Started</strong>” to be more efficient when you use it:</p>



<p class="wp-block-paragraph"><a href="https://learn.microsoft.com/en-us/ssms/tutorials/ssms-tricks">https://learn.microsoft.com/en-us/ssms/tutorials/ssms-tricks</a></p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="467" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-2.png" alt="" class="wp-image-39358" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-2.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-2-300x149.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/07/image-2-768x382.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph"><strong><em>Have a good start with the new landing page of SSMS!</em></strong></p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-new-sql-server-management-studio-ssms-landing-page/">SQL Server: New SQL Server Management Studio (SSMS)  landing page</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-new-sql-server-management-studio-ssms-landing-page/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server 2025: Local SQL Server Container – Schema design preview</title>
		<link>https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-design-preview/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-design-preview/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Wed, 25 Jun 2025 12:52:26 +0000</pubDate>
				<category><![CDATA[Development & Performance]]></category>
		<category><![CDATA[Docker]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Technology Survey]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=39320</guid>

					<description><![CDATA[<p>After my blogs about “SQL Server 2025: Local SQL Server Container without Docker Command” and “SQL Server 2025: Local SQL Server Container – Schema compare preview”, I continue to play &#38; test it. One new feature in preview is the “Schema Design compare” in this last MSSQL extension for Visual Studio Code: Let’s start and [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-design-preview/">SQL Server 2025: Local SQL Server Container – Schema design preview</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">After my blogs about “<a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-without-docker-command/"><strong>SQL Server 2025: Local SQL Server Container without Docker Command</strong></a>” and “<a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-compare-preview/"><strong>SQL Server 2025: Local SQL Server Container – Schema compare preview</strong></a>”, I continue to play &amp; test it.</p>



<p class="wp-block-paragraph">One new feature in preview is the “<strong>Schema Design compare</strong>” in this last<a href="https://code.visualstudio.com/download"> MSSQL extension for Visual Studio Code</a>:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="605" height="873" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-88.png" alt="" class="wp-image-39321" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-88.png 605w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-88-208x300.png 208w" sizes="auto, (max-width: 605px) 100vw, 605px" /></figure>



<p class="wp-block-paragraph">Let’s start and see on a database (db2 in my example):</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="938" height="425" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-89.png" alt="" class="wp-image-39322" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-89.png 938w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-89-300x136.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-89-768x348.png 768w" sizes="auto, (max-width: 938px) 100vw, 938px" /></figure>



<p class="wp-block-paragraph">Et voila, I have my 2 tables created during the test on Schema Compare blog here</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="503" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-90.png" alt="" class="wp-image-39323" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-90.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-90-300x161.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-90-768x411.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">Now, I create a new table t3 with some columns:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="386" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-91.png" alt="" class="wp-image-39324" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-91.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-91-300x123.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-91-768x316.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">Very easy to create a table without being a SQL Expert.</p>



<p class="wp-block-paragraph">As you can see, you have easily access to the option and add some specific input like the size or a default value.</p>



<p class="wp-block-paragraph">The table t3 is created with a primary key on column c1.</p>



<p class="wp-block-paragraph">Now, I change my table t2 and want to put c1 as primary key.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="426" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-92.png" alt="" class="wp-image-39325" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-92.png 940w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-92-300x136.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-92-768x348.png 768w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p class="wp-block-paragraph">To edit the table t2, just click on the pen:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="633" height="364" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-93.png" alt="" class="wp-image-39326" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-93.png 633w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-93-300x173.png 300w" sizes="auto, (max-width: 633px) 100vw, 633px" /></figure>



<p class="wp-block-paragraph">In the edit table, I just check the column c1 as primary key:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="419" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-94.png" alt="" class="wp-image-39327" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-94.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-94-300x134.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-94-768x343.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">And I have my primary key on table t2:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="938" height="517" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-95.png" alt="" class="wp-image-39328" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-95.png 938w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-95-300x165.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-95-768x423.png 768w" sizes="auto, (max-width: 938px) 100vw, 938px" /></figure>



<p class="wp-block-paragraph">Now, I want do link between my 3 tables (this is named/known as a Foreign Key&#8230;)</p>



<p class="wp-block-paragraph">First between t2 and t3, I go the side of the table t2 and a blue point appears. Take it and go to the table t3</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="670" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-96.png" alt="" class="wp-image-39329" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-96.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-96-300x214.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-96-768x548.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="655" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-97.png" alt="" class="wp-image-39330" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-97.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-97-300x209.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-97-768x536.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">Let’s try between the table t2 and the table t1</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="423" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-98.png" alt="" class="wp-image-39331" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-98.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-98-300x135.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-98-768x346.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">Aie! Error message:</p>



<ul class="wp-block-list">
<li><strong><em>Failed to create a foreign key</em></strong></li>



<li><strong><em>Column ‘c1’ must be a primary key</em></strong></li>
</ul>



<p class="wp-block-paragraph">It’s very good to have this control and information.</p>



<p class="wp-block-paragraph">This will help a lot of developers&#8230;</p>



<p class="wp-block-paragraph">I will not continue more with the design.<br>It’s already and really a good tool to design our schema.</p>



<p class="wp-block-paragraph">One good point is the <strong>export button</strong> to have the schema design as a picture with 3 formats possibilities svg ,png or jpeg.</p>



<p class="wp-block-paragraph">No excuse to not do a documentation! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="508" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-99.png" alt="" class="wp-image-39332" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-99.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-99-300x162.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-99-768x415.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">The <strong>definition button </strong>gives you the design script:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="732" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-100.png" alt="" class="wp-image-39333" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-100.png 940w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-100-300x234.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-100-768x598.png 768w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p class="wp-block-paragraph">The last button to use is the <strong>Publish Changes</strong>:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="938" height="523" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-101.png" alt="" class="wp-image-39334" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-101.png 938w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-101-300x167.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-101-768x428.png 768w" sizes="auto, (max-width: 938px) 100vw, 938px" /></figure>



<p class="wp-block-paragraph">I wait a little bit, and I have the resume of the design change:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="559" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-102.png" alt="" class="wp-image-39335" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-102.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-102-300x179.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-102-768x457.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I like the checkbox “I have read the summary and understand the potential risks” and I publish.</p>



<p class="wp-block-paragraph"></p>



<p class="wp-block-paragraph">It’s just a discovery about the Schema design preview.</p>



<p class="wp-block-paragraph">It will be a good help for developers.</p>



<p class="wp-block-paragraph">See you soon for the next episode! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-design-preview/">SQL Server 2025: Local SQL Server Container – Schema design preview</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-design-preview/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server 2025: Local SQL Server Container &#8211; Schema compare preview</title>
		<link>https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-compare-preview/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-compare-preview/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Tue, 24 Jun 2025 15:37:40 +0000</pubDate>
				<category><![CDATA[Development & Performance]]></category>
		<category><![CDATA[Docker]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Technology Survey]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=39301</guid>

					<description><![CDATA[<p>After my blog about “SQL Server 2025: Local SQL Server Container without Docker Command”, I continue to play &#38; test it. One new feature in preview is the “schema compare” in this last extension for Visual Code: I like new feature and now let’s go for a test! 😉 I create 2 identically databases db1 [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-compare-preview/">SQL Server 2025: Local SQL Server Container &#8211; Schema compare preview</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">After my blog about “<a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-without-docker-command/">SQL Server 2025: Local SQL Server Container without Docker Command</a>”, I continue to play &amp; test it.</p>



<p class="wp-block-paragraph">One new feature in preview is the “<strong>schema compare</strong>” in this last extension for Visual Code:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="464" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-73.png" alt="" class="wp-image-39302" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-73.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-73-300x148.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-73-768x380.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I like new feature and now let’s go for a test! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph">I create 2 identically databases db1 &amp; db2 with 2 tables and some data inside:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="934" height="1024" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-74-934x1024.png" alt="" class="wp-image-39303" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-74-934x1024.png 934w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-74-273x300.png 273w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-74-768x842.png 768w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-74.png 939w" sizes="auto, (max-width: 934px) 100vw, 934px" /></figure>



<p class="wp-block-paragraph">I do a select on both tables on both databases to see if everything is the same:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="636" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-75.png" alt="" class="wp-image-39304" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-75.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-75-300x203.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-75-768x520.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I run the “<strong>schema compare</strong>” to be sure I have everything is aligned:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="495" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-76.png" alt="" class="wp-image-39305" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-76.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-76-300x158.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-76-768x405.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I select the source “db1”, select the target “db2” and click on compare:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="472" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-77.png" alt="" class="wp-image-39306" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-77.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-77-300x151.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-77-768x386.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="363" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-78.png" alt="" class="wp-image-39307" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-78.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-78-300x116.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-78-768x297.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="306" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-79.png" alt="" class="wp-image-39308" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-79.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-79-300x98.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-79-768x250.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">After few seconds (due to my small databases), we have the result:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="241" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-80.png" alt="" class="wp-image-39309" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-80.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-80-300x77.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-80-768x197.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">Good! No schema differences were found! It&#8217;s a good start&#8230;</p>



<p class="wp-block-paragraph">Now, I play and change a little bit the db1:</p>



<ul class="wp-block-list">
<li>On table t1:
<ul class="wp-block-list">
<li>Add a column c4</li>



<li>Drop a column c1</li>



<li>Change the data type of the column c2</li>
</ul>
</li>
</ul>



<ul class="wp-block-list"></ul>



<ul class="wp-block-list">
<li>Create a new schema test2</li>
</ul>



<ul class="wp-block-list">
<li>Transfer the table t2 from schema dbo to scema test2</li>
</ul>



<ul class="wp-block-list">
<li>Create a new table t3</li>
</ul>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="605" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-81.png" alt="" class="wp-image-39310" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-81.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-81-300x193.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-81-768x495.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I run again the schema compare&#8230;</p>



<p class="wp-block-paragraph">This time, we have a result:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="330" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-82.png" alt="" class="wp-image-39311" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-82.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-82-300x105.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-82-768x270.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I have all my change but like other tools it will delete the table dbo.t2 and create a new one test2.t2. This is not really the same as a schema transfer&#8230;</p>



<p class="wp-block-paragraph">Otherwise, we see the missing table dbo.t2</p>



<p class="wp-block-paragraph">I will now run the compare in the other way db2 as source and db1 as target:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="213" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-83.png" alt="" class="wp-image-39312" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-83.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-83-300x68.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-83-768x174.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I see now the delete of what I change on db1, then it’s good and fine except the schema transfer like usual&#8230;</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="448" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-84.png" alt="" class="wp-image-39313" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-84.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-84-300x143.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-84-768x366.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I come back to my precedent comparison and this I use the “<strong>Switch Direction</strong>”:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="416" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-85.png" alt="" class="wp-image-39314" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-85.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-85-300x133.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-85-768x340.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">I test now the <strong>script generation</strong>:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="938" height="484" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-86.png" alt="" class="wp-image-39315" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-86.png 938w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-86-300x155.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-86-768x396.png 768w" sizes="auto, (max-width: 938px) 100vw, 938px" /></figure>



<p class="wp-block-paragraph">Et voila, I have my change script:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="581" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-87.png" alt="" class="wp-image-39316" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-87.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-87-300x186.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-87-768x475.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">It will be very nice to use for developers but as you see in my post, you need to be careful with your change (schema change for tables), control and test the script generated before do it on Production databases!</p>



<p class="wp-block-paragraph">See you soon for the next test on my Local SQL Server Container! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-compare-preview/">SQL Server 2025: Local SQL Server Container &#8211; Schema compare preview</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-2025-local-sql-server-container-schema-compare-preview/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SQL Server: New connectivity and Drivers landing page</title>
		<link>https://www.dbi-services.com/blog/sql-server-new-connectivity-and-drivers-landing-page/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-new-connectivity-and-drivers-landing-page/#respond</comments>
		
		<dc:creator><![CDATA[Stéphane Haby]]></dc:creator>
		<pubDate>Mon, 23 Jun 2025 14:57:16 +0000</pubDate>
				<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Technology Survey]]></category>
		<category><![CDATA[Microsoft]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/?p=39280</guid>

					<description><![CDATA[<p>You will find a new connectivity and drivers landing page for SQL Server with .Net, Java, Python, C++, Go and PHP languages: SQL Connectivity and Drivers &#8211; SQL Server &#124; Microsoft Learn As you can see, you can download, have a quick start and some code samples… Let’s test on Python! When I click on [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-new-connectivity-and-drivers-landing-page/">SQL Server: New connectivity and Drivers landing page</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">You will find a new connectivity and drivers landing page for SQL Server with .Net, Java, Python, C++, Go and PHP languages:</p>



<p class="wp-block-paragraph"><a href="https://learn.microsoft.com/en-us/sql/connect/?view=sql-server-ver17">SQL Connectivity and Drivers &#8211; SQL Server | Microsoft Learn</a></p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="528" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-64.png" alt="" class="wp-image-39282" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-64.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-64-300x169.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-64-768x432.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">As you can see, you can download, have a quick start and some code samples…</p>



<p class="wp-block-paragraph"><strong>Let’s test on Python!</strong></p>



<p class="wp-block-paragraph">When I click on “Download”, I have the page for <strong>“Python SQL Driver</strong>”:</p>



<p class="wp-block-paragraph"><a href="https://learn.microsoft.com/en-us/sql/connect/python/mssql-python/python-sql-driver-mssql-python?view=sql-server-ver17">Python SQL Driver &#8211; mssql-python (Preview) &#8211; Python driver for SQL Server | Microsoft Learn</a></p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="658" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-65.png" alt="" class="wp-image-39283" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-65.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-65-300x210.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-65-768x538.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">When I click on “Get Started”, I have the page for “<strong>Quickstart: Connect with the mssql-python driver for Python</strong>”:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="711" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-66.png" alt="" class="wp-image-39284" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-66.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-66-300x227.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-66-768x582.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">When I click on “Code Sample”, I have the page for “<strong>Quickstart: Deploy a Python (Django, Flask, or FastAPI) web app to Azure App Service</strong>”:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="939" height="622" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-69.png" alt="" class="wp-image-39287" srcset="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-69.png 939w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-69-300x199.png 300w, https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/06/image-69-768x509.png 768w" sizes="auto, (max-width: 939px) 100vw, 939px" /></figure>



<p class="wp-block-paragraph">Very easy to find out and simple to start with a connection to SQL Server from your development tools…</p>



<p class="wp-block-paragraph">I hope others like Ruby, Spark, … will also come soon! <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f609.png" alt="😉" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>



<p class="wp-block-paragraph"></p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-new-connectivity-and-drivers-landing-page/">SQL Server: New connectivity and Drivers landing page</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-new-connectivity-and-drivers-landing-page/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Lazy Loading (feed)

Served from: www.dbi-services.com @ 2026-08-24 03:14:59 by W3 Total Cache
-->