<p>Never used <code>JOIN</code>s before, so can someone tell me if I’m doing this right?</p>
<p><code>SELECT wcmsVertices.*, wcmsDiffs.modifer, wcmsDiffs.mtime, wcmsDiffs.reason FROM wcmsVertices RIGHT JOIN wcmsDiffs USING (id) WHERE wcmsVerticies.id = ‘$vertex’ ORDER BY wcmsDiffs DESC LIMIT 1;</code></p>
<p>I want to select everything from wcmsVertices and the three specified fields from wcmsDiffs where the ‘id’ fields are both equal to $vertex. If there’s more than one Diff, though, I want to only grab the most recent one</p>