<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1048662" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1048662</link>
    <description></description>
    <language>en</language>
          <item>
    <title>Comment Removed</title>
    <link>https://www.webmaster-forums.net/web-programming-and-application-development/post-removed-0#comment-1259741</link>
    <description> &lt;p&gt;Comment Removed&lt;/p&gt;
 </description>
     <pubDate>Sat, 03 Apr 2021 11:11:13 +0000</pubDate>
 <dc:creator>shaunno2009</dc:creator>
 <guid isPermaLink="false">comment 1259741 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>Every subquery needs an alias</title>
    <link>https://www.webmaster-forums.net/web-programming-and-application-development/post-removed-0#comment-1259753</link>
    <description> &lt;p&gt;Every subquery needs an alias (or name). That &quot;k&quot; is just what I decided to call the subquery.&lt;/p&gt;
&lt;p&gt;If you wanted to reference a specific column from that subquery, you would do something like:&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;SELECT &lt;br /&gt;&amp;nbsp; k.user_id,&amp;nbsp; # I am referencing a column from the subquery here&lt;br /&gt;&amp;nbsp; k.username&lt;br /&gt;FROM &lt;br /&gt;&amp;nbsp; (SELECT * FROM users ORDER BY points DESC LIMIT 3, 50) k &lt;br /&gt;ORDER BY &lt;br /&gt;&amp;nbsp; RAND()&lt;/code&gt;&lt;/div&gt;&lt;br /&gt;
If you had two columns named user_id (when you joined with another table), the k would resolve the ambiguity.&lt;/p&gt;
 </description>
     <pubDate>Tue, 04 Jan 2011 00:08:32 +0000</pubDate>
 <dc:creator>teammatt3</dc:creator>
 <guid isPermaLink="false">comment 1259753 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>Use a subquery:
SELECT * FROM</title>
    <link>https://www.webmaster-forums.net/web-programming-and-application-development/post-removed-0#comment-1259738</link>
    <description> &lt;p&gt;Use a subquery:&lt;/p&gt;
&lt;p&gt;&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;SELECT * FROM (SELECT * FROM users ORDER BY points DESC LIMIT 3, 50) k ORDER BY RAND()&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;
 </description>
     <pubDate>Mon, 03 Jan 2011 18:30:15 +0000</pubDate>
 <dc:creator>teammatt3</dc:creator>
 <guid isPermaLink="false">comment 1259738 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
