<?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>collation &#8211; Database Research &amp; Development</title>
	<atom:link href="https://www.dbrnd.com/tag/collation/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.dbrnd.com</link>
	<description>BIGData &#124; NoSQL &#124; MSSQL &#124; MySQL &#124; PostgreSQL</description>
	<lastBuildDate>Sun, 24 Sep 2017 13:58:02 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.4</generator>
	<item>
		<title>SQL Server Database Administrator Interview Questions and Answers (Day-6)</title>
		<link>https://www.dbrnd.com/2016/07/sql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6/</link>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Thu, 14 Jul 2016 20:59:17 +0000</pubDate>
				<category><![CDATA[SQL Server Interview]]></category>
		<category><![CDATA[answers]]></category>
		<category><![CDATA[Anvesh Patel]]></category>
		<category><![CDATA[browser service]]></category>
		<category><![CDATA[cloud computing]]></category>
		<category><![CDATA[collation]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[database administrator]]></category>
		<category><![CDATA[database research and development]]></category>
		<category><![CDATA[dbrnd]]></category>
		<category><![CDATA[Interviews]]></category>
		<category><![CDATA[model database]]></category>
		<category><![CDATA[msdtc]]></category>
		<category><![CDATA[questions]]></category>
		<category><![CDATA[SQL Query]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Server Administrator]]></category>
		<category><![CDATA[SQL Server Monitoring]]></category>
		<category><![CDATA[SQL Server Performance Tunning]]></category>
		<category><![CDATA[SQL Server Tips and Tricks]]></category>
		<category><![CDATA[TSQL]]></category>
		<category><![CDATA[udp port]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=3335</guid>

					<description><![CDATA[What is the main role of Model Database in SQL Server? The model database, as its name implies, serves as the model (or template) for all databases created on the same instance. If the model database is modified, all subsequent databases created on that instance will pick up those changes, but earlier created databases will [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a class="a2a_button_facebook" href="https://www.addtoany.com/add_to/facebook?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&amp;linkname=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" title="Facebook" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_twitter" href="https://www.addtoany.com/add_to/twitter?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&amp;linkname=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" title="Twitter" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_linkedin" href="https://www.addtoany.com/add_to/linkedin?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&amp;linkname=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" title="LinkedIn" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&amp;linkname=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_reddit" href="https://www.addtoany.com/add_to/reddit?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&amp;linkname=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" title="Reddit" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&amp;linkname=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" title="Pocket" rel="nofollow noopener" target="_blank"></a><a class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fsql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6%2F&#038;title=SQL%20Server%20Database%20Administrator%20Interview%20Questions%20and%20Answers%20%28Day-6%29" data-a2a-url="https://www.dbrnd.com/2016/07/sql-server-database-administrator-interview-questions-and-answers-model-database-collation-msdtc-udp-browser-service-day-6/" data-a2a-title="SQL Server Database Administrator Interview Questions and Answers (Day-6)"></a></p><p><strong>What is the main role of Model Database in SQL Server?</strong></p>
<blockquote><p>The model database, as its name implies, serves as the model (or template) for all databases created on the same instance. If the model database is modified, all subsequent databases created on that instance will pick up those changes, but earlier created databases will not. Note that TEMPDB is also created from model every time SQL Server starts up.</p></blockquote>
<p><strong>What is a collation in SQL Server?</strong></p>
<blockquote><p>Collation refers to a set of rules that determine how data is sorted and compared. Character data is sorted using rules that define the correct character sequence, with options for specifying case-sensitivity, accent marks, kana character types and character width.</p></blockquote>
<p><strong>What is Use of @@ SPID in SQL Server?</strong></p>
<blockquote><p>A SPID is the returns sessions ID of the current user process. And using that session ID, we can find out that the last query was executed.</p></blockquote>
<p><strong>What is cloud computing?</strong></p>
<blockquote><p>Cloud computing is a model for enabling ubiquitous, convenient, on-demand network access to a shared pool of configurable computing resources (e.g., networks, servers, storage, applications, and services) that can be rapidly provisioned and released with minimal management effort or service provider interaction.</p></blockquote>
<p><strong>How do I rename my SQL Server instance?</strong></p>
<blockquote><p>SQL Server doesn&#8217;t support renaming the instance name directly so you can uninstall the existed instance and install it with the new name and change the computer name and rename the part of the instance name that corresponds to the computer name.</p></blockquote>
<p><strong>How do I store data in multiple languages within one database?</strong></p>
<blockquote><p>The easiest way to manage character data in international databases is to always use the Unicode nchar, nvarchar, and nvarchar(max) data types, instead of their non-Unicode equivalents, char, varchar, and text. Unicode is a standard for mapping code points to characters.</p></blockquote>
<p><strong>How do I configure SQL Server to enable distributed transactions via Linked Server?</strong></p>
<blockquote><p>To enable distributed transactions across different servers, you need to configure MS DTC on both servers and some of your SQL Server server options.</p>
<p>Please run &#8220;services.msc&#8221; from windows run dialog to check DTC service is running or not.</p>
<p>Please make sure this service could access the network and could receive connection from other server.</p>
<p>Please enable the XACT_ABORT.</p></blockquote>
<p><strong>What is recompilation?</strong></p>
<blockquote><p>When the cached execution plan for a query cannot be used so the procedure recompiles.</p></blockquote>
<p><strong>How do I configure Windows Firewall to allow remote connections using TCP/IP protocol for SQL Server?</strong></p>
<blockquote><p>On the server on which SQL Server runs, we need to find out which ports that SQL Server is listening and add which to Windows Firewall Inbound Exceptions.</p>
<p>Firstly, we need to add TCP port on which SQL Server service is listening to the Windows Firewall Inbound Exceptions so that the client can make connections to SQL Server over Windows Firewall.</p>
<p>Secondly, if we do not specify TCP port in the connection string and SQL Server is not listening on the TCP 1433 port, we need to add UDP 1434 port on which SQL Server Browser Services is listening to the Windows Firewall Inbound Exceptions.</p></blockquote>
<p><strong>What is parallelism?</strong></p>
<blockquote><p>SQL Server can perform a query or index operation in parallel by using several operating system threads, the operation can be completed quickly. When a single query runs of multiple CPUs is known as query parallelism.</p></blockquote>
<p><strong>What is the default query threshold for parallelism?</strong></p>
<blockquote><p>The query optimizer decides to utilize multiple SPIDS running on different processors to query / transfer data. Default threshold is 5 seconds.</p></blockquote>
<p><strong>How to start the SQL Server with minimal configuration?</strong></p>
<blockquote><p>If there are any configuration problems that prevent the server from starting, you can start an instance of Microsoft SQL Server by using the minimal configuration startup option. This is the startup option -f.  Starting an instance of SQL Server with minimal configuration automatically puts the server in single-user mode.</p></blockquote>
<p><strong>What is auto close option?</strong></p>
<blockquote><p>AUTO CLOSE option:</p>
<p>When set to ON, the database is shut down cleanly and its resources are freed after the last user exits. The database automatically reopens when a user tries to use the database again.</p>
<p>When set to OFF, the database remains open after the last user exits.</p></blockquote>
<p><strong>What do you know about the MSDTC service?</strong></p>
<blockquote><p>MSDTC (aka Microsoft Distributed Transaction Control) is a piece of software which a lot of people use, but they don&#8217;t really know what it does, or how it works. MSDTC is used by SQL Server and other applications when they want to make a distributed transaction between more than one machine.</p></blockquote>
<p><strong>What do you know about the port UDP 1434?</strong></p>
<blockquote><p>UDP port 1434 is used for SQL Server named instances. The SQL Server Browser service listens on this port for incoming connections to a named instance. The service then responds to the client with the TCP port number for the requested named instance.</p></blockquote>
<p><strong>What do you know about the SQL Server Browser Service?</strong></p>
<blockquote><p>While commonly thought of as “one of those other SQL Server services”, life without the SQL Server Browser Service would be a bit more of a hassle. Its main purpose is to aid in the detection of SQL Server instances and provide information necessary for connecting to them.  It listens on UDP port 1434 and returns port numbers and version information for requested instances on a machine.</p>
<p>When a user connects to the default instance, the connection is passed to TCP 1433 automatically.  When connecting to a named instance and the port number is unknown, the first connection made is to the Browser Service at UDP 1434, which then returns the proper port number on which to initiate the TCP connection.</p></blockquote>
<p><strong>What is the Instance-aware and Instance-unaware services in SQL Server?</strong></p>
<p>Instance-aware services are associated with a specific instance of SQL Server.</p>
<ul>
<li>SQL Server</li>
<li>SQL Server Agent</li>
<li>Analysis Services</li>
<li>Reporting Services</li>
<li>Full-text search</li>
</ul>
<p>Instance-unaware services are shared among all installed SQL Server instances.</p>
<ul>
<li>Integration Services</li>
<li>SQL Server Browser</li>
<li>SQL Server Active Directory Helper</li>
<li>SQL Writer</li>
</ul>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>SQL Server: Database Developer (T-SQL) Interview Questions and Answers (Day-7)</title>
		<link>https://www.dbrnd.com/2016/06/sql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7/</link>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Sat, 18 Jun 2016 20:01:17 +0000</pubDate>
				<category><![CDATA[SQL Server Interview]]></category>
		<category><![CDATA[answers]]></category>
		<category><![CDATA[Anvesh Patel]]></category>
		<category><![CDATA[character set]]></category>
		<category><![CDATA[collation]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[Database Developer]]></category>
		<category><![CDATA[database research and development]]></category>
		<category><![CDATA[dbrnd]]></category>
		<category><![CDATA[Interviews]]></category>
		<category><![CDATA[linked server]]></category>
		<category><![CDATA[questions]]></category>
		<category><![CDATA[SQL Query]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Server Administrator]]></category>
		<category><![CDATA[SQL Server Monitoring]]></category>
		<category><![CDATA[SQL Server Performance Tunning]]></category>
		<category><![CDATA[SQL Server Tips and Tricks]]></category>
		<category><![CDATA[T-SQL]]></category>
		<category><![CDATA[triggers]]></category>
		<category><![CDATA[TSQL]]></category>
		<category><![CDATA[user defined function]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=3051</guid>

					<description><![CDATA[What are the advantages of User defined Function? You can create the function once, store it in the database, and call it any number of times in your program. Similar to stored procedures, Transact-SQL user-defined functions reduce the compilation cost of Transact-SQL code by caching the plans and reusing them for repeated executions. An operation [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a class="a2a_button_facebook" href="https://www.addtoany.com/add_to/facebook?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&amp;linkname=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" title="Facebook" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_twitter" href="https://www.addtoany.com/add_to/twitter?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&amp;linkname=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" title="Twitter" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_linkedin" href="https://www.addtoany.com/add_to/linkedin?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&amp;linkname=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" title="LinkedIn" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&amp;linkname=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_reddit" href="https://www.addtoany.com/add_to/reddit?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&amp;linkname=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" title="Reddit" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&amp;linkname=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" title="Pocket" rel="nofollow noopener" target="_blank"></a><a class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F06%2Fsql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7%2F&#038;title=SQL%20Server%3A%20Database%20Developer%20%28T-SQL%29%20Interview%20Questions%20and%20Answers%20%28Day-7%29" data-a2a-url="https://www.dbrnd.com/2016/06/sql-server-database-developer-t-sql-interview-questions-and-answers-udf-scalar-function-ddl-dml-trigger-linked-server-collation-day-7/" data-a2a-title="SQL Server: Database Developer (T-SQL) Interview Questions and Answers (Day-7)"></a></p><p><strong>What are the advantages of User defined Function?</strong></p>
<ul>
<li>You can create the function once, store it in the database, and call it any number of times in your program.</li>
<li>Similar to stored procedures, Transact-SQL user-defined functions reduce the compilation cost of Transact-SQL code by caching the plans and reusing them for repeated executions.</li>
<li>An operation that filters data based on some complex constraint that cannot be expressed in a single scalar expression can be expressed as a function.</li>
</ul>
<p><strong>What is a scalar function in SQL Server?</strong></p>
<blockquote><p>A scalar-valued function (SVF) returns a single value, such as a string, integer, or bit value.You can create scalar-valued user-defined functions in managed code using any .NET Framework programming language.</p></blockquote>
<p><strong>Can you write dynamic SQL in User defined Function?</strong></p>
<blockquote><p>No: we cannot perform dynamic SQL in a User defined function.</p>
<p>We should re-write our function to not require dynamic SQL.</p></blockquote>
<p><strong>Have you created DDL Trigger?</strong></p>
<blockquote><p>Yes:</p>
<p>DDL triggers fire in response to a variety of Data Definition Language (DDL) events. These events primarily correspond to Transact-SQL statements that start with the keywords CREATE, ALTER, DROP, GRANT, DENY, REVOKE or UPDATE STATISTICS.</p></blockquote>
<p><strong>In which scenarios, you require to create DDL Triggers?</strong></p>
<ul>
<li>Prevent certain changes to your database schema.</li>
<li>Have something occur in the database in response to a change in your database schema.</li>
<li>Record changes or events in the database schema.</li>
</ul>
<p><strong>What are the basic system tables to find information about the Triggers?</strong></p>
<ul>
<li>sys.trigger_event_types</li>
<li>sys.triggers</li>
<li>sys.triggers</li>
<li>sys.server_triggers</li>
</ul>
<p><strong>What is a DML trigger?</strong></p>
<blockquote><p>DML triggers is a special type of stored procedure that automatically takes effect when a data manipulation language (DML) event takes place that affects the table or view defined in the trigger. DML events include INSERT, UPDATE, or DELETE statements. DML triggers can be used to enforce business rules and data integrity, query other tables, and include complex Transact-SQL statements.</p></blockquote>
<p><strong>What is an AFTER TRIGGER?</strong></p>
<blockquote><p>AFTER triggers are executed after the action of the INSERT, UPDATE, MERGE, or DELETE statement is performed. AFTER triggers are never executed if a constraint violation occurs; therefore, these triggers cannot be used for any processing that might prevent constraint violations.</p></blockquote>
<p><strong>What is an INSTEAD OF TRIGGER?</strong></p>
<blockquote><p>INSTEAD OF triggers override the standard actions of the triggering statement. Therefore, they can be used to perform error or value checking on one or more columns and the perform additional actions before insert, updating or deleting the row or rows.</p>
<p>The primary advantage of INSTEAD OF triggers is that they enable views that would not be updatable to support updates.</p>
<p>Another advantage of INSTEAD OF triggers is that they enable you to code logic that can reject parts of a batch while letting other parts of a batch to succeed.</p></blockquote>
<p><strong>What is a Logon Triggers?</strong></p>
<blockquote><p>Logon triggers fire stored procedures in response to a LOGON event. This event is raised when a user session is established with an instance of SQL Server. Logon triggers fire after the authentication phase of logging in finishes, but before the user session is actually established.</p></blockquote>
<p><strong>T-SQL Script to disable/enable the triggers.</strong></p>
<blockquote><p><strong>To Disable:</strong></p><pre class="crayon-plain-tag">DISABLE Trigger ALL ON ALL SERVER;
DISABLE TRIGGER Trigger_Name ON DATABASE;
DISABLE TRIGGER Trigger_Name ON db.table_name;</pre><p>
<strong>To Enable:</strong></p><pre class="crayon-plain-tag">ENABLETrigger ALL ON ALL SERVER;
ENABLETRIGGER Trigger_Name ON DATABASE;
ENABLETRIGGER Trigger_Name ON db.table_name;</pre><p>
</p></blockquote>
<p><strong>What is a Linked Server?</strong></p>
<blockquote><p>Another question that can tell you if the candidate has experience with distributed databases is &#8220;What is a Linked Server?&#8221; A linked server is a reference from one SQL Server server to another. If you have databases on another SQL Server server that contains data you need for your system, you could create a link server on your server to the other SQL Server server. Then, you can use the four-part name of the remote table to use it within your local queries.</p></blockquote>
<p><strong>What is a four-part name?</strong></p>
<blockquote><p>This question can help you get a sense for whether the candidate ever crosses database boundaries with his queries. A four-part name refers to the parts of a SQL Server object name that uniquely identifies it in the SQL environment. The first part is the instance. The second part is the database. Third is the schema and fourth is the object name. for example, linkd1.db_name.dbo.table_name.</p></blockquote>
<p><strong>What does a cardinality of zero mean?</strong></p>
<blockquote><p>Well, if a column has a cardinality of zero, it means that the column has no unique values. This could potentially happen if the column has all NULL’s – which means that the column was never really used anyways.</p></blockquote>
<p><strong>How can you delete duplicate records using SET ROWCOUNT?</strong></p>
<blockquote><p>Use the SET ROWCOUNT command. For instance, if you have 2 duplicate rows, you would SET ROWCOUNT 1, execute DELETE command and then SET ROWCOUNT 0.</p></blockquote>
<p><strong>What is Delegation in SQL Server?</strong></p>
<blockquote><p>SQL Server and Windows can be configured to enable a client connected to an instance of SQL Server to connect to another instance of SQL Server of forwarding the credentials of an authenticated Windows user.</p>
<p>This arrangement is known as delegation.</p></blockquote>
<p><strong>What is Character Set and Collation?</strong></p>
<blockquote class="wp-embedded-content" data-secret="VUBoYXUfMQ"><p><a href="https://www.dbrnd.com/2015/10/database-theory-what-is-character-set-and-collation/">Database Theory: What is Character Set and Collation</a></p></blockquote>
<p><iframe class="wp-embedded-content" sandbox="allow-scripts" security="restricted"  src="https://www.dbrnd.com/2015/10/database-theory-what-is-character-set-and-collation/embed/#?secret=VUBoYXUfMQ" data-secret="VUBoYXUfMQ" width="600" height="338" title="&#8220;Database Theory: What is Character Set and Collation&#8221; &#8212; Database Research &amp; Development" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe></p>
<p><strong>How to find total Row Count of All Tables in a Database?</strong></p>
<blockquote class="wp-embedded-content" data-secret="nLeAHxJnOJ"><p><a href="https://www.dbrnd.com/2015/11/sql-server-script-to-find-total-row-count-of-all-tables-in-a-database/">SQL Server: Script to find total Row Count of All Tables in a Database</a></p></blockquote>
<p><iframe class="wp-embedded-content" sandbox="allow-scripts" security="restricted"  src="https://www.dbrnd.com/2015/11/sql-server-script-to-find-total-row-count-of-all-tables-in-a-database/embed/#?secret=nLeAHxJnOJ" data-secret="nLeAHxJnOJ" width="600" height="338" title="&#8220;SQL Server: Script to find total Row Count of All Tables in a Database&#8221; &#8212; Database Research &amp; Development" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe></p>
<p><strong>How to find the last Executed Query using SPID?</strong></p>
<blockquote class="wp-embedded-content" data-secret="nnLyFdGO2G"><p><a href="https://www.dbrnd.com/2015/11/sql-server-script-to-find-the-last-executed-query-using-spid/">SQL Server: Script to find the last Executed Query using SPID</a></p></blockquote>
<p><iframe class="wp-embedded-content" sandbox="allow-scripts" security="restricted"  src="https://www.dbrnd.com/2015/11/sql-server-script-to-find-the-last-executed-query-using-spid/embed/#?secret=nnLyFdGO2G" data-secret="nnLyFdGO2G" width="600" height="338" title="&#8220;SQL Server: Script to find the last Executed Query using SPID&#8221; &#8212; Database Research &amp; Development" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe></p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>MySQL: How to change default Character set to UTF-8</title>
		<link>https://www.dbrnd.com/2015/10/mysql-how-to-change-default-character-set-to-utf-8/</link>
					<comments>https://www.dbrnd.com/2015/10/mysql-how-to-change-default-character-set-to-utf-8/#comments</comments>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Fri, 30 Oct 2015 17:02:03 +0000</pubDate>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Anvesh Patel]]></category>
		<category><![CDATA[character set]]></category>
		<category><![CDATA[collation]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[database research and development]]></category>
		<category><![CDATA[dbrnd]]></category>
		<category><![CDATA[MySQL Command]]></category>
		<category><![CDATA[MySQL Database Administrator]]></category>
		<category><![CDATA[MySQL Database Designing]]></category>
		<category><![CDATA[MySQL Database Programming]]></category>
		<category><![CDATA[MySQL Error]]></category>
		<category><![CDATA[MySQL Performance Tunning]]></category>
		<category><![CDATA[MySQL Query]]></category>
		<category><![CDATA[MySQL Tips and Tricks]]></category>
		<category><![CDATA[utf-8]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=962</guid>

					<description><![CDATA[In the previous post, I discussed and provided the small note on Database Character Set and Collation. In this post, I am showing how you can configure or change default Character Set in MySQL? Sometimes, it requires changing the default character set of MySQL Server or MySQL Database. A Character set &#8220;latin1&#8221; and Collation &#8220;latin1_swedish_ci&#8221; [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a class="a2a_button_facebook" href="https://www.addtoany.com/add_to/facebook?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&amp;linkname=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" title="Facebook" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_twitter" href="https://www.addtoany.com/add_to/twitter?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&amp;linkname=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" title="Twitter" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_linkedin" href="https://www.addtoany.com/add_to/linkedin?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&amp;linkname=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" title="LinkedIn" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&amp;linkname=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_reddit" href="https://www.addtoany.com/add_to/reddit?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&amp;linkname=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" title="Reddit" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&amp;linkname=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" title="Pocket" rel="nofollow noopener" target="_blank"></a><a class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fmysql-how-to-change-default-character-set-to-utf-8%2F&#038;title=MySQL%3A%20How%20to%20change%20default%20Character%20set%20to%20UTF-8" data-a2a-url="https://www.dbrnd.com/2015/10/mysql-how-to-change-default-character-set-to-utf-8/" data-a2a-title="MySQL: How to change default Character set to UTF-8"></a></p><p>In the previous post, I discussed and provided the small note on Database Character Set and Collation.<br />
In this post, I am showing how you can configure or change default Character Set in MySQL?</p>
<blockquote><p>Sometimes, it requires changing the default character set of MySQL Server or MySQL Database.<br />
A Character set &#8220;latin1&#8221; and Collation &#8220;latin1_swedish_ci&#8221; are the default of MySQL Server.</p>
<p>This is a standard configuration, and you do not need to change anything, but if your application requires storing data using a different character set, you have to change this default configuration.</p></blockquote>
<p><strong>Here, I am showing how to change your default character set and collation to UTF-8.</strong></p>
<p>MySQL Server provides, different three ways to configure character set and collation.</p>
<ul>
<li>Configure Character set and Collation at Database Level.</li>
<li>Configure Character set and Collation at Server Startup.</li>
<li>Configure Character set and Collation during MySQL Server Installation and Configuration.</li>
</ul>
<p><strong>First, check your default Character Set and Collation of MySQL Server.</strong></p><pre class="crayon-plain-tag">SHOW VARIABLES LIKE 'chara%'; 
SHOW VARIABLES LIKE 'collation%';</pre><p> </p>
<p><strong>If you want to change the default to UTF-8, you want to add the following to my.cnf (MySQL Configuration File).<br />
</strong></p>
<pre class="crayon-plain-tag">[client]
default-character-set=utf8

[mysql]
default-character-set=utf8

[mysqld]
collation-server = utf8_unicode_ci
init-connect='SET NAMES utf8'
character-set-server = utf8</pre> </p>
<p><strong>Specify Character Settings per Database:<br />
</strong></p>
<pre class="crayon-plain-tag">CREATE DATABASE MyDatabase
DEFAULT CHARACTER SET utf8
DEFAULT COLLATE utf8_general_ci;</pre> </p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbrnd.com/2015/10/mysql-how-to-change-default-character-set-to-utf-8/feed/</wfw:commentRss>
			<slash:comments>4</slash:comments>
		
		
			</item>
		<item>
		<title>Database Theory: What is Character Set and Collation</title>
		<link>https://www.dbrnd.com/2015/10/database-theory-what-is-character-set-and-collation/</link>
					<comments>https://www.dbrnd.com/2015/10/database-theory-what-is-character-set-and-collation/#comments</comments>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Thu, 29 Oct 2015 18:26:59 +0000</pubDate>
				<category><![CDATA[Database Theory]]></category>
		<category><![CDATA[Anvesh Patel]]></category>
		<category><![CDATA[character set]]></category>
		<category><![CDATA[collation]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[database concept]]></category>
		<category><![CDATA[database research and development]]></category>
		<category><![CDATA[database standards]]></category>
		<category><![CDATA[database topic]]></category>
		<category><![CDATA[dbrnd]]></category>
		<category><![CDATA[latin1]]></category>
		<category><![CDATA[RDBMS]]></category>
		<category><![CDATA[utf-8]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=955</guid>

					<description><![CDATA[In this post, I am sharing small Database theory on Character Set and Collation. As we are Database Professionals and already experienced with &#8220;Collate&#8221; in SQL Server and MySQL. I found that fresher and intermediate Database Professional have doubt and question about Character Set and Collation. Let me clear this with a natural note. What [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a class="a2a_button_facebook" href="https://www.addtoany.com/add_to/facebook?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&amp;linkname=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" title="Facebook" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_twitter" href="https://www.addtoany.com/add_to/twitter?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&amp;linkname=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" title="Twitter" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_linkedin" href="https://www.addtoany.com/add_to/linkedin?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&amp;linkname=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" title="LinkedIn" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&amp;linkname=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_reddit" href="https://www.addtoany.com/add_to/reddit?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&amp;linkname=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" title="Reddit" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&amp;linkname=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" title="Pocket" rel="nofollow noopener" target="_blank"></a><a class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fwww.dbrnd.com%2F2015%2F10%2Fdatabase-theory-what-is-character-set-and-collation%2F&#038;title=Database%20Theory%3A%20What%20is%20Character%20Set%20and%20Collation" data-a2a-url="https://www.dbrnd.com/2015/10/database-theory-what-is-character-set-and-collation/" data-a2a-title="Database Theory: What is Character Set and Collation"></a></p><p>In this post, I am sharing small Database theory on Character Set and Collation.<br />
As we are Database Professionals and already experienced with &#8220;Collate&#8221; in SQL Server and MySQL.<br />
I found that fresher and intermediate Database Professional have doubt and question about Character Set and Collation.</p>
<p>Let me clear this with a natural note.</p>
<p><strong>What is Character Set?</strong></p>
<blockquote><p>A Character Set is nothing but just a list of symbols and encodings. </p>
<p>For example, latin1 and UTF-8 are the most traditional character set.<br />
Using latin1, you will be able to write all American words because latin1 contains all ASCII characters, which are sufficient to write an English word. On the contrary, with ASCII you will not be able to write all words of Western European specific languages because for instance, characters like &#8216;ë&#8217;, &#8216;õ&#8217;, &#8216;Ñ&#8217; are missing.</p>
<p>A Character Set encodes characters so that they fit in memory. For example,  the euro symbol, €, will be encoded as 0xa4, and in UTF-8, it will be 0xe282ac.</p></blockquote>
<p><strong>What is Collation?</strong></p>
<blockquote><p>A collation is a set of rules for comparing characters in a character set. It has also ruled for sorting of characters, and proper order of two characters varies from language to language.<br />
A Collation compared two strings like, if a word is greater than another one, and sort accordingly. </p>
<p>If you are using &#8220;latin1&#8221; Character set, you can use &#8220;latin1_swedish_ci&#8221; Collation.<br />
You have to choose right collation because wrong collation may affect your database performance.</p></blockquote>
<p><strong>Now create one database in MySQL using Character Set and Collation:</strong></p>
<pre class="crayon-plain-tag">CREATE DATABASE DatabaseName CHARACTER SET latin1 COLLATE latin1_swedish_ci;</pre> </p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbrnd.com/2015/10/database-theory-what-is-character-set-and-collation/feed/</wfw:commentRss>
			<slash:comments>7</slash:comments>
		
		
			</item>
	</channel>
</rss>
