<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://script.spoken-tutorial.org/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=PostgreSQL-Database%2FC2%2FData-Redundancy-and-Primary-Key%2FEnglish</id>
		<title>PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=PostgreSQL-Database%2FC2%2FData-Redundancy-and-Primary-Key%2FEnglish"/>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;action=history"/>
		<updated>2026-04-03T21:41:24Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.23.17</generator>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;diff=57431&amp;oldid=prev</id>
		<title>Madhurig at 08:43, 9 February 2026</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;diff=57431&amp;oldid=prev"/>
				<updated>2026-02-09T08:43:27Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 08:43, 9 February 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 121:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 121:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Right-click on the students table.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Right-click on the students table.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Let me right click on the '''students''' table.A '''context menu '''opens.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Let me right click on the '''students''' table.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;A '''context menu '''opens.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Select '''Drop'''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Select '''Drop'''&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 128:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 130:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Drop Table pop up box appears with a message.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Drop Table pop up box appears with a message.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Click the red colored '''Drop button. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Click the red colored '''Drop button&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;'''&lt;/ins&gt;. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;'''&lt;/del&gt;Notice that the table structure along with its data is deleted.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Notice that the table structure along with its data is deleted.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| '''DROP TABLE tablename; '''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| '''DROP TABLE tablename; '''&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;''Add annotation'''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;''Add annotation'''&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| The syntax to delete a table is '''DROP TABLE tablename semicolon&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;.&lt;/del&gt;'''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| The syntax to delete a table is '''DROP TABLE tablename semicolon'''&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;||&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;||&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 170:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 172:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Cursor on green notification:'''The students table is created&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Cursor on green notification:'''The students table is created&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;successfully'''.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;successfully'''.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Let us execute this query.The students table is created successfully.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Let us execute this query.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The students table is created successfully.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;||&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;||&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Point to the table.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Now let us insert data into this table.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Now let us insert data into this table.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 183:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 187:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;'''('S103','Pooja','Pune','Female','1995-03-25',9.2);'''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;'''('S103','Pooja','Pune','Female','1995-03-25',9.2);'''&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Let me type the following code in the &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;query &lt;/del&gt;window.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|| Let me type the following code in the &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;'''Query''' &lt;/ins&gt;window.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|- &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Madhurig</name></author>	</entry>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;diff=57430&amp;oldid=prev</id>
		<title>Madhurig at 07:35, 9 February 2026</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;diff=57430&amp;oldid=prev"/>
				<updated>2026-02-09T07:35:36Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;a href=&quot;https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;amp;diff=57430&amp;amp;oldid=57429&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Madhurig</name></author>	</entry>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;diff=57429&amp;oldid=prev</id>
		<title>Ketkinaina: Created page with &quot;'''Title of the Script: Data Redundancy and Primary Key'''  '''Author''': '''EduPyramids'''  '''Keywords''':''' Data redundancy, Query Tool,''' '''use a''' '''primary key, DRO...&quot;</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=PostgreSQL-Database/C2/Data-Redundancy-and-Primary-Key/English&amp;diff=57429&amp;oldid=prev"/>
				<updated>2026-02-07T04:44:37Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;&amp;#039;&amp;#039;&amp;#039;Title of the Script: Data Redundancy and Primary Key&amp;#039;&amp;#039;&amp;#039;  &amp;#039;&amp;#039;&amp;#039;Author&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;&amp;#039;EduPyramids&amp;#039;&amp;#039;&amp;#039;  &amp;#039;&amp;#039;&amp;#039;Keywords&amp;#039;&amp;#039;&amp;#039;:&amp;#039;&amp;#039;&amp;#039; Data redundancy, Query Tool,&amp;#039;&amp;#039;&amp;#039; &amp;#039;&amp;#039;&amp;#039;use a&amp;#039;&amp;#039;&amp;#039; &amp;#039;&amp;#039;&amp;#039;primary key, DRO...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;'''Title of the Script: Data Redundancy and Primary Key'''&lt;br /&gt;
&lt;br /&gt;
'''Author''': '''EduPyramids'''&lt;br /&gt;
&lt;br /&gt;
'''Keywords''':''' Data redundancy, Query Tool,''' '''use a''' '''primary key, DROP TABLE, EduPyramids,&lt;br /&gt;
Video Tutorial.'''&lt;br /&gt;
&lt;br /&gt;
{| border=1&lt;br /&gt;
|- &lt;br /&gt;
|| '''Visual Cue'''&lt;br /&gt;
|| '''Narration'''&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 1 Title Slide'''&lt;br /&gt;
|| Welcome to the Spoken Tutorial on '''Data Redundancy and Primary Key'''.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 2 Learning Objectives '''&lt;br /&gt;
|| In this tutorial, we will learn about,&lt;br /&gt;
*Data redundancy&lt;br /&gt;
*Why data redundancy is a problem&lt;br /&gt;
*Primary keys, and &lt;br /&gt;
*How to create a table with a primary key.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 3 System Requirements '''&lt;br /&gt;
|| To record this tutorial, I am using, * '''Ubuntu&lt;br /&gt;
24.04''' LTS&lt;br /&gt;
* '''PostgreSQL version 18.1''' and &lt;br /&gt;
* '''pgAdmin 4 version 9.11'''.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 4 Pre-requisites '''&lt;br /&gt;
'''https://EduPyramids.org'''&lt;br /&gt;
|| To follow this tutorial, * Learners should have&lt;br /&gt;
'''PostgreSQL''' and '''pgAdmin 4''' installed in their systems.&lt;br /&gt;
&lt;br /&gt;
For the pre-requisite '''PostgreSQL''' tutorials, please visit this website.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 5 Code Files '''&lt;br /&gt;
drp-codes.txt&lt;br /&gt;
|| The following code file is required to practice this tutorial.&lt;br /&gt;
This file is provided in the Code Files link of this tutorial page.&lt;br /&gt;
|- &lt;br /&gt;
|| Open '''pgAdmin 4'''&lt;br /&gt;
&lt;br /&gt;
|| Let us open '''pgAdmin 4'''.&lt;br /&gt;
|- &lt;br /&gt;
|| Click on '''localhost''' node.&lt;br /&gt;
|| Please ensure that '''Localhost''' '''PostgreSQL '''server is connected.&lt;br /&gt;
|- &lt;br /&gt;
|| Click '''students''' table&lt;br /&gt;
|| Now let’s click on the '''students''' table.&lt;br /&gt;
|- &lt;br /&gt;
|| Right click on students tableSelect '''Query Tool'''. Cursor on '''Query''' Editor.&lt;br /&gt;
|| I will right click on the '''students''' table and select the '''Query Tool'''.&lt;br /&gt;
The '''Query''' Editor window opens on the right side.&lt;br /&gt;
|- &lt;br /&gt;
|| Type '''SELECT * FROM students;'''&lt;br /&gt;
&lt;br /&gt;
'''Show SQL'''&lt;br /&gt;
|| Let us retrieve the data from the '''students''' table.&lt;br /&gt;
Type '''SELECT space asterisk space FROM space students semicolon'''.&lt;br /&gt;
|- &lt;br /&gt;
|| Click '''Execute query '''button.&lt;br /&gt;
Looks like a play button.Highlight the output.&lt;br /&gt;
|| Click on the '''Execute''' '''query '''button on the tool bar.The output is displayed in tabular format.&lt;br /&gt;
|- &lt;br /&gt;
|| Point to duplicate names&lt;br /&gt;
|| We can see that student names such as '''Ram''' or '''Kishore''' appear more than once.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 6 Data Redundancy'''&lt;br /&gt;
|| Data redundancy means duplication of data in a database table.&lt;br /&gt;
It increases storage usage, causes data inconsistency and affects database performance.&lt;br /&gt;
|- &lt;br /&gt;
||&lt;br /&gt;
|| To prevent data redundancy, we use a '''primary key'''.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide7 What is a Primary Key?'''&lt;br /&gt;
|| A primary key is a column or a set of columns that uniquely identifies each row in a table.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 8 Rules of Primary Key'''&lt;br /&gt;
|| A table can have only one primary key, and its values must be unique and not null.Student name cannot&lt;br /&gt;
be a primary key as multiple students can have the same name.&lt;br /&gt;
|- &lt;br /&gt;
|| '''pgAdmin 4 cursor on Columns'''&lt;br /&gt;
|| Therefore, we will create a new column called '''studentid''' and make it as the primary key.&lt;br /&gt;
|- &lt;br /&gt;
|| '''pgAdmin 4'''&lt;br /&gt;
|| First, we must delete the existing students table.&lt;br /&gt;
|- &lt;br /&gt;
|| Right-click on the students table.&lt;br /&gt;
|| Let me right click on the '''students''' table.A '''context menu '''opens.&lt;br /&gt;
|- &lt;br /&gt;
|| Select '''Drop'''&lt;br /&gt;
|| I will select the '''Drop''' option.&lt;br /&gt;
&lt;br /&gt;
Drop Table pop up box appears with a message.Click the red colored '''Drop button. '''Notice that the table&lt;br /&gt;
structure along with its data is deleted.&lt;br /&gt;
|- &lt;br /&gt;
|| '''DROP TABLE tablename; Add annotation'''&lt;br /&gt;
|| The syntax to delete a table is '''DROP TABLE tablename semicolon.'''&lt;br /&gt;
|- &lt;br /&gt;
||&lt;br /&gt;
|| Let us create the '''students''' table with a primary key.&lt;br /&gt;
|- &lt;br /&gt;
|| Open Right-click on the Tables and select '''Query Tool'''&lt;br /&gt;
|| Now let us open the '''Query Tool'''.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Show SQLType CREATE TABLE students ('''&lt;br /&gt;
'''studentid VARCHAR(10),'''&lt;br /&gt;
'''studentname VARCHAR(50),'''&lt;br /&gt;
'''city VARCHAR(40),'''&lt;br /&gt;
'''gender VARCHAR(10),'''&lt;br /&gt;
'''dob DATE,'''&lt;br /&gt;
'''cgpa NUMERIC(2,1),'''&lt;br /&gt;
'''PRIMARY KEY (studentid)'''&lt;br /&gt;
''');'''&lt;br /&gt;
|| Let me type the following code in the query window.&lt;br /&gt;
|- &lt;br /&gt;
|| Highlight '''studentid'''&lt;br /&gt;
|| Here, '''studentid''' is defined as the primary key.&lt;br /&gt;
|- &lt;br /&gt;
|| Click on the '''Execute''' '''query button'''.Cursor on green notification:'''The students table is created&lt;br /&gt;
successfully'''.&lt;br /&gt;
|| Let us execute this query.The students table is created successfully.&lt;br /&gt;
|- &lt;br /&gt;
||&lt;br /&gt;
|| Now let us insert data into this table.&lt;br /&gt;
|- &lt;br /&gt;
|| Type: '''INSERT INTO students VALUES'''&lt;br /&gt;
'''('S101','Ram','Mumbai','Male','1996-10-23',9.6),'''&lt;br /&gt;
'''('S102','Kishore','Mumbai','Male','1996-08-09',8.5),'''&lt;br /&gt;
'''('S103','Pooja','Pune','Female','1995-03-25',9.2);'''&lt;br /&gt;
|| Let me type the following code in the query window.&lt;br /&gt;
&lt;br /&gt;
|- &lt;br /&gt;
|| Click on the '''Execute''' '''query''' button.Show the notifications.&lt;br /&gt;
|| Click on the '''Execute query''' button to execute the code.The records are inserted successfully.&lt;br /&gt;
|- &lt;br /&gt;
|| Click on the '''Execute''' '''query '''button.&lt;br /&gt;
&lt;br /&gt;
|| Let us insert the same data again.&lt;br /&gt;
For that, execute the '''INSERT''' statement once more.&lt;br /&gt;
|- &lt;br /&gt;
|| Point to error&lt;br /&gt;
|| We get an error message saying '''duplicate key value violates unique constraint'''.&lt;br /&gt;
|- &lt;br /&gt;
|| Point to the error.&lt;br /&gt;
|| This error occurs because the primary key does not allow duplicate values.Now, let us retrieve the data&lt;br /&gt;
again.&lt;br /&gt;
|- &lt;br /&gt;
|| Type:''' SELECT * FROM students;''' Click on the '''Execute '''button.&lt;br /&gt;
&lt;br /&gt;
Show the Output.&lt;br /&gt;
|| Let me type '''SELECT asterisk FROM students semicolon'''.Execute the following command.Notice that&lt;br /&gt;
there is no duplication of data in the table.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 9 Summary'''&lt;br /&gt;
In this tutorial, we will learn about,* Data&lt;br /&gt;
redundancy &lt;br /&gt;
* Why data redundancy is a problem&lt;br /&gt;
* Primary keys, and &lt;br /&gt;
* How to create a table with a primary key.&lt;br /&gt;
&lt;br /&gt;
|| With this we come to the end of this tutorial.Let us summarise.&lt;br /&gt;
|- &lt;br /&gt;
|| * '''Slide 10 As an Assignment,'''&lt;br /&gt;
* Drop the '''Emp''' table&lt;br /&gt;
* Create it again with '''empno''' as the primary&lt;br /&gt;
key&lt;br /&gt;
* Insert a few records and retrieve the data.&lt;br /&gt;
&lt;br /&gt;
|| As an assignment, please do the following.&lt;br /&gt;
|- &lt;br /&gt;
|| '''Slide 11 Thank You '''&lt;br /&gt;
|| This Spoken Tutorial is brought to you by '''EduPyramids''' educational services private limited SINE IIT&lt;br /&gt;
Bombay.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Ketkinaina</name></author>	</entry>

	</feed>