<p>Après vous être familiarisé avec les conditions de requête de Yii2, utilisez Active
Record est très pratique pour interroger des données.
Ci-dessous, nous introduisons la méthode d'assemblage des conditions dans la méthode Where(). </p>
<h2 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">1 Syntaxe </h2>
<p style="white-space:pre-wrap;">Yii2 utilise la méthode <code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-built_in">where</span>()</code> (bien sûr, il existe d'autres méthodes) pour implémenter le filtrage conditionnel : </p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">public $this where ( $condition, $params = [] )</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;"><code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-variable" style="color:rgb(223,80,0);">$params</span></code> est un. paramètre facultatif, spécifiant la valeur à laquelle lier la requête. </p><p style="white-space:pre-wrap;"><code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-variable" style="color:rgb(223,80,0);">$condition</span></code> est un paramètre obligatoire, <code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-variable" style="color:rgb(223,80,0);">$condition</span></code> peut être une chaîne (telle que <code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-string" style="color:rgb(223,80,0);">'id=1'</span></code>) ou un tableau. Lorsque </p><p style="white-space:pre-wrap;"><code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-variable" style="color:rgb(223,80,0);">$condition</span></code> est un tableau, il existe deux formats : </p><ul style="margin-top:0px;list-style-position:inside;" class=" list-paddingleft-2"><li><p>Format de hachage : <code class="hljs json" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;white-space:pre-wrap;">['column1'
=> value1, 'column2' => value2, ...]</code></p></li><li><p> opération Format du symbole : <code class="hljs json" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;white-space:pre-wrap;">[operator,
operand1, operand2, ...]</code></p></li></ul><h2 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">2 Format de hachage </h2><p style="white-space:pre-wrap;"> Habituellement, la condition de requête au format de hachage génère une instruction SQL comme celle-ci : </p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">column1=value1 AND column2=value2 AND ...</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;">Si une valeur est un tableau, une instruction <code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">IN</code> est générée. </p><p style="white-space:pre-wrap;">Si une valeur est <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-literal" style="color:rgb(0,134,179);">null</span></code>, <code class="hljs cpp" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">IS<span class="hljs-literal" style="color:rgb(0,134,179);">NULL</span></code> sera utilisé pour générer la déclaration. </p><p style="white-space:pre-wrap;">Exemple : </p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['type' => 1, 'status' => 2]
// 生成:(type = 1) AND (status = 2)['id' => [1, 2, 3], 'status' => 2]
// 生成:(id IN (1, 2, 3)) AND (status = 2)['status' => null]
// 生成:status IS NULL</pre><div class="contentsignin">Copier après la connexion</div></div><h2 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3 Format d'opérateur </h2><p style="white-space:pre-wrap;">Au format d'opérateur, Yii générera des instructions SQL basées sur l'opérateur spécifié. </p>Les opérateurs <p style="white-space:pre-wrap;"> sont : <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">and</span></code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">or</span></code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span></code>, <code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">between</code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span>
between</code>, <code class="hljs bash" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">in</span></code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span><span class="hljs-keyword" style="color:rgb(167,29,93);">in</span></code>, <code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">like</code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">or</span>
like</code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span>
like</code>, <code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">or</span><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span> like</code> ,<code class="hljs perl" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">exists</span></code>,<code class="hljs perl" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">pas</span><span class="hljs-keyword" style="color:rgb(167,29,93);">existe</span></code>、<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">></code>、<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><</code>、<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">=</code>、<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">>=</code>、<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><=</code>、<code class="hljs diff" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-addition" style="color:rgb(85,165,50);background-color:rgb(234,255,234);">!=</span></code>等。</p><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.1 对比</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['>', 'id', 1]
// 生成:id > 1['<', 'id', 100]
// 生成:id < 100['=', 'id', 10]
// 生成:id = 10['>=', 'id', 1]
// 生成:id >= 1['<=', 'id', 100]
// 生成:id != 10</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;">具体生成的SQL语句,运算符<code class="hljs objectivec" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">id</span></code>会自动加上反斜杠引号<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">`</code>,运算数会自动转义。</p><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.2 and</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['and', 'id' => 1, 'id' => 2]
// 生成:id=1 AND id=2['and', 'id=1', 'id=2']
// 生成:id=1 AND id=2['and', 'type=1', ['or', 'id=1', 'id=2']]
// 生成:type=1 AND (id=1 OR id=2)</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;">在第2条和第3条语句中,列名称和搜索值未用键值关系指定,所以生成的SQL不会添加引号,也不会转义。</p><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.3 or</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['or', ['type' => [7, 8, 9]], ['id' => [1, 2, 3]]]
// 生成:(type IN (7, 8, 9) OR (id IN (1, 2, 3)))</pre><div class="contentsignin">Copier après la connexion</div></div><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.4 not</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['not', ['attribute' => null]]
// 生成:NOT (attribute IS NULL)</pre><div class="contentsignin">Copier après la connexion</div></div><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.5 between和not between</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['between', 'id', 1, 10]
// 生成:id BETWEEN 1 AND 10['not between', 'id', 1, 10]
// 生成:id NOT BETWEEN 1 AND 10</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;">运算符后面的运算数1为数据表<span style="font-weight:bolder;">列名称</span>,运算数2和运算数3分别为列值范围的<span style="font-weight:bolder;">最小值</span>和<span style="font-weight:bolder;">最大值</span>。</p><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.6 in和not in</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['in', 'id', [1, 2, 3]]
// 生成:id IN (1, 2, 3)['not in', 'id', [1, 2, 3]]
// 生成:id NOT IN (1, 2, 3)</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;">运算符后面的<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">运算数1</code>为列名称或DB表达式,<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">运算数2</code>为数组,指定列值所在的范围。</p><p style="white-space:pre-wrap;">这个方法会为值添加引号,并正确转义。</p><p style="white-space:pre-wrap;">要生成混合<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">IN</code>条件,列名和列值都设置为数组,并且用列名为列值指定下标:</p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="hljs php" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['in', ['id', 'name'], [['id' => 1, 'name' => 'foo'], ['id' => 2, 'name' => 'bar']]] // 生成:(`id`, `name`) IN ((1, 'foo'), (2, 'bar'))</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;">另外,还可以用子查询作为<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">IN</code>条件的值,如下:</p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['in', 'user_id', (new Query())->select('id')->from('users')->where(['active' => 1])]</pre><div class="contentsignin">Copier après la connexion</div></div><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.7 like</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['like', 'name', 'tester']
// 生成:name LIKE '%tester%'['like', 'name', ['test', 'sample']]
// 生成:name LIKE '%test%' AND name LIKE '%sample%'['like', 'name', '%tester', false]
// 生成:name LIKE '%tester'
// 这是自定义查询方式,要传入值为false的运算数3,并且自行添加%</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;"><span style="color:rgb(119,119,119);font-family:'courier new';"><span style="background-color:rgb(238,238,238);">运算数</span></span>后面的运算数1为列名称或DB表达式,运算数2为字符串或数组,指定列值查询条件。</p><p style="white-space:pre-wrap;">这个方法会为值添加引号,并正确转义。</p><p style="white-space:pre-wrap;"><code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">or</span>
like</code>、<code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span>
like</code>、<code class="hljs coffeescript" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">or</span><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span> like</code>用法和<code class="hljs" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;">like</code>一样。</p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['or like', 'name', ['test', 'sample']]
// 生成:name LIKE '%test%' OR name LIKE '%sample%'['not like', 'name', 'tester']
// 生成:name NOT LIKE '%tester%'['or not like', 'name', ['test', 'sample']]
// 生成:name NOT LIKE '%test%' OR name NOT LIKE '%sample%'</pre><div class="contentsignin">Copier après la connexion</div></div><h3 style="font-family:'Microsoft YaHei UI Light', SimHei, SimSun, sans-serif;line-height:1.1;color:rgb(66,139,209);">3.8 exists</h3><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false;" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;overflow:auto;color:rgb(51,51,51);background-color:rgb(247,247,247);padding:1em;line-height:1.65;">['exists', (new Query())->select('id')->from('users')->where(['active' => 1])]
// 生成:EXISTS (SELECT "id" FROM "users" WHERE "active"=1)</pre><div class="contentsignin">Copier après la connexion</div></div><p style="white-space:pre-wrap;"><code class="hljs perl" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">not</span><span class="hljs-keyword" style="color:rgb(167,29,93);">exists</span></code>用法和<code class="hljs perl" style="font-family:Consolas, 'Liberation Mono', Menlo, Courier, monospace;font-size:12px;padding:.3em;color:rgb(51,51,51);background-color:rgb(247,247,247);display:inline;line-height:1.65;"><span class="hljs-keyword" style="color:rgb(167,29,93);">exists</span></code>一样。</p>
<p style="white-space: pre-wrap;"> 相关推荐:</p>
<p style="white-space: pre-wrap;"><a href="http://www.php.cn/php-weizijiaocheng-330818.html" target="_self">Yii20中文开发向导——Where条件查询全解析</a></p>
Ce qui précède est le contenu détaillé de. pour plus d'informations, suivez d'autres articles connexes sur le site Web de PHP en chinois!