<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>MySQL on Tutes Club</title><link>https://tutes.in/tag/mysql/</link><description>Recent content in MySQL on Tutes Club</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Fri, 08 Sep 2023 13:37:22 +0000</lastBuildDate><atom:link href="https://tutes.in/tag/mysql/index.xml" rel="self" type="application/rss+xml"/><item><title>How to speed up slow Magento indexer process? Maria DB 10.4</title><link>https://tutes.in/how-to-speed-up-slow-magento-indexer-process-maria-db-10-4/</link><pubDate>Fri, 08 Sep 2023 13:37:21 +0000</pubDate><guid>https://tutes.in/how-to-speed-up-slow-magento-indexer-process-maria-db-10-4/</guid><description>&lt;p&gt;Category Products index taking too much time?&lt;/p&gt;
&lt;p&gt;bin/magento index:reset&lt;/p&gt;
&lt;p&gt;bin/magento index:reindex&lt;/p&gt;
&lt;p&gt;Stuck at category products index …&lt;/p&gt;
&lt;p&gt;Here is the solution if you are using MariaDB 10.4&lt;/p&gt;
&lt;p&gt;You need to update options/parameters for your db. If using RDS, edit “DB instance parameter group” that you are using and update these 2 values:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;optimizer_switch=&amp;#39;rowid_filter=off&amp;#39;
optimizer_use_condition_selectivity = 1
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;After these changes, restart your database. In aws, RDS automatically updates these parameters without any downtime or requirement for restarting. You will see noticeable difference in indexer time.&lt;/p&gt;</description></item><item><title>How to export multiple selected tables in PMA phpmyadmin (but not all tables)</title><link>https://tutes.in/how-to-export-multiple-selected-tables-in-pma-phpmyadmin-but-not-all-tables/</link><pubDate>Tue, 25 May 2021 07:55:37 +0000</pubDate><guid>https://tutes.in/how-to-export-multiple-selected-tables-in-pma-phpmyadmin-but-not-all-tables/</guid><description>&lt;p&gt;Click on export, and choose “custom” export method.&lt;/p&gt;
&lt;p&gt;&lt;img loading="lazy" src="https://tutes.in/wp-content/uploads/2021/05/pma_export1.png"&gt;&lt;/p&gt;
&lt;p&gt;Lets say you want to export first 20 tables only.&lt;/p&gt;
&lt;p&gt;Open chrome or browser console &lt;em&gt;[ctrl+shift+j]&lt;/em&gt;, enter the following:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-javascript" data-lang="javascript"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="nx"&gt;$&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;input[name=&amp;#39;table_data[]&amp;#39;]&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;slice&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;20&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nx"&gt;click&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img loading="lazy" src="https://tutes.in/wp-content/uploads/2021/05/pma_export2.png.jpg"&gt;&lt;/p&gt;
&lt;p&gt;For next 20, use 20,50 as arguments in slice function used above.&lt;/p&gt;</description></item><item><title>How to solve MySQL server gone away error Maria Db update on cPanel and WHM?</title><link>https://tutes.in/how-to-solve-mysql-server-gone-away-error-maria-db-update-on-cpanel-and-whm/</link><pubDate>Wed, 06 Nov 2019 18:44:15 +0000</pubDate><guid>https://tutes.in/how-to-solve-mysql-server-gone-away-error-maria-db-update-on-cpanel-and-whm/</guid><description>&lt;p&gt;This is related to new MariaDb upgrade from 10.1.41 to 10.1.42 and also for servers which were updated from 10.2.27 to 10.2.28&lt;/p&gt;
&lt;p&gt;&lt;a href="#solution"&gt;Go to solution&lt;/a&gt; ( Special Thanks to &lt;a href="https://forums.cpanel.net/members/valetia.4402/"&gt;@Valetia&lt;/a&gt; )&lt;/p&gt;
&lt;p&gt;You will see errors in following formats/messages:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;No file or input found&lt;/li&gt;
&lt;li&gt;MySQL Server has gone away&lt;/li&gt;
&lt;li&gt;Connection to MySQL Server failed&lt;/li&gt;
&lt;li&gt;sqlstate[hy000]: general error: 2013 lost connection to mysql server during query&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;General error: 2006 MySQL server has gone away&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;ERROR 2006 (HY000): MySQL server has gone away&lt;/li&gt;
&lt;li&gt;ERROR 2013 (HY000): Lost connection to MySQL server during query&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Log files (/var/lib/mysql/$hostname.err) will have or can have any of these errors:&lt;/p&gt;</description></item><item><title>How to change attribute dropdown type to multi-select in Magento 2?</title><link>https://tutes.in/how-to-change-attribute-dropdown-type-to-multi-select-in-magento-2/</link><pubDate>Thu, 29 Aug 2019 01:32:22 +0000</pubDate><guid>https://tutes.in/how-to-change-attribute-dropdown-type-to-multi-select-in-magento-2/</guid><description>&lt;p&gt;Short Answer:&lt;/p&gt;
&lt;p&gt;Not possible via Magento2 Admin Backend.&lt;/p&gt;
&lt;p&gt;Solution:&lt;/p&gt;
&lt;p&gt;You need to update &lt;code&gt;eav_attribute&lt;/code&gt; table and edit information about backend_source, frontend_input etc.&lt;/p&gt;
&lt;p&gt;Simple query for that is:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sql" data-lang="sql"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;UPDATE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="n"&gt;eav_attribute&lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="n"&gt;backend_model&lt;/span&gt;&lt;span class="o"&gt;`=&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;Magento\\\Eav\\\Model\\\Entity\\\Attribute\\\Backend\\\ArrayBackend&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="n"&gt;backend_type&lt;/span&gt;&lt;span class="o"&gt;`=&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;varchar&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="n"&gt;frontend_input&lt;/span&gt;&lt;span class="o"&gt;`=&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;multiselect&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="n"&gt;source_model&lt;/span&gt;&lt;span class="o"&gt;`=&lt;/span&gt;&lt;span class="k"&gt;NULL&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;WHERE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;`&lt;/span&gt;&lt;span class="n"&gt;attribute_id&lt;/span&gt;&lt;span class="o"&gt;`=&lt;/span&gt;&lt;span class="n"&gt;YOUR_ATTRIBUTE_ID_INTEGER&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;LIMIT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Replace &lt;strong&gt;&lt;code&gt;YOUR_ATTRIBUTE_ID_INTEGER&lt;/code&gt;&lt;/strong&gt; with your &lt;em&gt;&lt;code&gt;attribute_id&lt;/code&gt;&lt;/em&gt; like &lt;strong&gt;&lt;code&gt;355&lt;/code&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id="reference"&gt;Reference:&lt;/h3&gt;
&lt;p&gt;&lt;a href="https://stackoverflow.com/a/57701845/2229148"&gt;https://stackoverflow.com/a/57701845/2229148&lt;/a&gt;&lt;/p&gt;</description></item><item><title>How to wipe all the tables and data in MySQL? Clean whole database</title><link>https://tutes.in/how-to-wipe-all-the-tables-and-data-in-mysql-clean-whole-database/</link><pubDate>Sat, 03 Aug 2019 18:10:33 +0000</pubDate><guid>https://tutes.in/how-to-wipe-all-the-tables-and-data-in-mysql-clean-whole-database/</guid><description>&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sql" data-lang="sql"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;FOREIGN_KEY_CHECKS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;GROUP_CONCAT_MAX_LEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;32768&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;GROUP_CONCAT&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;`&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;table_name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;`&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;INTO&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;information_schema&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;WHERE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;table_schema&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;DATABASE&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;IFNULL&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;dummy&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;INTO&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;CONCAT&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;DROP TABLE IF EXISTS &amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;PREPARE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;stmt&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;EXECUTE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;stmt&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;DEALLOCATE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;PREPARE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;stmt&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;FOREIGN_KEY_CHECKS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Will not work via phpmyadmin or any script. this has to be run in cmd/terminal&lt;/p&gt;
&lt;p&gt;Quick Command&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;wget https://gist.githubusercontent.com/harshvardhanmalpani/e670a8de7aa81673364dd48f125cb9ac/raw/ce04b319bf1594d148d3346e1474119fe1cd1b3f/flushdb.sql
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;mysql -hYOUR_DATABASE_HOSTNAME -uYOUR_DATABASE_USER -p YOUR_DATABASE_NAME &amp;lt; flushdb.sql
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;*&lt;em&gt;Source:*&lt;/em&gt; &lt;a href="https://gist.github.com/harshvardhanmalpani/e670a8de7aa81673364dd48f125cb9ac"&gt;https://gist.github.com/harshvardhanmalpani/e670a8de7aa81673364dd48f125cb9ac&lt;/a&gt;&lt;/p&gt;</description></item><item><title>How to reverse the ids in a mysql table column without breaking primary key constraint?</title><link>https://tutes.in/how-to-reverse-the-ids-in-a-mysql-table-column-without-breaking-primary-key-constraint/</link><pubDate>Sat, 01 Jun 2019 20:13:25 +0000</pubDate><guid>https://tutes.in/how-to-reverse-the-ids-in-a-mysql-table-column-without-breaking-primary-key-constraint/</guid><description>&lt;p&gt;Let me explain the problem scenario: Let us assume we have a table with 4 columns in it out of which 1 is &lt;code&gt;PRIMARY&lt;/code&gt; column and rest 3 contain some data.&lt;/p&gt;
&lt;p&gt;What we want to do is to reverse the primary key IDs for that data keeping the rest of data intact. It is like shifting the first row to end and moving last row to starting.&lt;/p&gt;
&lt;h2 id="initial-data"&gt;Initial Data&lt;/h2&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;em&gt;id&lt;/em&gt;&lt;/th&gt;
&lt;th&gt;&lt;em&gt;name&lt;/em&gt;&lt;/th&gt;
&lt;th&gt;&lt;em&gt;email&lt;/em&gt;&lt;/th&gt;
&lt;th&gt;&lt;em&gt;anything&lt;/em&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;jacob&lt;/td&gt;
&lt;td&gt;whatever&lt;/td&gt;
&lt;td&gt;how to reverse&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;3&lt;/td&gt;
&lt;td&gt;nathan&lt;/td&gt;
&lt;td&gt;whosoeverisnathan&lt;/td&gt;
&lt;td&gt;ids in mysql table column&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;4&lt;/td&gt;
&lt;td&gt;jagmohan&lt;/td&gt;
&lt;td&gt;idontknowjagmohan&lt;/td&gt;
&lt;td&gt;without breaking&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;8&lt;/td&gt;
&lt;td&gt;monica&lt;/td&gt;
&lt;td&gt;iamsexy&lt;/td&gt;
&lt;td&gt;primary key constraint&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;batman&lt;/td&gt;
&lt;td&gt;idontexistinrealworld&lt;/td&gt;
&lt;td&gt;i am batman&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id="data-after-update"&gt;Data after update&lt;/h2&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;em&gt;id&lt;/em&gt;&lt;/th&gt;
&lt;th&gt;&lt;em&gt;name&lt;/em&gt;&lt;/th&gt;
&lt;th&gt;&lt;em&gt;email&lt;/em&gt;&lt;/th&gt;
&lt;th&gt;&lt;em&gt;anything&lt;/em&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;9&lt;/td&gt;
&lt;td&gt;jacob&lt;/td&gt;
&lt;td&gt;whatever&lt;/td&gt;
&lt;td&gt;how to reverse&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;8&lt;/td&gt;
&lt;td&gt;nathan&lt;/td&gt;
&lt;td&gt;whosoeverisnathan&lt;/td&gt;
&lt;td&gt;ids in mysql table column&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;4&lt;/td&gt;
&lt;td&gt;jagmohan&lt;/td&gt;
&lt;td&gt;idontknowjagmohan&lt;/td&gt;
&lt;td&gt;without breaking&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;3&lt;/td&gt;
&lt;td&gt;monica&lt;/td&gt;
&lt;td&gt;iamsexy&lt;/td&gt;
&lt;td&gt;primary key constraint&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;batman&lt;/td&gt;
&lt;td&gt;idontexistinrealworld&lt;/td&gt;
&lt;td&gt;i am batman&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id="dude-you-are-just-reversing-the-column-what-is-so-tough-in-this"&gt;Dude, you are just reversing the column, what is so tough in this?&lt;/h2&gt;
&lt;p&gt;So, this seems simple to reverse an array if isolated by key “&lt;em&gt;id&lt;/em&gt;“. But you have to understand that this column is the primary key. So if you run a command to change id for “&lt;em&gt;jacob&lt;/em&gt;” to “&lt;em&gt;&lt;strong&gt;9&lt;/strong&gt;&lt;/em&gt;“. It will give you error: “&lt;code&gt;Duplicate entry for id 9&lt;/code&gt;“&lt;/p&gt;</description></item><item><title>Some of the most important SQL commands.</title><link>https://tutes.in/some-of-the-most-important-sql-commands/</link><pubDate>Thu, 24 Jan 2019 10:47:53 +0000</pubDate><guid>https://tutes.in/some-of-the-most-important-sql-commands/</guid><description>These are the most commonly used SQL commands. This article will walk you through each of them with the example. Read Here.</description></item><item><title>Creating a table in PhpMyAdmin Xampp server.</title><link>https://tutes.in/creating-a-table-in-phpmyadmin-xampp-server/</link><pubDate>Wed, 16 Jan 2019 05:12:30 +0000</pubDate><guid>https://tutes.in/creating-a-table-in-phpmyadmin-xampp-server/</guid><description>This is how you can create a table in phpmyadmin xampp server for your php project. Create database and table in phpmyadmin xampp server.</description></item><item><title>Connection timeout with MySQL database.</title><link>https://tutes.in/mysql-timeout/</link><pubDate>Tue, 08 Jan 2019 07:27:09 +0000</pubDate><guid>https://tutes.in/mysql-timeout/</guid><description>MySQL timeout error. See here hot to solve this issue.</description></item><item><title>How to repair a MySQL database?</title><link>https://tutes.in/how-to-repair-a-mysql-database/</link><pubDate>Tue, 30 Oct 2018 08:20:31 +0000</pubDate><guid>https://tutes.in/how-to-repair-a-mysql-database/</guid><description>Repair the MySQL database through Linux or Windows both covered in this article.</description></item><item><title>How to remove all tables from MySQL Database?</title><link>https://tutes.in/how-to-remove-all-tables-from-mysql-database/</link><pubDate>Fri, 19 Oct 2018 22:25:03 +0000</pubDate><guid>https://tutes.in/how-to-remove-all-tables-from-mysql-database/</guid><description>&lt;p&gt;Connect to your mysql host and select the database to be used&lt;br&gt;
example: &lt;code&gt;use notfavoritedb;&lt;/code&gt; where notfavoritedb is your database name, and then enter the sql commands given below:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sql" data-lang="sql"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;FOREIGN_KEY_CHECKS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;GROUP_CONCAT_MAX_LEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;32768&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;NULL&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;GROUP_CONCAT&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;`&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;table_name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;`&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;INTO&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;information_schema&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;WHERE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;table_schema&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;DATABASE&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SELECT&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;IFNULL&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;dummy&amp;#39;&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;INTO&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;CONCAT&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;&amp;#39;DROP TABLE IF EXISTS &amp;#39;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;PREPARE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;stmt&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;@&lt;/span&gt;&lt;span class="n"&gt;tables&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;EXECUTE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;stmt&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;DEALLOCATE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="k"&gt;PREPARE&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;stmt&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="k"&gt;SET&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;FOREIGN_KEY_CHECKS&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="n"&gt;exit&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Reference: &lt;a href="https://stackoverflow.com/questions/12403662/how-to-remove-all-mysql-tables-from-the-command-line-without-drop-database-permi/18625545#18625545" title="go to original answer on stackoverflow.com"&gt;StackOverflow&lt;/a&gt;&lt;/p&gt;</description></item><item><title>[Forgot Password] [Can’t Log In] How to reset WordPress admin password without sending reset email?</title><link>https://tutes.in/forgot-password-cant-log-in-how-to-reset-wordpress-admin-password-without-sending-reset-email/</link><pubDate>Thu, 20 Sep 2018 10:31:42 +0000</pubDate><guid>https://tutes.in/forgot-password-cant-log-in-how-to-reset-wordpress-admin-password-without-sending-reset-email/</guid><description>&lt;p&gt;So, admit it. We put really strong passwords and then we forget them.&lt;br&gt;
And you end up being locked out of your own website.&lt;/p&gt;
&lt;p&gt;So here is how you can reset it quickly.&lt;br&gt;
Go to your hosting control panel and then go to phpMyAdmin if available.&lt;/p&gt;
&lt;p&gt;Look into the database which is being used for your wordpress installation and click on &lt;mark&gt;Users&lt;/mark&gt; table&lt;br&gt;
&lt;a href="https://tutes.in/wp-content/uploads/2018/09/user-table-in-db.png"&gt;&lt;img loading="lazy" src="https://tutes.in/wp-content/uploads/2018/09/user-table-in-db-1024x679.png"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Inside users table, find the row responsible for your admin account. (check the user_nicename column for username match)&lt;br&gt;
and Press edit.&lt;br&gt;
&lt;a href="https://tutes.in/wp-content/uploads/2018/09/inside-user-table.png"&gt;&lt;img loading="lazy" src="https://tutes.in/wp-content/uploads/2018/09/inside-user-table-1024x593.png"&gt;&lt;/a&gt;&lt;/p&gt;</description></item><item><title>MySQL error 1449: The user specified as a definer does not exist</title><link>https://tutes.in/mysql-error-1449-the-user-specified-as-a-definer-does-not-exist/</link><pubDate>Sat, 28 Jul 2018 12:05:17 +0000</pubDate><guid>https://tutes.in/mysql-error-1449-the-user-specified-as-a-definer-does-not-exist/</guid><description>&lt;p&gt;Why this error happens?&lt;/p&gt;
&lt;p&gt;Most of the times, reason is that your database dump through command line or PhpMyAdmin or even other libraries can have SQL’s Definer statements. Now, as per &lt;a href="https://dev.mysql.com/doc/en/create-procedure.html"&gt;MySQL’s Official Documentation&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;The &lt;code&gt;DEFINER&lt;/code&gt; clause specifies the MySQL account to be used when checking access privileges at routine execution time for routines that have the &lt;code&gt;SQL SECURITY DEFINER&lt;/code&gt; characteristic.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://dev.mysql.com/doc/refman/8.0/en/create-procedure.html"&gt;MySQL Reference Manual v8.0&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id="solution-mysql-mysqldump-create-a-safe-backup-to-ensure-no-corruption"&gt;Solution: MySQL mysqldump create a safe backup to ensure no corruption&lt;/h2&gt;
&lt;p&gt;Use the following command to create backup of your mysql database. Put the command in terminal&lt;/p&gt;</description></item><item><title>How to tweak Magento 2 for two letter search in fulltext mode</title><link>https://tutes.in/how-to-tweak-magento-2-for-two-letter-search-in-fulltext-mode/</link><pubDate>Fri, 02 Mar 2018 00:19:16 +0000</pubDate><guid>https://tutes.in/how-to-tweak-magento-2-for-two-letter-search-in-fulltext-mode/</guid><description>&lt;h2 id="the-problem"&gt;The problem:&lt;/h2&gt;
&lt;p&gt;Magento 2 wont return any search results if the search token is 2 letters in length.&lt;/p&gt;
&lt;h2 id="solution"&gt;Solution:&lt;/h2&gt;
&lt;p&gt;Alter MySQL conf file. Edit my.cnf file on your server&lt;br&gt;
In CentOS, use command&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;nano /etc/my.cnf
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;and add the following lines:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-text" data-lang="text"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;ft_min_word_len=2
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;innodb_ft_min_token_size=2
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Save using &lt;kbd&gt;CTRL+x&lt;/kbd&gt; and then restart mysqld service.&lt;br&gt;
Now we need to regenerate the index in order to get updated search results. Use the following SQL commands to regenerate:&lt;/p&gt;</description></item><item><title>How to find rows which exist in new table but not in old table – MySQL</title><link>https://tutes.in/how-to-find-rows-which-exist-in-new-table-but-not-in-old-table-mysql/</link><pubDate>Sat, 18 Nov 2017 01:59:16 +0000</pubDate><guid>https://tutes.in/how-to-find-rows-which-exist-in-new-table-but-not-in-old-table-mysql/</guid><description>&lt;p&gt;SQL Query:&lt;br&gt;
&lt;code&gt;\ SELECT t1.stone FROM newatt t1 LEFT JOIN att t2 ON t2.stone = t1.stone WHERE t2.stone IS NULL\&lt;/code&gt;&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;newatt = new table (contains updated extra rows)
att = old table
stone = column name on both tables
&lt;/code&gt;&lt;/pre&gt;</description></item><item><title>Insert Indian States in Magento Database</title><link>https://tutes.in/insert-indian-states-in-magento-database/</link><pubDate>Wed, 01 Nov 2017 12:31:57 +0000</pubDate><guid>https://tutes.in/insert-indian-states-in-magento-database/</guid><description>&lt;p&gt;Connect to your server’s database using mysql cli or phpmyadmin and use the following query&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;INSERT INTO `directory_country_region` VALUES
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;AP&amp;#34;,&amp;#34;Andhra Pradesh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;AR&amp;#34;,&amp;#34;Arunachal Pradesh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;AS&amp;#34;,&amp;#34;Assam&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;BR&amp;#34;,&amp;#34;Bihar&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;CG&amp;#34;,&amp;#34;Chhattisgarh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;GA&amp;#34;,&amp;#34;Goa&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;GJ&amp;#34;,&amp;#34;Gujarat&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;HR&amp;#34;,&amp;#34;Haryana&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;HP&amp;#34;,&amp;#34;Himachal Pradesh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;JK&amp;#34;,&amp;#34;Jammu and Kashmir&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;JH&amp;#34;,&amp;#34;Jharkhand&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;KA&amp;#34;,&amp;#34;Karnataka&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;KL&amp;#34;,&amp;#34;Kerala&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;MP&amp;#34;,&amp;#34;Madhya Pradesh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;MH&amp;#34;,&amp;#34;Maharashtra&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;MN&amp;#34;,&amp;#34;Manipur&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;ML&amp;#34;,&amp;#34;Meghalaya&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;MZ&amp;#34;,&amp;#34;Mizoram&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;NL&amp;#34;,&amp;#34;Nagaland&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;OD&amp;#34;,&amp;#34;Odisha&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;PB&amp;#34;,&amp;#34;Punjab&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;RJ&amp;#34;,&amp;#34;Rajasthan&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;SK&amp;#34;,&amp;#34;Sikkim&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;TN&amp;#34;,&amp;#34;Tamil Nadu&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;TL&amp;#34;,&amp;#34;Telangana&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;TR&amp;#34;,&amp;#34;Tripura&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;UK&amp;#34;,&amp;#34;Uttarakhand&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;UP&amp;#34;,&amp;#34;Uttar Pradesh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;WB&amp;#34;,&amp;#34;West Bengal&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;AN&amp;#34;,&amp;#34;Andaman and Nicobar Islands&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;CH&amp;#34;,&amp;#34;Chandigarh&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;DH&amp;#34;,&amp;#34;Dadra and Nagar Haveli&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;DD&amp;#34;,&amp;#34;Daman and Diu&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;DL&amp;#34;,&amp;#34;Delhi&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;LD&amp;#34;,&amp;#34;Lakshadweep&amp;#34;),
(NULL,&amp;#34;IN&amp;#34;,&amp;#34;PY&amp;#34;,&amp;#34;Puducherry&amp;#34;);
&lt;/code&gt;&lt;/pre&gt;</description></item><item><title>Inserting into SQL without specifying primary column</title><link>https://tutes.in/inserting-into-sql-without-specifying-primary-column/</link><pubDate>Tue, 14 Mar 2017 09:52:06 +0000</pubDate><guid>https://tutes.in/inserting-into-sql-without-specifying-primary-column/</guid><description>&lt;p&gt;If Primary key is set to Auto-increment, there are chances that you would not want to provide its value in insert query.&lt;/p&gt;
&lt;p&gt;Here is how to do it in MySQL:&lt;br&gt;
&lt;code&gt;INSERT INTO table_name VALUES (NULL, 'column b', 'col c');&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Assumption^: The first column is the primary key set to AI&lt;br&gt;
&lt;br&gt;
Similarly you can skip columns for other non-required data:&lt;br&gt;
&lt;code&gt;INSERT INTO table_name(col b,col c) VALUES ('column b', 'col c');&lt;/code&gt;&lt;/p&gt;</description></item></channel></rss>