SQL优化 MySQL版

SQL优化 MySQL版 - 避免索引失效原则(一)

					<div> 
														 StanleyBlogs															
														 2024-10-13 15:26:02 

				</div>
									<pre>select * from book where authroid = 1 and typeid = 2;</pre><pre>explain select * from book where authroid = 1 and typeid*2 = 2;</pre><pre>explain select * from book where authroid*2 = 1 and typeid*2 = 2;</pre><pre>select * from book where authroid*2 = 1 and typeid = 2;</pre><pre>select * from book where authoid = 1 and typeid = 2</pre><pre>explain  select * from book where authoid ! = 1 and typeid = 2</pre><pre>explain  select * from book where authoid ! = 1 and typeid ! = 2;</pre>


														<div>