Skip to content

Commit d1f6003

Browse files
author
Eric Harmeling
committed
CREATE TABLE AS updates:
Parameter updates Diagram updates Examples now use MovR Code PRs: cockroachdb/cockroach#38589 cockroachdb/cockroach#38904 Fixes #5190
1 parent 060850c commit d1f6003

11 files changed

+2920
-2455
lines changed

_includes/v19.2/sql/aggregates.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,3 +154,4 @@
154154
<tr><td><code>xor_agg(arg1: <a href="int.html">int</a>) &rarr; <a href="int.html">int</a></code></td><td><span class="funcdesc"><p>Calculates the bitwise XOR of the selected values.</p>
155155
</span></td></tr></tbody>
156156
</table>
157+
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<div><svg width="371" height="113">
2+
<polygon points="9 33 1 29 1 37"></polygon>
3+
<polygon points="17 33 9 29 9 37"></polygon>
4+
<rect x="91" y="19" width="84" height="32" rx="10"></rect>
5+
<rect x="89" y="17" width="84" height="32" class="terminal" rx="10"></rect>
6+
<text class="terminal" x="99" y="37">PRIMARY</text>
7+
<rect x="195" y="19" width="46" height="32" rx="10"></rect>
8+
<rect x="193" y="17" width="46" height="32" class="terminal" rx="10"></rect>
9+
<text class="terminal" x="203" y="37">KEY</text>
10+
<rect x="91" y="63" width="72" height="32" rx="10"></rect>
11+
<rect x="89" y="61" width="72" height="32" class="terminal" rx="10"></rect>
12+
<text class="terminal" x="99" y="81">FAMILY</text><a xlink:href="sql-grammar.html#family_name" xlink:title="family_name">
13+
<rect x="183" y="63" width="100" height="32"></rect>
14+
<rect x="181" y="61" width="100" height="32" class="nonterminal"></rect>
15+
<text class="nonterminal" x="191" y="81">family_name</text></a><path class="line" d="m17 33 h2 m60 0 h10 m84 0 h10 m0 0 h10 m46 0 h10 m0 0 h42 m-232 0 h20 m212 0 h20 m-252 0 q10 0 10 10 m232 0 q0 -10 10 -10 m-242 10 v24 m232 0 v-24 m-232 24 q0 10 10 10 m212 0 q10 0 10 -10 m-222 10 h10 m72 0 h10 m0 0 h10 m100 0 h10 m-252 -44 l20 0 m-1 0 q-9 0 -9 -10 l0 -12 q0 -10 10 -10 m252 32 l20 0 m-20 0 q10 0 10 -10 l0 -12 q0 -10 -10 -10 m-252 0 h10 m0 0 h242 m-292 32 h20 m292 0 h20 m-332 0 q10 0 10 10 m312 0 q0 -10 10 -10 m-322 10 v58 m312 0 v-58 m-312 58 q0 10 10 10 m292 0 q10 0 10 -10 m-302 10 h10 m0 0 h282 m23 -78 h-3"></path>
16+
<polygon points="361 33 369 29 369 37"></polygon>
17+
<polygon points="361 33 353 29 353 37"></polygon></svg></div>
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<div><svg width="459" height="37">
2+
<polygon points="9 17 1 13 1 21"></polygon>
3+
<polygon points="17 17 9 13 9 21"></polygon>
4+
<rect x="31" y="3" width="84" height="32" rx="10"></rect>
5+
<rect x="29" y="1" width="84" height="32" class="terminal" rx="10"></rect>
6+
<text class="terminal" x="39" y="21">PRIMARY</text>
7+
<rect x="135" y="3" width="46" height="32" rx="10"></rect>
8+
<rect x="133" y="1" width="46" height="32" class="terminal" rx="10"></rect>
9+
<text class="terminal" x="143" y="21">KEY</text>
10+
<rect x="201" y="3" width="26" height="32" rx="10"></rect>
11+
<rect x="199" y="1" width="26" height="32" class="terminal" rx="10"></rect>
12+
<text class="terminal" x="209" y="21">(</text><a xlink:href="sql-grammar.html#create_as_params" xlink:title="create_as_params">
13+
<rect x="247" y="3" width="138" height="32"></rect>
14+
<rect x="245" y="1" width="138" height="32" class="nonterminal"></rect>
15+
<text class="nonterminal" x="255" y="21">create_as_params</text></a><rect x="405" y="3" width="26" height="32" rx="10"></rect>
16+
<rect x="403" y="1" width="26" height="32" class="terminal" rx="10"></rect>
17+
<text class="terminal" x="413" y="21">)</text>
18+
<path class="line" d="m17 17 h2 m0 0 h10 m84 0 h10 m0 0 h10 m46 0 h10 m0 0 h10 m26 0 h10 m0 0 h10 m138 0 h10 m0 0 h10 m26 0 h10 m3 0 h-3"></path>
19+
<polygon points="449 17 457 13 457 21"></polygon>
20+
<polygon points="449 17 441 13 441 21"></polygon></svg></div>
Lines changed: 48 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,48 @@
1-
<div><svg width="612" height="326">
2-
3-
<polygon points="9 17 1 13 1 21"></polygon>
4-
<polygon points="17 17 9 13 9 21"></polygon>
5-
<rect x="31" y="3" width="72" height="32" rx="10"></rect>
6-
<rect x="29" y="1" width="72" height="32" class="terminal" rx="10"></rect>
7-
<text class="terminal" x="39" y="21">CREATE</text>
8-
<rect x="123" y="3" width="62" height="32" rx="10"></rect>
9-
<rect x="121" y="1" width="62" height="32" class="terminal" rx="10"></rect>
10-
<text class="terminal" x="131" y="21">TABLE</text>
11-
<rect x="225" y="35" width="34" height="32" rx="10"></rect>
12-
<rect x="223" y="33" width="34" height="32" class="terminal" rx="10"></rect>
13-
<text class="terminal" x="233" y="53">IF</text>
14-
<rect x="279" y="35" width="48" height="32" rx="10"></rect>
15-
<rect x="277" y="33" width="48" height="32" class="terminal" rx="10"></rect>
16-
<text class="terminal" x="287" y="53">NOT</text>
17-
<rect x="347" y="35" width="68" height="32" rx="10"></rect>
18-
<rect x="345" y="33" width="68" height="32" class="terminal" rx="10"></rect>
19-
<text class="terminal" x="355" y="53">EXISTS</text>
20-
<a xlink:href="sql-grammar.html#table_name" xlink:title="table_name">
21-
<rect x="455" y="3" width="90" height="32"></rect>
22-
<rect x="453" y="1" width="90" height="32" class="nonterminal"></rect>
23-
<text class="nonterminal" x="463" y="21">table_name</text>
24-
</a>
25-
<rect x="565" y="3" width="26" height="32" rx="10"></rect>
26-
<rect x="563" y="1" width="26" height="32" class="terminal" rx="10"></rect>
27-
<text class="terminal" x="573" y="21">(</text>
28-
<a xlink:href="sql-grammar.html#column_def" xlink:title="column_def">
29-
<rect x="99" y="145" width="90" height="32"></rect>
30-
<rect x="97" y="143" width="90" height="32" class="nonterminal"></rect>
31-
<text class="nonterminal" x="107" y="163">column_def</text>
32-
</a>
33-
<a xlink:href="sql-grammar.html#index_def" xlink:title="index_def">
34-
<rect x="99" y="189" width="78" height="32"></rect>
35-
<rect x="97" y="187" width="78" height="32" class="nonterminal"></rect>
36-
<text class="nonterminal" x="107" y="207">index_def</text>
37-
</a>
38-
<a xlink:href="sql-grammar.html#family_def" xlink:title="family_def">
39-
<rect x="99" y="233" width="82" height="32"></rect>
40-
<rect x="97" y="231" width="82" height="32" class="nonterminal"></rect>
41-
<text class="nonterminal" x="107" y="251">family_def</text>
42-
</a>
43-
<a xlink:href="sql-grammar.html#table_constraint" xlink:title="table_constraint">
44-
<rect x="99" y="277" width="116" height="32"></rect>
45-
<rect x="97" y="275" width="116" height="32" class="nonterminal"></rect>
46-
<text class="nonterminal" x="107" y="295">table_constraint</text>
47-
</a>
48-
<rect x="79" y="101" width="24" height="32" rx="10"></rect>
49-
<rect x="77" y="99" width="24" height="32" class="terminal" rx="10"></rect>
50-
<text class="terminal" x="87" y="119">,</text>
51-
<rect x="295" y="145" width="26" height="32" rx="10"></rect>
52-
<rect x="293" y="143" width="26" height="32" class="terminal" rx="10"></rect>
53-
<text class="terminal" x="303" y="163">)</text>
54-
<a xlink:href="sql-grammar.html#opt_interleave" xlink:title="opt_interleave">
55-
<rect x="341" y="145" width="106" height="32"></rect>
56-
<rect x="339" y="143" width="106" height="32" class="nonterminal"></rect>
57-
<text class="nonterminal" x="349" y="163">opt_interleave</text>
58-
</a>
59-
<a xlink:href="sql-grammar.html#opt_partition_by" xlink:title="opt_partition_by">
60-
<rect x="467" y="145" width="118" height="32"></rect>
61-
<rect x="465" y="143" width="118" height="32" class="nonterminal"></rect>
62-
<text class="nonterminal" x="475" y="163">opt_partition_by</text>
63-
</a>
64-
<path class="line" d="m17 17 h2 m0 0 h10 m72 0 h10 m0 0 h10 m62 0 h10 m20 0 h10 m0 0 h200 m-230 0 h20 m210 0 h20 m-250 0 q10 0 10 10 m230 0 q0 -10 10 -10 m-240 10 v12 m230 0 v-12 m-230 12 q0 10 10 10 m210 0 q10 0 10 -10 m-220 10 h10 m34 0 h10 m0 0 h10 m48 0 h10 m0 0 h10 m68 0 h10 m20 -32 h10 m90 0 h10 m0 0 h10 m26 0 h10 m2 0 l2 0 m2 0 l2 0 m2 0 l2 0 m-596 142 l2 0 m2 0 l2 0 m2 0 l2 0 m62 0 h10 m90 0 h10 m0 0 h26 m-156 0 h20 m136 0 h20 m-176 0 q10 0 10 10 m156 0 q0 -10 10 -10 m-166 10 v24 m156 0 v-24 m-156 24 q0 10 10 10 m136 0 q10 0 10 -10 m-146 10 h10 m78 0 h10 m0 0 h38 m-146 -10 v20 m156 0 v-20 m-156 20 v24 m156 0 v-24 m-156 24 q0 10 10 10 m136 0 q10 0 10 -10 m-146 10 h10 m82 0 h10 m0 0 h34 m-146 -10 v20 m156 0 v-20 m-156 20 v24 m156 0 v-24 m-156 24 q0 10 10 10 m136 0 q10 0 10 -10 m-146 10 h10 m116 0 h10 m-176 -132 l20 0 m-1 0 q-9 0 -9 -10 l0 -24 q0 -10 10 -10 m176 44 l20 0 m-20 0 q10 0 10 -10 l0 -24 q0 -10 -10 -10 m-176 0 h10 m24 0 h10 m0 0 h132 m-216 44 h20 m216 0 h20 m-256 0 q10 0 10 10 m236 0 q0 -10 10 -10 m-246 10 v146 m236 0 v-146 m-236 146 q0 10 10 10 m216 0 q10 0 10 -10 m-226 10 h10 m0 0 h206 m20 -166 h10 m26 0 h10 m0 0 h10 m106 0 h10 m0 0 h10 m118 0 h10 m3 0 h-3"></path>
65-
<polygon points="603 159 611 155 611 163"></polygon>
66-
<polygon points="603 159 595 155 595 163"></polygon>
67-
</svg></div>
1+
<div><svg width="621" height="327">
2+
<polygon points="9 17 1 13 1 21"></polygon>
3+
<polygon points="17 17 9 13 9 21"></polygon>
4+
<rect x="31" y="3" width="72" height="32" rx="10"></rect>
5+
<rect x="29" y="1" width="72" height="32" class="terminal" rx="10"></rect>
6+
<text class="terminal" x="39" y="21">CREATE</text>
7+
<rect x="123" y="3" width="62" height="32" rx="10"></rect>
8+
<rect x="121" y="1" width="62" height="32" class="terminal" rx="10"></rect>
9+
<text class="terminal" x="131" y="21">TABLE</text>
10+
<rect x="225" y="35" width="34" height="32" rx="10"></rect>
11+
<rect x="223" y="33" width="34" height="32" class="terminal" rx="10"></rect>
12+
<text class="terminal" x="233" y="53">IF</text>
13+
<rect x="279" y="35" width="48" height="32" rx="10"></rect>
14+
<rect x="277" y="33" width="48" height="32" class="terminal" rx="10"></rect>
15+
<text class="terminal" x="287" y="53">NOT</text>
16+
<rect x="347" y="35" width="70" height="32" rx="10"></rect>
17+
<rect x="345" y="33" width="70" height="32" class="terminal" rx="10"></rect>
18+
<text class="terminal" x="355" y="53">EXISTS</text><a xlink:href="sql-grammar.html#table_name" xlink:title="table_name">
19+
<rect x="457" y="3" width="96" height="32"></rect>
20+
<rect x="455" y="1" width="96" height="32" class="nonterminal"></rect>
21+
<text class="nonterminal" x="465" y="21">table_name</text></a><rect x="573" y="3" width="26" height="32" rx="10"></rect>
22+
<rect x="571" y="1" width="26" height="32" class="terminal" rx="10"></rect>
23+
<text class="terminal" x="581" y="21">(</text><a xlink:href="sql-grammar.html#column_def" xlink:title="column_def">
24+
<rect x="85" y="145" width="92" height="32"></rect>
25+
<rect x="83" y="143" width="92" height="32" class="nonterminal"></rect>
26+
<text class="nonterminal" x="93" y="163">column_def</text></a><a xlink:href="sql-grammar.html#index_def" xlink:title="index_def">
27+
<rect x="85" y="189" width="82" height="32"></rect>
28+
<rect x="83" y="187" width="82" height="32" class="nonterminal"></rect>
29+
<text class="nonterminal" x="93" y="207">index_def</text></a><a xlink:href="sql-grammar.html#family_def" xlink:title="family_def">
30+
<rect x="85" y="233" width="86" height="32"></rect>
31+
<rect x="83" y="231" width="86" height="32" class="nonterminal"></rect>
32+
<text class="nonterminal" x="93" y="251">family_def</text></a><a xlink:href="sql-grammar.html#table_constraint" xlink:title="table_constraint">
33+
<rect x="85" y="277" width="124" height="32"></rect>
34+
<rect x="83" y="275" width="124" height="32" class="nonterminal"></rect>
35+
<text class="nonterminal" x="93" y="295">table_constraint</text></a><rect x="65" y="101" width="24" height="32" rx="10"></rect>
36+
<rect x="63" y="99" width="24" height="32" class="terminal" rx="10"></rect>
37+
<text class="terminal" x="73" y="119">,</text>
38+
<rect x="289" y="145" width="26" height="32" rx="10"></rect>
39+
<rect x="287" y="143" width="26" height="32" class="terminal" rx="10"></rect>
40+
<text class="terminal" x="297" y="163">)</text><a xlink:href="sql-grammar.html#opt_interleave" xlink:title="opt_interleave">
41+
<rect x="335" y="145" width="112" height="32"></rect>
42+
<rect x="333" y="143" width="112" height="32" class="nonterminal"></rect>
43+
<text class="nonterminal" x="343" y="163">opt_interleave</text></a><a xlink:href="sql-grammar.html#opt_partition_by" xlink:title="opt_partition_by">
44+
<rect x="467" y="145" width="126" height="32"></rect>
45+
<rect x="465" y="143" width="126" height="32" class="nonterminal"></rect>
46+
<text class="nonterminal" x="475" y="163">opt_partition_by</text></a><path class="line" d="m17 17 h2 m0 0 h10 m72 0 h10 m0 0 h10 m62 0 h10 m20 0 h10 m0 0 h202 m-232 0 h20 m212 0 h20 m-252 0 q10 0 10 10 m232 0 q0 -10 10 -10 m-242 10 v12 m232 0 v-12 m-232 12 q0 10 10 10 m212 0 q10 0 10 -10 m-222 10 h10 m34 0 h10 m0 0 h10 m48 0 h10 m0 0 h10 m70 0 h10 m20 -32 h10 m96 0 h10 m0 0 h10 m26 0 h10 m2 0 l2 0 m2 0 l2 0 m2 0 l2 0 m-618 142 l2 0 m2 0 l2 0 m2 0 l2 0 m62 0 h10 m92 0 h10 m0 0 h32 m-164 0 h20 m144 0 h20 m-184 0 q10 0 10 10 m164 0 q0 -10 10 -10 m-174 10 v24 m164 0 v-24 m-164 24 q0 10 10 10 m144 0 q10 0 10 -10 m-154 10 h10 m82 0 h10 m0 0 h42 m-154 -10 v20 m164 0 v-20 m-164 20 v24 m164 0 v-24 m-164 24 q0 10 10 10 m144 0 q10 0 10 -10 m-154 10 h10 m86 0 h10 m0 0 h38 m-154 -10 v20 m164 0 v-20 m-164 20 v24 m164 0 v-24 m-164 24 q0 10 10 10 m144 0 q10 0 10 -10 m-154 10 h10 m124 0 h10 m-184 -132 l20 0 m-1 0 q-9 0 -9 -10 l0 -24 q0 -10 10 -10 m184 44 l20 0 m-20 0 q10 0 10 -10 l0 -24 q0 -10 -10 -10 m-184 0 h10 m24 0 h10 m0 0 h140 m-224 44 h20 m224 0 h20 m-264 0 q10 0 10 10 m244 0 q0 -10 10 -10 m-254 10 v146 m244 0 v-146 m-244 146 q0 10 10 10 m224 0 q10 0 10 -10 m-234 10 h10 m0 0 h214 m20 -166 h10 m26 0 h10 m0 0 h10 m112 0 h10 m0 0 h10 m126 0 h10 m3 0 h-3"></path>
47+
<polygon points="611 159 619 155 619 163"></polygon>
48+
<polygon points="611 159 603 155 603 163"></polygon></svg></div>

0 commit comments

Comments
 (0)