<?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>SQL Server &#8211; Sibeesh Passion</title>
	<atom:link href="https://sibeeshpassion.com/category/database/sql-server/feed/" rel="self" type="application/rss+xml" />
	<link>https://sibeeshpassion.com</link>
	<description>My passion towards life</description>
	<lastBuildDate>Fri, 27 Apr 2018 04:26:29 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>/wp-content/uploads/2017/04/Sibeesh_Passion_Logo_Small.png</url>
	<title>SQL Server &#8211; Sibeesh Passion</title>
	<link>https://sibeeshpassion.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>How to Copy Table Schema and Data from One Database to another Database in SQL Server</title>
		<link>https://sibeeshpassion.com/copy-table-schema-and-data-from-one-to-another-database/</link>
					<comments>https://sibeeshpassion.com/copy-table-schema-and-data-from-one-to-another-database/#disqus_thread</comments>
		
		<dc:creator><![CDATA[Andrew Jackson]]></dc:creator>
		<pubDate>Thu, 26 Apr 2018 12:41:04 +0000</pubDate>
				<category><![CDATA[Database]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Database to Database]]></category>
		<category><![CDATA[MSSQL]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=12814</guid>

					<description><![CDATA[[toc] Problem: A few days ago, while migrating data from one database to another, I encountered an interesting problem which user faced a lot. “I have two databases, I have to copy tables data from one database to another. My query is how can I copy table schema from one database to another with its schema and data” In this blog, we will learn the easiest solution on how you can solve that query. Solution There are plenty of methods on how you can copy table schema and data from one database to another like Generate script wizard, Import/Export Wizard [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>[toc]</p>
<h2>Problem:</h2>
<p>A few days ago, while migrating data from one database to another, I encountered an interesting problem which user faced a lot.</p>
<p><em>“I have two databases, I have to copy tables data from one database to another. My query is how can I copy table schema from one database to another with its schema and data”</em></p>
<p>In this blog, we will learn the easiest solution on how you can solve that query.</p>
<h2>Solution</h2>
<p>There are plenty of methods on how you can copy table schema and data from one database to another like Generate script wizard, Import/Export Wizard etc. But these methods are quite lengthy and requires users time.</p>
<p>The easiest solution to copy schema’s table from one database to another is to use SysTools SQL Server Database Migration Tool. You will able to migrate your tables schema by performing few steps.</p>
<h3>How to Copy Table Schema and Data from One Database to Another?</h3>
<ul>
<li>Launch <strong><a href="https://www.systoolsgroup.com/sql-server/migration/">SysTools SQL Server Database Migration Tool</a></strong>.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/1.png"><img fetchpriority="high" decoding="async" class="size-medium wp-image-12815" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/1-300x185.png" alt="Launch SysTools SQL Server Database Migration Tool" width="300" height="185" srcset="/wp-content/uploads/2018/04/1-300x185.png 300w, /wp-content/uploads/2018/04/1-768x473.png 768w, /wp-content/uploads/2018/04/1-400x247.png 400w, /wp-content/uploads/2018/04/1-973x600.png 973w, /wp-content/uploads/2018/04/1.png 579w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>Click <strong>Open</strong> and load your database MDF file.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/3.png"><img decoding="async" class="size-medium wp-image-12816" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/3-300x185.png" alt="open MDF File" width="300" height="185" srcset="/wp-content/uploads/2018/04/3-300x185.png 300w, /wp-content/uploads/2018/04/3-768x474.png 768w, /wp-content/uploads/2018/04/3-1024x631.png 1024w, /wp-content/uploads/2018/04/3-400x247.png 400w, /wp-content/uploads/2018/04/3-973x600.png 973w, /wp-content/uploads/2018/04/3.png 1025w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>Choose the <strong>Scan Modes</strong> accordingly and select the SQL Server version of your .mdf file.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/4.png"><img decoding="async" class="size-medium wp-image-12817" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/4-300x185.png" alt="select version" width="300" height="185" srcset="/wp-content/uploads/2018/04/4-300x185.png 300w, /wp-content/uploads/2018/04/4-768x474.png 768w, /wp-content/uploads/2018/04/4-400x247.png 400w, /wp-content/uploads/2018/04/4-973x600.png 973w, /wp-content/uploads/2018/04/4.png 579w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>Select the database table from the left side, which you want to migrate to another database.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/5.png"><img decoding="async" class="size-medium wp-image-12818" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/5-300x185.png" alt="Select the database name" width="300" height="185" srcset="/wp-content/uploads/2018/04/5-300x185.png 300w, /wp-content/uploads/2018/04/5-768x473.png 768w, /wp-content/uploads/2018/04/5-400x247.png 400w, /wp-content/uploads/2018/04/5-973x600.png 973w, /wp-content/uploads/2018/04/5.png 1022w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>Click on <strong>Export</strong> for migration process.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/6.png"><img decoding="async" class="size-medium wp-image-12819" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/6-300x185.png" alt="Click export to migrate the data" width="300" height="185" srcset="/wp-content/uploads/2018/04/6-300x185.png 300w, /wp-content/uploads/2018/04/6-768x473.png 768w, /wp-content/uploads/2018/04/6-400x246.png 400w, /wp-content/uploads/2018/04/6-974x600.png 974w, /wp-content/uploads/2018/04/6.png 1023w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>You will get two options for exporting. One is SQL Server Database and other is SQL Server Compatible Script. Choose it according to your need.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/7.png"><img decoding="async" class="size-medium wp-image-12820" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/7-300x247.png" alt="Two option for exporting" width="300" height="247" srcset="/wp-content/uploads/2018/04/7-300x247.png 300w, /wp-content/uploads/2018/04/7-400x329.png 400w, /wp-content/uploads/2018/04/7.png 624w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>After filling the Server credentials, Select the destination database as ‘<strong>Export to Existing database</strong>’</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/8.png"><img decoding="async" class="size-medium wp-image-12821" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/8-300x247.png" alt="Choose your desired destination location" width="300" height="247" srcset="/wp-content/uploads/2018/04/8-300x247.png 300w, /wp-content/uploads/2018/04/8-400x329.png 400w, /wp-content/uploads/2018/04/8.png 624w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>Software will fetch the databases and let you select the database on which you want to move the selected table.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/9.png"><img decoding="async" class="size-medium wp-image-12822" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/9-300x247.png" alt="fetch details od database" width="300" height="247" srcset="/wp-content/uploads/2018/04/9-300x247.png 300w, /wp-content/uploads/2018/04/9-400x329.png 400w, /wp-content/uploads/2018/04/9.png 623w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>You will get two options to export. Select ‘<strong>With Schema &amp; Data</strong>’. This option will copy schema &amp; data of your selected table from one database and export it to another and click <strong>Export</strong>.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/11.png"><img decoding="async" class="size-medium wp-image-12823" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/11-300x246.png" alt="Select Schema &amp; Data option" width="300" height="246" srcset="/wp-content/uploads/2018/04/11-300x246.png 300w, /wp-content/uploads/2018/04/11-400x328.png 400w, /wp-content/uploads/2018/04/11.png 625w" sizes="(max-width: 300px) 100vw, 300px" /></a></p>
<li>You will get popup of Export complete.</li>
<p><a href="https://sibeeshpassion.com/wp-content/uploads/2018/04/12.png"><img decoding="async" class="size-medium wp-image-12824" src="https://sibeeshpassion.com/wp-content/uploads/2018/04/12-300x186.png" alt="Export complete" width="300" height="186" srcset="/wp-content/uploads/2018/04/12-300x186.png 300w, /wp-content/uploads/2018/04/12-768x476.png 768w, /wp-content/uploads/2018/04/12-400x248.png 400w, /wp-content/uploads/2018/04/12-969x600.png 969w, /wp-content/uploads/2018/04/12.png 577w" sizes="(max-width: 300px) 100vw, 300px" /></a>
</ul>
<h2>Conclusion</h2>
<p>The blog covers the easiest workaround of mostly faced users query on how to copy schema &amp; data from one database to another. You can also use Import/Export Wizard, Generate script wizard etc for object migration using SQL Server. But these methods has some limitations. In Import/Export wizard, the indexes and the key will not get transferred, you need to generate scripts for that. The export wizard fails if foreign keys connecting the tables together is not in a correct order. ‘Generate script’ method is used to generate a single script for tables schema, data, indexes and keys. But again, the limitation is this method doesn’t generate tables creation script in correct order.</p>
<p>So one can opt for SysTools SQL Database Migration Tool for fast migration of tables schema from one database to another.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/copy-table-schema-and-data-from-one-to-another-database/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Generate Database Scripts With Data In SQL Server</title>
		<link>https://sibeeshpassion.com/generate-database-scripts-with-data-in-sql-server/</link>
					<comments>https://sibeeshpassion.com/generate-database-scripts-with-data-in-sql-server/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Fri, 19 Feb 2016 09:09:51 +0000</pubDate>
				<category><![CDATA[Database]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Generate Scripts]]></category>
		<category><![CDATA[Scripts With Data]]></category>
		<guid isPermaLink="false">http://sibeecst_passion.com/?p=11270</guid>

					<description><![CDATA[In this post we will discuss about how we can generate SQL Server scripts of our database with existing data, once we generate the script, the result will give you all the insert query with other queries so that the data also will get inserted in your new database. We are going to use the option &#8216;Schema and data&#8217; in SQL server for this task. I hope the screen shots given will help you generate the script with insert queries. Background I was working with an article which has so many database transactions/actions. So I thought of attaching the database [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>In this post we will discuss about how we can generate SQL Server scripts of our database with existing data, once we generate the script, the result will give you all the insert query with other queries so that the data also will get inserted in your new database. We are going to use the option &#8216;Schema and data&#8217; in SQL server for this task. I hope the screen shots given will help you generate the script with insert queries. </p>
<p><strong>Background</strong></p>
<p>I was working with an article which has so many database transactions/actions. So I thought of attaching the database scripts with data also in the source code download section of the article, so that it may help user to insert the data in his/her database. That made me to write this article. I hope you will like this.</p>
<p><strong>Steps To Generate Database Scripts With Data In SQL Server</strong></p>
<p><strong>Step 1</strong></p>
<p>Right click on your database and select Task -> generate script. </p>
<div id="attachment_11271" style="width: 593px" class="wp-caption alignnone"><a href="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option.png"><img decoding="async" aria-describedby="caption-attachment-11271" src="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option.png" alt="Database_Scripts_With_Data_Select_Option" width="583" height="586" class="size-full wp-image-11271" srcset="/wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option.png 583w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option-150x150.png 150w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option-298x300.png 298w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option-130x130.png 130w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Option-400x402.png 400w" sizes="(max-width: 583px) 100vw, 583px" /></a><p id="caption-attachment-11271" class="wp-caption-text">Database_Scripts_With_Data_Select_Option</p></div>
<p><strong>Step 2</strong></p>
<p>Click next in the introduction screen.</p>
<div id="attachment_11272" style="width: 660px" class="wp-caption alignnone"><a href="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Inroduction-e1455872059585.png"><img decoding="async" aria-describedby="caption-attachment-11272" src="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Inroduction-e1455872059585.png" alt="Database_Scripts_With_Data_Inroduction" width="650" height="604" class="size-full wp-image-11272" srcset="/wp-content/uploads/2016/02/Database_Scripts_With_Data_Inroduction-e1455872059585.png 384w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Inroduction-e1455872059585-300x279.png 300w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Inroduction-e1455872059585-400x372.png 400w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Inroduction-e1455872059585-646x600.png 646w" sizes="(max-width: 650px) 100vw, 650px" /></a><p id="caption-attachment-11272" class="wp-caption-text">Database_Scripts_With_Data_Inroduction</p></div>
<p><strong>Step 3</strong></p>
<p>Select the database object which you are all you need and then click next.</p>
<div id="attachment_11273" style="width: 660px" class="wp-caption alignnone"><a href="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Database_Objects-e1455872190424.png"><img decoding="async" aria-describedby="caption-attachment-11273" src="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Database_Objects-e1455872190424.png" alt="Database_Scripts_With_Data_Select_Database_Objects" width="650" height="604" class="size-full wp-image-11273" srcset="/wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Database_Objects-e1455872190424.png 384w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Database_Objects-e1455872190424-300x279.png 300w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Database_Objects-e1455872190424-400x372.png 400w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Select_Database_Objects-e1455872190424-646x600.png 646w" sizes="(max-width: 650px) 100vw, 650px" /></a><p id="caption-attachment-11273" class="wp-caption-text">Database_Scripts_With_Data_Select_Database_Objects</p></div>
<p><strong>Step 4</strong></p>
<p>Now you will be shown a window which asks you about how your script should be published. </p>
<div id="attachment_11274" style="width: 660px" class="wp-caption alignnone"><a href="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Publish_Options-e1455872352563.png"><img decoding="async" aria-describedby="caption-attachment-11274" src="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Publish_Options-e1455872352563.png" alt="Database_Scripts_With_Data_Publish_Options" width="650" height="604" class="size-full wp-image-11274" srcset="/wp-content/uploads/2016/02/Database_Scripts_With_Data_Publish_Options-e1455872352563.png 384w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Publish_Options-e1455872352563-300x279.png 300w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Publish_Options-e1455872352563-400x372.png 400w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Publish_Options-e1455872352563-646x600.png 646w" sizes="(max-width: 650px) 100vw, 650px" /></a><p id="caption-attachment-11274" class="wp-caption-text">Database_Scripts_With_Data_Publish_Options</p></div>
<p>Click advanced in that window. </p>
<p><strong>Step 5</strong></p>
<p>Select &#8216;Schema and data&#8217; from type of data to script option and then click OK. </p>
<div id="attachment_11275" style="width: 660px" class="wp-caption alignnone"><a href="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Advanced-e1455872521896.png"><img decoding="async" aria-describedby="caption-attachment-11275" src="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Advanced-e1455872521896.png" alt="Database_Scripts_With_Data_Advanced" width="650" height="604" class="size-full wp-image-11275" srcset="/wp-content/uploads/2016/02/Database_Scripts_With_Data_Advanced-e1455872521896.png 384w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Advanced-e1455872521896-300x279.png 300w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Advanced-e1455872521896-400x372.png 400w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Advanced-e1455872521896-646x600.png 646w" sizes="(max-width: 650px) 100vw, 650px" /></a><p id="caption-attachment-11275" class="wp-caption-text">Database_Scripts_With_Data_Advanced</p></div>
<p>Click next.</p>
<p><strong>Step 6</strong></p>
<p>Click finish, now check the script file, it must be having the insert queries too. </p>
<div id="attachment_11276" style="width: 660px" class="wp-caption alignnone"><a href="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Finish-e1455872683355.png"><img decoding="async" aria-describedby="caption-attachment-11276" src="http://sibeeshpassion.com/wp-content/uploads/2016/02/Database_Scripts_With_Data_Finish-e1455872683355.png" alt="Database_Scripts_With_Data_Finish" width="650" height="604" class="size-full wp-image-11276" srcset="/wp-content/uploads/2016/02/Database_Scripts_With_Data_Finish-e1455872683355.png 384w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Finish-e1455872683355-300x279.png 300w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Finish-e1455872683355-400x372.png 400w, /wp-content/uploads/2016/02/Database_Scripts_With_Data_Finish-e1455872683355-646x600.png 646w" sizes="(max-width: 650px) 100vw, 650px" /></a><p id="caption-attachment-11276" class="wp-caption-text">Database_Scripts_With_Data_Finish</p></div>
<p>Now what else is pending, go ahead and run your script. </p>
<p><strong>Conclusion</strong></p>
<p>Did I miss anything that you may think which is needed? Have you ever wanted to do this requirement? Could you find this post as useful? I hope you liked this article. Please share me your valuable suggestions and feedback.</p>
<p><strong>Your turn. What do you think?</strong></p>
<p>A blog isn’t a blog without comments, but do try to stay on topic. If you have a question unrelated to this post, you’re better off posting it on C# Corner, Code Project, Stack Overflow, Asp.Net Forum instead of commenting here. Tweet or email me a link to your question there and I’ll definitely try to help if I can.</p>
<p>Kindest Regards<br />
Sibeesh Venu</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/generate-database-scripts-with-data-in-sql-server/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title>Solution for saving changes not permitted error in SQL</title>
		<link>https://sibeeshpassion.com/solution-for-saving-changes-not-permitted-error-in-sql/</link>
					<comments>https://sibeeshpassion.com/solution-for-saving-changes-not-permitted-error-in-sql/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Mon, 29 Jun 2015 08:07:06 +0000</pubDate>
				<category><![CDATA[Q&A]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Errors]]></category>
		<category><![CDATA[sql table design error]]></category>
		<category><![CDATA[SQL Tips]]></category>
		<category><![CDATA[SQL Tricks]]></category>
		<category><![CDATA[table design]]></category>
		<guid isPermaLink="false">http://sibeecst_passion.com/?p=5461</guid>

					<description><![CDATA[Introduction Hi All, How are you today? In this article we will see a solution for a fix that we usually encounter when you work in Microsoft SQL server. The error message will be &#8220;Saving changes is not permitted,The changes you have made require the following table to be dropped and re-created. You have either made changes to the table that can&#8217;t be re-created or enabled the option Prevent saving changes that require the table to be re-created.&#8221;. Let us see how we can solve this issue. I hope you will like it. Background As the error message says, it [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>Hi All, How are you today? In this article we will see a solution for a fix that we usually encounter when you work in Microsoft SQL server. The error message will be <em>&#8220;Saving changes is not permitted,The changes you have made require the following table to be dropped and re-created. You have either made changes to the table that can&#8217;t be re-created or enabled the option Prevent saving changes that require the table to be re-created.&#8221;</em>. Let us see how we can solve this issue. I hope you will like it.</p>
<p><strong>Background</strong></p>
<p>As the error message says, it is because of you have enabled the option Prevent saving changes. Now we will see how we can disable that option in SQL Server Management Studio. Before going through the fix, we will see teh screenshot of the error.</p>
<p><img decoding="async" src="http://www.sibeeshpassion.com/content/images/tab1.png" alt="www.sibeeshpassion.com" /></p>
<p><strong>Steps to follow</strong></p>
<p>To fix this issue, you need to follow some certain steps. We will explain that here.</p>
<p><em><strong>Step 1</strong></em></p>
<p>Go to Tools menu and click on options.</p>
<p><img decoding="async" src="http://www.sibeeshpassion.com/content/images/tab2.png" alt="www.sibeeshpassion.com" /></p>
<p><em><strong>Step 2</strong></em></p>
<p>Now you can see a window is opened as follows. You can see some settings there. No need to change anything in that.</p>
<p><img decoding="async" src="http://www.sibeeshpassion.com/content/images/tab3.png" alt="www.sibeeshpassion.com" /></p>
<p><em><strong>Step 3</strong></em></p>
<p>Now go to Designers menu and click on &#8220;Table and Database designers&#8221; </p>
<p><img decoding="async" src="http://www.sibeeshpassion.com/content/images/tab4.png" alt="www.sibeeshpassion.com" /></p>
<p><em><strong>Step 4</strong></em></p>
<p>It is time for changing the settings. As you can see there is a check box which is captioned as <em>&#8220;Prevent saving changes that requires table re-creation&#8221;</em> . Just uncheck that and click OK.</p>
<p><img decoding="async" src="http://www.sibeeshpassion.com/content/images/tab5.png" alt="www.sibeeshpassion.com" /></p>
<p>That is all. Now if you try to save that table, you won&#8217;t be facing above mentioned issue. Have a happy table designing.</p>
<p><strong>Conclusion</strong></p>
<p>I hope you will like this article. Please share me your valuable thoughts and comments. Your feedback is always welcomed.</p>
<p>Thanks in advance. Happy coding!</p>
<p>Kindest Regards<br />
<a href="https://plus.google.com/+sibeeshkv" target="_blank">Sibeesh Venu</a></p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/solution-for-saving-changes-not-permitted-error-in-sql/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SqlDateTime Overflow, Must be between Error</title>
		<link>https://sibeeshpassion.com/sqldatetime-overflow-must-be-between-error/</link>
					<comments>https://sibeeshpassion.com/sqldatetime-overflow-must-be-between-error/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Fri, 05 Jun 2015 07:16:12 +0000</pubDate>
				<category><![CDATA[Q&A]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Date Parameter]]></category>
		<category><![CDATA[SQL Errors]]></category>
		<category><![CDATA[SQL Parameter Error]]></category>
		<guid isPermaLink="false">http://sibeecst_passion.com/?p=4482</guid>

					<description><![CDATA[Introduction Hi All, I hope you are fine. We all are using SQL parameter in our application right?Yeah it is a good way to restrict the Injections are hijacks. But still if you pass those parameters in the right way, you will face lots of problems. In this article I am going to share you such an Issue. I hope you will like it. Background Morning I was working in a grid control which editable, and I selected a row to edit and started editing. In a date field I edited the date and clicked update button. I was expecting [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><strong>Introduction</strong></p>
<p>Hi All, I hope you are fine. We all are using SQL parameter in our application right?Yeah it is a good way to restrict the Injections are hijacks. But still if you pass those parameters in the right way, you will face lots of problems. In this article I am going to share you such an Issue. I hope you will like it.</p>
<p><strong>Background</strong></p>
<p>Morning I was working in a grid control which editable, and I selected a row to edit and started editing. In a date field I edited the date and clicked update button. I was expecting an output result as &#8220;Successfully updated&#8221;. But it didn&#8217;t happen. Instead it throws an error. <em>&#8220;SqlDateTime Overflow, Must be between&#8221;</em></p>
<p><strong>Using the code</strong></p>
<p>To resolve this issue, first you must understand the root cause for this. I was passing the parameters as follows.</p>
<p>[csharp]<br />
 SqlParameter[] myParam = new SqlParameter[3];<br />
            myParam[0] = new SqlParameter(&quot;@name&quot;, myObject.name);<br />
            myParam[1] = new SqlParameter(&quot;@ValidFrom&quot;, myObject.hjcValidFrom);<br />
            myParam[2] = new SqlParameter(&quot;@ValidTo&quot;, myObject.hjcValidTo);<br />
[/csharp]</p>
<p>When I run my application with above code, I got the following error.<br />
<img decoding="async" src="http://sibeeshpassion.com/Content/Images/sqldateerror.PNG" alt="" /></p>
<p><strong>So what is the fix/solution?</strong></p>
<p>I changed the parameter as follows. </p>
<p>[csharp]<br />
 SqlParameter[] myParam = new SqlParameter[3];<br />
            myParam[0] = new SqlParameter(&quot;@name&quot;, myObject.name);<br />
            myParam[1] = new SqlParameter(&quot;@ValidFrom&quot;, myObject.hjcValidFrom.ToString(&quot;MM/dd/YYYY&quot;));<br />
            myParam[2] = new SqlParameter(&quot;@ValidTo&quot;, myObject.hjcValidTo.ToString(&quot;MM/dd/YYYY&quot;));<br />
[/csharp]</p>
<p>That solved the issue. Simple right?</p>
<p><strong>Some other case</strong></p>
<p>There are dome other cases you may get this error if you use the codes as follows.<br />
[csharp]<br />
 SqlParameter[] myParam = new SqlParameter[3];<br />
            DateTime myDate=new DateTime();<br />
            myParam[0] = new SqlParameter(&quot;@name&quot;, myObject.name);<br />
            myParam[1] = new SqlParameter(&quot;@ValidFrom&quot;, myDate);<br />
            myParam[2] = new SqlParameter(&quot;@ValidTo&quot;, myDate);<br />
[/csharp]</p>
<p>What you have to do all to fix this issue is just take the now property value from your date time object and pass it your parameter.</p>
<p>[csharp]<br />
 SqlParameter[] myParam = new SqlParameter[3];<br />
            DateTime myDate = DateTime.Now;<br />
            myParam[0] = new SqlParameter(&quot;@name&quot;, myObject.name);<br />
            myParam[1] = new SqlParameter(&quot;@ValidFrom&quot;, myDate);<br />
            myParam[2] = new SqlParameter(&quot;@ValidTo&quot;, myDate);<br />
[/csharp]</p>
<p><strong>Conclusion </strong></p>
<p>I hope you enjoyed reading and found this useful. Please share me your valuable feedback. For me it matters a lot.</p>
<p>Kindest Regards<br />
Sibeesh Venu</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/sqldatetime-overflow-must-be-between-error/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Find Out the Missing Indexes in SQL</title>
		<link>https://sibeeshpassion.com/find-out-the-missing-indexes-in-sql/</link>
					<comments>https://sibeeshpassion.com/find-out-the-missing-indexes-in-sql/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 14:34:35 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Missing Index]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=3781</guid>

					<description><![CDATA[This code helps you to find out the missing Indexes in SQL [sql] SELECT d.[object_id], s = OBJECT_SCHEMA_NAME(d.[object_id]), o = OBJECT_NAME(d.[object_id]), d.equality_columns, d.inequality_columns, d.included_columns, s.unique_compiles, s.user_seeks, s.last_user_seek, s.user_scans, s.last_user_scan INTO #missingindexes FROM sys.dm_db_missing_index_details AS d INNER JOIN sys.dm_db_missing_index_groups AS g ON d.index_handle = g.index_handle INNER JOIN sys.dm_db_missing_index_group_stats AS s ON g.index_group_handle = s.group_handle WHERE d.database_id = DB_ID() AND OBJECTPROPERTY(d.[object_id], &#8216;IsMsShipped&#8217;) = 0; select * from #missingindexes [/sql]]]></description>
										<content:encoded><![CDATA[<p>This code helps you to find out the missing Indexes in SQL<br />
[sql]<br />
SELECT<br />
  d.[object_id],<br />
  s = OBJECT_SCHEMA_NAME(d.[object_id]),<br />
  o = OBJECT_NAME(d.[object_id]),<br />
  d.equality_columns,<br />
  d.inequality_columns,<br />
  d.included_columns,<br />
  s.unique_compiles,<br />
  s.user_seeks, s.last_user_seek,<br />
  s.user_scans, s.last_user_scan<br />
INTO #missingindexes<br />
FROM sys.dm_db_missing_index_details AS d<br />
INNER JOIN sys.dm_db_missing_index_groups AS g<br />
ON d.index_handle = g.index_handle<br />
INNER JOIN sys.dm_db_missing_index_group_stats AS s<br />
ON g.index_group_handle = s.group_handle<br />
WHERE d.database_id = DB_ID()<br />
AND OBJECTPROPERTY(d.[object_id], &#8216;IsMsShipped&#8217;) = 0;  </p>
<p>select * from #missingindexes<br />
[/sql]</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/find-out-the-missing-indexes-in-sql/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Find the Relationship Difference Between Two DB</title>
		<link>https://sibeeshpassion.com/find-the-relationship-difference-between-two-db/</link>
					<comments>https://sibeeshpassion.com/find-the-relationship-difference-between-two-db/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 14:32:35 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Relation]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=3741</guid>

					<description><![CDATA[Find the relationship difference between two DB. [sql] SELECT f.name AS ForeignKey FROM sys.foreign_keys AS f where f.name not in (SELECT f.name AS ForeignKey FROM inova.sys.foreign_keys AS f)order by f.name asc [/sql]]]></description>
										<content:encoded><![CDATA[<p>Find the relationship difference between two DB.<br />
[sql]<br />
SELECT f.name AS ForeignKey<br />
FROM sys.foreign_keys AS f where f.name not in<br />
(SELECT f.name AS ForeignKey<br />
FROM inova.sys.foreign_keys AS f)order by f.name asc<br />
[/sql]</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/find-the-relationship-difference-between-two-db/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Find Relationships Between Tables in SQL Server 2008</title>
		<link>https://sibeeshpassion.com/find-relationships-between-tables-in-sql-server-2008/</link>
					<comments>https://sibeeshpassion.com/find-relationships-between-tables-in-sql-server-2008/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 14:30:18 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Relation]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=3711</guid>

					<description><![CDATA[find the relationships between tables in SQL Server 2008 [sql] SELECT f.name AS ForeignKey, SCHEMA_NAME(f.SCHEMA_ID) SchemaName, OBJECT_NAME(f.parent_object_id) AS TableName, COL_NAME(fc.parent_object_id,fc.parent_column_id) AS ColumnName, SCHEMA_NAME(o.SCHEMA_ID) ReferenceSchemaName, OBJECT_NAME (f.referenced_object_id) AS ReferenceTableName, COL_NAME(fc.referenced_object_id,fc.referenced_column_id) AS ReferenceColumnName FROM sys.foreign_keys AS f INNER JOIN sys.foreign_key_columns AS fc ON f.OBJECT_ID = fc.constraint_object_id INNER JOIN sys.objects AS o ON o.OBJECT_ID = fc.referenced_object_id [/sql]]]></description>
										<content:encoded><![CDATA[<p>find the relationships between tables in SQL Server 2008<br />
[sql]<br />
SELECT f.name AS ForeignKey,<br />
   SCHEMA_NAME(f.SCHEMA_ID) SchemaName,<br />
   OBJECT_NAME(f.parent_object_id) AS TableName,<br />
   COL_NAME(fc.parent_object_id,fc.parent_column_id) AS ColumnName,<br />
   SCHEMA_NAME(o.SCHEMA_ID) ReferenceSchemaName,<br />
   OBJECT_NAME (f.referenced_object_id) AS ReferenceTableName,<br />
   COL_NAME(fc.referenced_object_id,fc.referenced_column_id) AS ReferenceColumnName<br />
FROM sys.foreign_keys AS f<br />
INNER JOIN sys.foreign_key_columns AS fc ON f.OBJECT_ID = fc.constraint_object_id<br />
INNER JOIN sys.objects AS o ON o.OBJECT_ID = fc.referenced_object_id<br />
[/sql]</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/find-relationships-between-tables-in-sql-server-2008/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Find Which Are All Table has Set Identity</title>
		<link>https://sibeeshpassion.com/find-which-are-all-table-has-set-identity/</link>
					<comments>https://sibeeshpassion.com/find-which-are-all-table-has-set-identity/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 14:25:45 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=3652</guid>

					<description><![CDATA[Find which are all table has set identity. [sql] select COLUMN_NAME, TABLE_NAME from INFORMATION_SCHEMA.COLUMNS where TABLE_SCHEMA = &#8216;dbo&#8217; and COLUMNPROPERTY(object_id(TABLE_NAME), COLUMN_NAME, &#8216;IsIdentity&#8217;) = 1 order by TABLE_NAME [/sql]]]></description>
										<content:encoded><![CDATA[<p>Find which are all table has set identity.<br />
[sql]<br />
select COLUMN_NAME, TABLE_NAME<br />
from INFORMATION_SCHEMA.COLUMNS<br />
where TABLE_SCHEMA = &#8216;dbo&#8217;<br />
and COLUMNPROPERTY(object_id(TABLE_NAME), COLUMN_NAME, &#8216;IsIdentity&#8217;) = 1<br />
order by TABLE_NAME<br />
[/sql]</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/find-which-are-all-table-has-set-identity/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Get the Count of Entries in Each Table in a DB in SQL</title>
		<link>https://sibeeshpassion.com/get-the-count-of-entries-in-each-table-in-a-db-in-sql/</link>
					<comments>https://sibeeshpassion.com/get-the-count-of-entries-in-each-table-in-a-db-in-sql/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 14:22:32 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Entry Count]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=3621</guid>

					<description><![CDATA[Hi All, This code will helps you to get the count of entries in each table in a DB in SQL: [sql] SELECT sysobjects.Name , sysindexes.Rows FROM sysobjects INNER JOIN sysindexes ON sysobjects.id = sysindexes.id WHERE type = &#8216;U&#8217; AND sysindexes.IndId &#60; 2 ORDER BY sysobjects.Name [/sql] OR [/sql] SELECT sum(sysindexes.Rows),GETDATE() FROM sysobjects INNER JOIN sysindexes ON sysobjects.id = sysindexes.id WHERE type = &#8216;U&#8217; AND sysindexes.IndId < 2 [/sql] Kindest Regards]]></description>
										<content:encoded><![CDATA[<p>Hi All,</p>
<p>This code will helps you to get the count of entries in each table in a DB in SQL:<br />
[sql]<br />
SELECT<br />
    sysobjects.Name<br />
    , sysindexes.Rows<br />
FROM<br />
    sysobjects<br />
    INNER JOIN sysindexes<br />
    ON sysobjects.id = sysindexes.id<br />
WHERE<br />
    type = &#8216;U&#8217;<br />
    AND sysindexes.IndId &lt; 2<br />
ORDER BY<br />
    sysobjects.Name<br />
  [/sql]<br />
OR<br />
[/sql]<br />
SELECT<br />
   sum(sysindexes.Rows),GETDATE()<br />
FROM<br />
    sysobjects<br />
    INNER JOIN sysindexes<br />
    ON sysobjects.id = sysindexes.id<br />
WHERE<br />
    type = &#8216;U&#8217;<br />
    AND sysindexes.IndId < 2  
[/sql]

Kindest Regards
</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/get-the-count-of-entries-in-each-table-in-a-db-in-sql/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Get the Table Count in a DB in SQL</title>
		<link>https://sibeeshpassion.com/get-the-table-count-in-a-db-in-sql/</link>
					<comments>https://sibeeshpassion.com/get-the-table-count-in-a-db-in-sql/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Sun, 31 May 2015 14:19:38 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Table Count]]></category>
		<guid isPermaLink="false">https://sibeeshpassion.com/?p=3602</guid>

					<description><![CDATA[Get the table count in a DB in SQL. [sql] select * from sys.tables where is_ms_shipped=&#8217;0&#8242; [/sql]]]></description>
										<content:encoded><![CDATA[<p>Get the table count in a DB in SQL.<br />
[sql]<br />
select * from sys.tables where is_ms_shipped=&#8217;0&#8242;<br />
[/sql]</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/get-the-table-count-in-a-db-in-sql/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
