You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2165 lines
56 KiB

Improved testing of ssl and compression - Added show status variable "compression" for checking that compression is turned on. - Updated show status variable "have_openssl" to be set to DISABLED if server supports ssl but it's not turned on to accept incoming ssl connections. - Setup server to accept ssl connections from clients ig that is supported by server - New tests - ssl - Run with ssl turned on - ssl_compress - Run with ssl and compression turned on - compress - Run with compression turned in - Updated test - openssl_1, rpl_openssl1 - Changed to run if server supports ssl BitKeeper/deleted/.del-have_openssl_1.inc~55590efedeec9ee0: Delete: mysql-test/include/have_openssl_1.inc BitKeeper/deleted/.del-have_openssl_1.require~e8cdeb0adba99ac5: Delete: mysql-test/r/have_openssl_1.require client/mysqltest.c: Add commands to enable/disable ssl for the follwing connect's Add commands to enable/disable compression for the following connect's mysql-test/mysql-test-run.pl: Test if ssl is supported by the server If ssl is supported by the server, start server with ability to accept ssl connections from clients Cleanup check of supported features check_ssl_support, check_ndbcluster_support Flags and helptext for mysl-test-run.pl updated --ssl, turn on ssl encryption between server and client --skip-ssl, don'r turn on ssl or setup ssl even if it's supported --with-openssl, deprecated, synonym with --ssl mysql-test/r/openssl_1.result: Update test results mysql-test/t/openssl_1.test: Run this if server reports it has support for ssl Enable ssl before connecting Check that ssl encryption has been turned on mysql-test/t/rpl_openssl.test: Run this if server reports it supports ssl sql-common/client.c: Add DBUG_PRINT's sql/mysqld.cc: If server can't accept ssl connection set have_openssl to SHOW_OPTION_DISABLED Add status variable to show if connection with server is using compressed protocol sql/sql_show.cc: Add status variable to show if connection with server is using compressed protocol sql/structs.h: Add status variable to show if connection with server is using compressed protocol mysql-test/r/compress.result: New BitKeeper file ``mysql-test/r/compress.result'' mysql-test/r/ssl.result: New BitKeeper file ``mysql-test/r/ssl.result'' mysql-test/r/ssl_compress.result: New BitKeeper file ``mysql-test/r/ssl_compress.result'' mysql-test/t/compress.test: New BitKeeper file ``mysql-test/t/compress.test'' mysql-test/t/ssl.test: New BitKeeper file ``mysql-test/t/ssl.test'' mysql-test/t/ssl_compress.test: New BitKeeper file ``mysql-test/t/ssl_compress.test''
21 years ago
Improved testing of ssl and compression - Added show status variable "compression" for checking that compression is turned on. - Updated show status variable "have_openssl" to be set to DISABLED if server supports ssl but it's not turned on to accept incoming ssl connections. - Setup server to accept ssl connections from clients ig that is supported by server - New tests - ssl - Run with ssl turned on - ssl_compress - Run with ssl and compression turned on - compress - Run with compression turned in - Updated test - openssl_1, rpl_openssl1 - Changed to run if server supports ssl BitKeeper/deleted/.del-have_openssl_1.inc~55590efedeec9ee0: Delete: mysql-test/include/have_openssl_1.inc BitKeeper/deleted/.del-have_openssl_1.require~e8cdeb0adba99ac5: Delete: mysql-test/r/have_openssl_1.require client/mysqltest.c: Add commands to enable/disable ssl for the follwing connect's Add commands to enable/disable compression for the following connect's mysql-test/mysql-test-run.pl: Test if ssl is supported by the server If ssl is supported by the server, start server with ability to accept ssl connections from clients Cleanup check of supported features check_ssl_support, check_ndbcluster_support Flags and helptext for mysl-test-run.pl updated --ssl, turn on ssl encryption between server and client --skip-ssl, don'r turn on ssl or setup ssl even if it's supported --with-openssl, deprecated, synonym with --ssl mysql-test/r/openssl_1.result: Update test results mysql-test/t/openssl_1.test: Run this if server reports it has support for ssl Enable ssl before connecting Check that ssl encryption has been turned on mysql-test/t/rpl_openssl.test: Run this if server reports it supports ssl sql-common/client.c: Add DBUG_PRINT's sql/mysqld.cc: If server can't accept ssl connection set have_openssl to SHOW_OPTION_DISABLED Add status variable to show if connection with server is using compressed protocol sql/sql_show.cc: Add status variable to show if connection with server is using compressed protocol sql/structs.h: Add status variable to show if connection with server is using compressed protocol mysql-test/r/compress.result: New BitKeeper file ``mysql-test/r/compress.result'' mysql-test/r/ssl.result: New BitKeeper file ``mysql-test/r/ssl.result'' mysql-test/r/ssl_compress.result: New BitKeeper file ``mysql-test/r/ssl_compress.result'' mysql-test/t/compress.test: New BitKeeper file ``mysql-test/t/compress.test'' mysql-test/t/ssl.test: New BitKeeper file ``mysql-test/t/ssl.test'' mysql-test/t/ssl_compress.test: New BitKeeper file ``mysql-test/t/ssl_compress.test''
21 years ago
Improved testing of ssl and compression - Added show status variable "compression" for checking that compression is turned on. - Updated show status variable "have_openssl" to be set to DISABLED if server supports ssl but it's not turned on to accept incoming ssl connections. - Setup server to accept ssl connections from clients ig that is supported by server - New tests - ssl - Run with ssl turned on - ssl_compress - Run with ssl and compression turned on - compress - Run with compression turned in - Updated test - openssl_1, rpl_openssl1 - Changed to run if server supports ssl BitKeeper/deleted/.del-have_openssl_1.inc~55590efedeec9ee0: Delete: mysql-test/include/have_openssl_1.inc BitKeeper/deleted/.del-have_openssl_1.require~e8cdeb0adba99ac5: Delete: mysql-test/r/have_openssl_1.require client/mysqltest.c: Add commands to enable/disable ssl for the follwing connect's Add commands to enable/disable compression for the following connect's mysql-test/mysql-test-run.pl: Test if ssl is supported by the server If ssl is supported by the server, start server with ability to accept ssl connections from clients Cleanup check of supported features check_ssl_support, check_ndbcluster_support Flags and helptext for mysl-test-run.pl updated --ssl, turn on ssl encryption between server and client --skip-ssl, don'r turn on ssl or setup ssl even if it's supported --with-openssl, deprecated, synonym with --ssl mysql-test/r/openssl_1.result: Update test results mysql-test/t/openssl_1.test: Run this if server reports it has support for ssl Enable ssl before connecting Check that ssl encryption has been turned on mysql-test/t/rpl_openssl.test: Run this if server reports it supports ssl sql-common/client.c: Add DBUG_PRINT's sql/mysqld.cc: If server can't accept ssl connection set have_openssl to SHOW_OPTION_DISABLED Add status variable to show if connection with server is using compressed protocol sql/sql_show.cc: Add status variable to show if connection with server is using compressed protocol sql/structs.h: Add status variable to show if connection with server is using compressed protocol mysql-test/r/compress.result: New BitKeeper file ``mysql-test/r/compress.result'' mysql-test/r/ssl.result: New BitKeeper file ``mysql-test/r/ssl.result'' mysql-test/r/ssl_compress.result: New BitKeeper file ``mysql-test/r/ssl_compress.result'' mysql-test/t/compress.test: New BitKeeper file ``mysql-test/t/compress.test'' mysql-test/t/ssl.test: New BitKeeper file ``mysql-test/t/ssl.test'' mysql-test/t/ssl_compress.test: New BitKeeper file ``mysql-test/t/ssl_compress.test''
21 years ago
Improved testing of ssl and compression - Added show status variable "compression" for checking that compression is turned on. - Updated show status variable "have_openssl" to be set to DISABLED if server supports ssl but it's not turned on to accept incoming ssl connections. - Setup server to accept ssl connections from clients ig that is supported by server - New tests - ssl - Run with ssl turned on - ssl_compress - Run with ssl and compression turned on - compress - Run with compression turned in - Updated test - openssl_1, rpl_openssl1 - Changed to run if server supports ssl BitKeeper/deleted/.del-have_openssl_1.inc~55590efedeec9ee0: Delete: mysql-test/include/have_openssl_1.inc BitKeeper/deleted/.del-have_openssl_1.require~e8cdeb0adba99ac5: Delete: mysql-test/r/have_openssl_1.require client/mysqltest.c: Add commands to enable/disable ssl for the follwing connect's Add commands to enable/disable compression for the following connect's mysql-test/mysql-test-run.pl: Test if ssl is supported by the server If ssl is supported by the server, start server with ability to accept ssl connections from clients Cleanup check of supported features check_ssl_support, check_ndbcluster_support Flags and helptext for mysl-test-run.pl updated --ssl, turn on ssl encryption between server and client --skip-ssl, don'r turn on ssl or setup ssl even if it's supported --with-openssl, deprecated, synonym with --ssl mysql-test/r/openssl_1.result: Update test results mysql-test/t/openssl_1.test: Run this if server reports it has support for ssl Enable ssl before connecting Check that ssl encryption has been turned on mysql-test/t/rpl_openssl.test: Run this if server reports it supports ssl sql-common/client.c: Add DBUG_PRINT's sql/mysqld.cc: If server can't accept ssl connection set have_openssl to SHOW_OPTION_DISABLED Add status variable to show if connection with server is using compressed protocol sql/sql_show.cc: Add status variable to show if connection with server is using compressed protocol sql/structs.h: Add status variable to show if connection with server is using compressed protocol mysql-test/r/compress.result: New BitKeeper file ``mysql-test/r/compress.result'' mysql-test/r/ssl.result: New BitKeeper file ``mysql-test/r/ssl.result'' mysql-test/r/ssl_compress.result: New BitKeeper file ``mysql-test/r/ssl_compress.result'' mysql-test/t/compress.test: New BitKeeper file ``mysql-test/t/compress.test'' mysql-test/t/ssl.test: New BitKeeper file ``mysql-test/t/ssl.test'' mysql-test/t/ssl_compress.test: New BitKeeper file ``mysql-test/t/ssl_compress.test''
21 years ago
  1. SHOW STATUS LIKE 'Ssl_cipher';
  2. Variable_name Value
  3. Ssl_cipher DHE-RSA-AES256-SHA
  4. SHOW STATUS LIKE 'Compression';
  5. Variable_name Value
  6. Compression ON
  7. drop table if exists t1,t2,t3,t4;
  8. CREATE TABLE t1 (
  9. Period smallint(4) unsigned zerofill DEFAULT '0000' NOT NULL,
  10. Varor_period smallint(4) unsigned DEFAULT '0' NOT NULL
  11. );
  12. INSERT INTO t1 VALUES (9410,9412);
  13. select period from t1;
  14. period
  15. 9410
  16. select * from t1;
  17. Period Varor_period
  18. 9410 9412
  19. select t1.* from t1;
  20. Period Varor_period
  21. 9410 9412
  22. CREATE TABLE t2 (
  23. auto int not null auto_increment,
  24. fld1 int(6) unsigned zerofill DEFAULT '000000' NOT NULL,
  25. companynr tinyint(2) unsigned zerofill DEFAULT '00' NOT NULL,
  26. fld3 char(30) DEFAULT '' NOT NULL,
  27. fld4 char(35) DEFAULT '' NOT NULL,
  28. fld5 char(35) DEFAULT '' NOT NULL,
  29. fld6 char(4) DEFAULT '' NOT NULL,
  30. UNIQUE fld1 (fld1),
  31. KEY fld3 (fld3),
  32. PRIMARY KEY (auto)
  33. );
  34. select t2.fld3 from t2 where companynr = 58 and fld3 like "%imaginable%";
  35. fld3
  36. imaginable
  37. select fld3 from t2 where fld3 like "%cultivation" ;
  38. fld3
  39. cultivation
  40. select t2.fld3,companynr from t2 where companynr = 57+1 order by fld3;
  41. fld3 companynr
  42. concoct 58
  43. druggists 58
  44. engrossing 58
  45. Eurydice 58
  46. exclaimers 58
  47. ferociousness 58
  48. hopelessness 58
  49. Huey 58
  50. imaginable 58
  51. judges 58
  52. merging 58
  53. ostrich 58
  54. peering 58
  55. Phelps 58
  56. presumes 58
  57. Ruth 58
  58. sentences 58
  59. Shylock 58
  60. straggled 58
  61. synergy 58
  62. thanking 58
  63. tying 58
  64. unlocks 58
  65. select fld3,companynr from t2 where companynr = 58 order by fld3;
  66. fld3 companynr
  67. concoct 58
  68. druggists 58
  69. engrossing 58
  70. Eurydice 58
  71. exclaimers 58
  72. ferociousness 58
  73. hopelessness 58
  74. Huey 58
  75. imaginable 58
  76. judges 58
  77. merging 58
  78. ostrich 58
  79. peering 58
  80. Phelps 58
  81. presumes 58
  82. Ruth 58
  83. sentences 58
  84. Shylock 58
  85. straggled 58
  86. synergy 58
  87. thanking 58
  88. tying 58
  89. unlocks 58
  90. select fld3 from t2 order by fld3 desc limit 10;
  91. fld3
  92. youthfulness
  93. yelped
  94. Wotan
  95. workers
  96. Witt
  97. witchcraft
  98. Winsett
  99. Willy
  100. willed
  101. wildcats
  102. select fld3 from t2 order by fld3 desc limit 5;
  103. fld3
  104. youthfulness
  105. yelped
  106. Wotan
  107. workers
  108. Witt
  109. select fld3 from t2 order by fld3 desc limit 5,5;
  110. fld3
  111. witchcraft
  112. Winsett
  113. Willy
  114. willed
  115. wildcats
  116. select t2.fld3 from t2 where fld3 = 'honeysuckle';
  117. fld3
  118. honeysuckle
  119. select t2.fld3 from t2 where fld3 LIKE 'honeysuckl_';
  120. fld3
  121. honeysuckle
  122. select t2.fld3 from t2 where fld3 LIKE 'hon_ysuckl_';
  123. fld3
  124. honeysuckle
  125. select t2.fld3 from t2 where fld3 LIKE 'honeysuckle%';
  126. fld3
  127. honeysuckle
  128. select t2.fld3 from t2 where fld3 LIKE 'h%le';
  129. fld3
  130. honeysuckle
  131. select t2.fld3 from t2 where fld3 LIKE 'honeysuckle_';
  132. fld3
  133. select t2.fld3 from t2 where fld3 LIKE 'don_t_find_me_please%';
  134. fld3
  135. explain select t2.fld3 from t2 where fld3 = 'honeysuckle';
  136. id select_type table type possible_keys key key_len ref rows Extra
  137. 1 SIMPLE t2 ref fld3 fld3 30 const 1 Using where; Using index
  138. explain select fld3 from t2 ignore index (fld3) where fld3 = 'honeysuckle';
  139. id select_type table type possible_keys key key_len ref rows Extra
  140. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  141. explain select fld3 from t2 use index (fld1) where fld3 = 'honeysuckle';
  142. id select_type table type possible_keys key key_len ref rows Extra
  143. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  144. explain select fld3 from t2 use index (fld3) where fld3 = 'honeysuckle';
  145. id select_type table type possible_keys key key_len ref rows Extra
  146. 1 SIMPLE t2 ref fld3 fld3 30 const 1 Using where; Using index
  147. explain select fld3 from t2 use index (fld1,fld3) where fld3 = 'honeysuckle';
  148. id select_type table type possible_keys key key_len ref rows Extra
  149. 1 SIMPLE t2 ref fld3 fld3 30 const 1 Using where; Using index
  150. explain select fld3 from t2 ignore index (fld3,not_used);
  151. ERROR 42000: Key column 'not_used' doesn't exist in table
  152. explain select fld3 from t2 use index (not_used);
  153. ERROR 42000: Key column 'not_used' doesn't exist in table
  154. select t2.fld3 from t2 where fld3 >= 'honeysuckle' and fld3 <= 'honoring' order by fld3;
  155. fld3
  156. honeysuckle
  157. honoring
  158. explain select t2.fld3 from t2 where fld3 >= 'honeysuckle' and fld3 <= 'honoring' order by fld3;
  159. id select_type table type possible_keys key key_len ref rows Extra
  160. 1 SIMPLE t2 range fld3 fld3 30 NULL 2 Using where; Using index
  161. select fld1,fld3 from t2 where fld3="Colombo" or fld3 = "nondecreasing" order by fld3;
  162. fld1 fld3
  163. 148504 Colombo
  164. 068305 Colombo
  165. 000000 nondecreasing
  166. select fld1,fld3 from t2 where companynr = 37 and fld3 = 'appendixes';
  167. fld1 fld3
  168. 232605 appendixes
  169. 1232605 appendixes
  170. 1232606 appendixes
  171. 1232607 appendixes
  172. 1232608 appendixes
  173. 1232609 appendixes
  174. select fld1 from t2 where fld1=250501 or fld1="250502";
  175. fld1
  176. 250501
  177. 250502
  178. explain select fld1 from t2 where fld1=250501 or fld1="250502";
  179. id select_type table type possible_keys key key_len ref rows Extra
  180. 1 SIMPLE t2 range fld1 fld1 4 NULL 2 Using where; Using index
  181. select fld1 from t2 where fld1=250501 or fld1=250502 or fld1 >= 250505 and fld1 <= 250601 or fld1 between 250501 and 250502;
  182. fld1
  183. 250501
  184. 250502
  185. 250505
  186. 250601
  187. explain select fld1 from t2 where fld1=250501 or fld1=250502 or fld1 >= 250505 and fld1 <= 250601 or fld1 between 250501 and 250502;
  188. id select_type table type possible_keys key key_len ref rows Extra
  189. 1 SIMPLE t2 range fld1 fld1 4 NULL 4 Using where; Using index
  190. select fld1,fld3 from t2 where companynr = 37 and fld3 like 'f%';
  191. fld1 fld3
  192. 218401 faithful
  193. 018007 fanatic
  194. 228311 fated
  195. 018017 featherweight
  196. 218022 feed
  197. 088303 feminine
  198. 058004 Fenton
  199. 038017 fetched
  200. 018054 fetters
  201. 208101 fiftieth
  202. 238007 filial
  203. 013606 fingerings
  204. 218008 finishers
  205. 038205 firearm
  206. 188505 fitting
  207. 202301 Fitzpatrick
  208. 238008 fixedly
  209. 012001 flanking
  210. 018103 flint
  211. 018104 flopping
  212. 188007 flurried
  213. 013602 foldout
  214. 226205 foothill
  215. 232102 forgivably
  216. 228306 forthcoming
  217. 186002 freakish
  218. 208113 freest
  219. 231315 freezes
  220. 036002 funereal
  221. 226209 furnishings
  222. 198006 furthermore
  223. select fld3 from t2 where fld3 like "L%" and fld3 = "ok";
  224. fld3
  225. select fld3 from t2 where (fld3 like "C%" and fld3 = "Chantilly");
  226. fld3
  227. Chantilly
  228. select fld1,fld3 from t2 where fld1 like "25050%";
  229. fld1 fld3
  230. 250501 poisoning
  231. 250502 Iraqis
  232. 250503 heaving
  233. 250504 population
  234. 250505 bomb
  235. select fld1,fld3 from t2 where fld1 like "25050_";
  236. fld1 fld3
  237. 250501 poisoning
  238. 250502 Iraqis
  239. 250503 heaving
  240. 250504 population
  241. 250505 bomb
  242. select distinct companynr from t2;
  243. companynr
  244. 00
  245. 37
  246. 36
  247. 50
  248. 58
  249. 29
  250. 40
  251. 53
  252. 65
  253. 41
  254. 34
  255. 68
  256. select distinct companynr from t2 order by companynr;
  257. companynr
  258. 00
  259. 29
  260. 34
  261. 36
  262. 37
  263. 40
  264. 41
  265. 50
  266. 53
  267. 58
  268. 65
  269. 68
  270. select distinct companynr from t2 order by companynr desc;
  271. companynr
  272. 68
  273. 65
  274. 58
  275. 53
  276. 50
  277. 41
  278. 40
  279. 37
  280. 36
  281. 34
  282. 29
  283. 00
  284. select distinct t2.fld3,period from t2,t1 where companynr=37 and fld3 like "O%";
  285. fld3 period
  286. obliterates 9410
  287. offload 9410
  288. opaquely 9410
  289. organizer 9410
  290. overestimating 9410
  291. overlay 9410
  292. select distinct fld3 from t2 where companynr = 34 order by fld3;
  293. fld3
  294. absentee
  295. accessed
  296. ahead
  297. alphabetic
  298. Asiaticizations
  299. attitude
  300. aye
  301. bankruptcies
  302. belays
  303. Blythe
  304. bomb
  305. boulevard
  306. bulldozes
  307. cannot
  308. caressing
  309. charcoal
  310. checksumming
  311. chess
  312. clubroom
  313. colorful
  314. cosy
  315. creator
  316. crying
  317. Darius
  318. diffusing
  319. duality
  320. Eiffel
  321. Epiphany
  322. Ernestine
  323. explorers
  324. exterminated
  325. famine
  326. forked
  327. Gershwins
  328. heaving
  329. Hodges
  330. Iraqis
  331. Italianization
  332. Lagos
  333. landslide
  334. libretto
  335. Majorca
  336. mastering
  337. narrowed
  338. occurred
  339. offerers
  340. Palestine
  341. Peruvianizes
  342. pharmaceutic
  343. poisoning
  344. population
  345. Pygmalion
  346. rats
  347. realest
  348. recording
  349. regimented
  350. retransmitting
  351. reviver
  352. rouses
  353. scars
  354. sicker
  355. sleepwalk
  356. stopped
  357. sugars
  358. translatable
  359. uncles
  360. unexpected
  361. uprisings
  362. versatility
  363. vest
  364. select distinct fld3 from t2 limit 10;
  365. fld3
  366. abates
  367. abiding
  368. Abraham
  369. abrogating
  370. absentee
  371. abut
  372. accessed
  373. accruing
  374. accumulating
  375. accuracies
  376. select distinct fld3 from t2 having fld3 like "A%" limit 10;
  377. fld3
  378. abates
  379. abiding
  380. Abraham
  381. abrogating
  382. absentee
  383. abut
  384. accessed
  385. accruing
  386. accumulating
  387. accuracies
  388. select distinct substring(fld3,1,3) from t2 where fld3 like "A%";
  389. substring(fld3,1,3)
  390. aba
  391. abi
  392. Abr
  393. abs
  394. abu
  395. acc
  396. acq
  397. acu
  398. Ade
  399. adj
  400. Adl
  401. adm
  402. Ado
  403. ads
  404. adv
  405. aer
  406. aff
  407. afi
  408. afl
  409. afo
  410. agi
  411. ahe
  412. aim
  413. air
  414. Ald
  415. alg
  416. ali
  417. all
  418. alp
  419. alr
  420. ama
  421. ame
  422. amm
  423. ana
  424. and
  425. ane
  426. Ang
  427. ani
  428. Ann
  429. Ant
  430. api
  431. app
  432. aqu
  433. Ara
  434. arc
  435. Arm
  436. arr
  437. Art
  438. Asi
  439. ask
  440. asp
  441. ass
  442. ast
  443. att
  444. aud
  445. Aug
  446. aut
  447. ave
  448. avo
  449. awe
  450. aye
  451. Azt
  452. select distinct substring(fld3,1,3) as a from t2 having a like "A%" order by a limit 10;
  453. a
  454. aba
  455. abi
  456. Abr
  457. abs
  458. abu
  459. acc
  460. acq
  461. acu
  462. Ade
  463. adj
  464. select distinct substring(fld3,1,3) from t2 where fld3 like "A%" limit 10;
  465. substring(fld3,1,3)
  466. aba
  467. abi
  468. Abr
  469. abs
  470. abu
  471. acc
  472. acq
  473. acu
  474. Ade
  475. adj
  476. select distinct substring(fld3,1,3) as a from t2 having a like "A%" limit 10;
  477. a
  478. aba
  479. abi
  480. Abr
  481. abs
  482. abu
  483. acc
  484. acq
  485. acu
  486. Ade
  487. adj
  488. create table t3 (
  489. period int not null,
  490. name char(32) not null,
  491. companynr int not null,
  492. price double(11,0),
  493. price2 double(11,0),
  494. key (period),
  495. key (name)
  496. );
  497. create temporary table tmp engine = myisam select * from t3;
  498. insert into t3 select * from tmp;
  499. insert into tmp select * from t3;
  500. insert into t3 select * from tmp;
  501. insert into tmp select * from t3;
  502. insert into t3 select * from tmp;
  503. insert into tmp select * from t3;
  504. insert into t3 select * from tmp;
  505. insert into tmp select * from t3;
  506. insert into t3 select * from tmp;
  507. insert into tmp select * from t3;
  508. insert into t3 select * from tmp;
  509. insert into tmp select * from t3;
  510. insert into t3 select * from tmp;
  511. insert into tmp select * from t3;
  512. insert into t3 select * from tmp;
  513. insert into tmp select * from t3;
  514. insert into t3 select * from tmp;
  515. alter table t3 add t2nr int not null auto_increment primary key first;
  516. drop table tmp;
  517. SET SQL_BIG_TABLES=1;
  518. select distinct concat(fld3," ",fld3) as namn from t2,t3 where t2.fld1=t3.t2nr order by namn limit 10;
  519. namn
  520. Abraham Abraham
  521. abrogating abrogating
  522. admonishing admonishing
  523. Adolph Adolph
  524. afield afield
  525. aging aging
  526. ammonium ammonium
  527. analyzable analyzable
  528. animals animals
  529. animized animized
  530. SET SQL_BIG_TABLES=0;
  531. select distinct concat(fld3," ",fld3) from t2,t3 where t2.fld1=t3.t2nr order by fld3 limit 10;
  532. concat(fld3," ",fld3)
  533. Abraham Abraham
  534. abrogating abrogating
  535. admonishing admonishing
  536. Adolph Adolph
  537. afield afield
  538. aging aging
  539. ammonium ammonium
  540. analyzable analyzable
  541. animals animals
  542. animized animized
  543. select distinct fld5 from t2 limit 10;
  544. fld5
  545. neat
  546. Steinberg
  547. jarring
  548. tinily
  549. balled
  550. persist
  551. attainments
  552. fanatic
  553. measures
  554. rightfulness
  555. select distinct fld3,count(*) from t2 group by companynr,fld3 limit 10;
  556. fld3 count(*)
  557. affixed 1
  558. and 1
  559. annoyers 1
  560. Anthony 1
  561. assayed 1
  562. assurers 1
  563. attendants 1
  564. bedlam 1
  565. bedpost 1
  566. boasted 1
  567. SET SQL_BIG_TABLES=1;
  568. select distinct fld3,count(*) from t2 group by companynr,fld3 limit 10;
  569. fld3 count(*)
  570. affixed 1
  571. and 1
  572. annoyers 1
  573. Anthony 1
  574. assayed 1
  575. assurers 1
  576. attendants 1
  577. bedlam 1
  578. bedpost 1
  579. boasted 1
  580. SET SQL_BIG_TABLES=0;
  581. select distinct fld3,repeat("a",length(fld3)),count(*) from t2 group by companynr,fld3 limit 100,10;
  582. fld3 repeat("a",length(fld3)) count(*)
  583. circus aaaaaa 1
  584. cited aaaaa 1
  585. Colombo aaaaaaa 1
  586. congresswoman aaaaaaaaaaaaa 1
  587. contrition aaaaaaaaaa 1
  588. corny aaaaa 1
  589. cultivation aaaaaaaaaaa 1
  590. definiteness aaaaaaaaaaaa 1
  591. demultiplex aaaaaaaaaaa 1
  592. disappointing aaaaaaaaaaaaa 1
  593. select distinct companynr,rtrim(space(512+companynr)) from t3 order by 1,2;
  594. companynr rtrim(space(512+companynr))
  595. 37
  596. 78
  597. 101
  598. 154
  599. 311
  600. 447
  601. 512
  602. select distinct fld3 from t2,t3 where t2.companynr = 34 and t2.fld1=t3.t2nr order by fld3;
  603. fld3
  604. explain select t3.t2nr,fld3 from t2,t3 where t2.companynr = 34 and t2.fld1=t3.t2nr order by t3.t2nr,fld3;
  605. id select_type table type possible_keys key key_len ref rows Extra
  606. 1 SIMPLE t2 ALL fld1 NULL NULL NULL 1199 Using where; Using temporary; Using filesort
  607. 1 SIMPLE t3 eq_ref PRIMARY PRIMARY 4 test.t2.fld1 1 Using where; Using index
  608. explain select * from t3 as t1,t3 where t1.period=t3.period order by t3.period;
  609. id select_type table type possible_keys key key_len ref rows Extra
  610. 1 SIMPLE t1 ALL period NULL NULL NULL 41810 Using temporary; Using filesort
  611. 1 SIMPLE t3 ref period period 4 test.t1.period 4181
  612. explain select * from t3 as t1,t3 where t1.period=t3.period order by t3.period limit 10;
  613. id select_type table type possible_keys key key_len ref rows Extra
  614. 1 SIMPLE t3 index period period 4 NULL 41810
  615. 1 SIMPLE t1 ref period period 4 test.t3.period 4181
  616. explain select * from t3 as t1,t3 where t1.period=t3.period order by t1.period limit 10;
  617. id select_type table type possible_keys key key_len ref rows Extra
  618. 1 SIMPLE t1 index period period 4 NULL 41810
  619. 1 SIMPLE t3 ref period period 4 test.t1.period 4181
  620. select period from t1;
  621. period
  622. 9410
  623. select period from t1 where period=1900;
  624. period
  625. select fld3,period from t1,t2 where fld1 = 011401 order by period;
  626. fld3 period
  627. breaking 9410
  628. select fld3,period from t2,t3 where t2.fld1 = 011401 and t2.fld1=t3.t2nr and t3.period=1001;
  629. fld3 period
  630. breaking 1001
  631. explain select fld3,period from t2,t3 where t2.fld1 = 011401 and t3.t2nr=t2.fld1 and 1001 = t3.period;
  632. id select_type table type possible_keys key key_len ref rows Extra
  633. 1 SIMPLE t2 const fld1 fld1 4 const 1
  634. 1 SIMPLE t3 const PRIMARY,period PRIMARY 4 const 1
  635. select fld3,period from t2,t1 where companynr*10 = 37*10;
  636. fld3 period
  637. breaking 9410
  638. Romans 9410
  639. intercepted 9410
  640. bewilderingly 9410
  641. astound 9410
  642. admonishing 9410
  643. sumac 9410
  644. flanking 9410
  645. combed 9410
  646. subjective 9410
  647. scatterbrain 9410
  648. Eulerian 9410
  649. Kane 9410
  650. overlay 9410
  651. perturb 9410
  652. goblins 9410
  653. annihilates 9410
  654. Wotan 9410
  655. snatching 9410
  656. concludes 9410
  657. laterally 9410
  658. yelped 9410
  659. grazing 9410
  660. Baird 9410
  661. celery 9410
  662. misunderstander 9410
  663. handgun 9410
  664. foldout 9410
  665. mystic 9410
  666. succumbed 9410
  667. Nabisco 9410
  668. fingerings 9410
  669. aging 9410
  670. afield 9410
  671. ammonium 9410
  672. boat 9410
  673. intelligibility 9410
  674. Augustine 9410
  675. teethe 9410
  676. dreaded 9410
  677. scholastics 9410
  678. audiology 9410
  679. wallet 9410
  680. parters 9410
  681. eschew 9410
  682. quitter 9410
  683. neat 9410
  684. Steinberg 9410
  685. jarring 9410
  686. tinily 9410
  687. balled 9410
  688. persist 9410
  689. attainments 9410
  690. fanatic 9410
  691. measures 9410
  692. rightfulness 9410
  693. capably 9410
  694. impulsive 9410
  695. starlet 9410
  696. terminators 9410
  697. untying 9410
  698. announces 9410
  699. featherweight 9410
  700. pessimist 9410
  701. daughter 9410
  702. decliner 9410
  703. lawgiver 9410
  704. stated 9410
  705. readable 9410
  706. attrition 9410
  707. cascade 9410
  708. motors 9410
  709. interrogate 9410
  710. pests 9410
  711. stairway 9410
  712. dopers 9410
  713. testicle 9410
  714. Parsifal 9410
  715. leavings 9410
  716. postulation 9410
  717. squeaking 9410
  718. contrasted 9410
  719. leftover 9410
  720. whiteners 9410
  721. erases 9410
  722. Punjab 9410
  723. Merritt 9410
  724. Quixotism 9410
  725. sweetish 9410
  726. dogging 9410
  727. scornfully 9410
  728. bellow 9410
  729. bills 9410
  730. cupboard 9410
  731. sureties 9410
  732. puddings 9410
  733. fetters 9410
  734. bivalves 9410
  735. incurring 9410
  736. Adolph 9410
  737. pithed 9410
  738. Miles 9410
  739. trimmings 9410
  740. tragedies 9410
  741. skulking 9410
  742. flint 9410
  743. flopping 9410
  744. relaxing 9410
  745. offload 9410
  746. suites 9410
  747. lists 9410
  748. animized 9410
  749. multilayer 9410
  750. standardizes 9410
  751. Judas 9410
  752. vacuuming 9410
  753. dentally 9410
  754. humanness 9410
  755. inch 9410
  756. Weissmuller 9410
  757. irresponsibly 9410
  758. luckily 9410
  759. culled 9410
  760. medical 9410
  761. bloodbath 9410
  762. subschema 9410
  763. animals 9410
  764. Micronesia 9410
  765. repetitions 9410
  766. Antares 9410
  767. ventilate 9410
  768. pityingly 9410
  769. interdependent 9410
  770. Graves 9410
  771. neonatal 9410
  772. chafe 9410
  773. honoring 9410
  774. realtor 9410
  775. elite 9410
  776. funereal 9410
  777. abrogating 9410
  778. sorters 9410
  779. Conley 9410
  780. lectured 9410
  781. Abraham 9410
  782. Hawaii 9410
  783. cage 9410
  784. hushes 9410
  785. Simla 9410
  786. reporters 9410
  787. Dutchman 9410
  788. descendants 9410
  789. groupings 9410
  790. dissociate 9410
  791. coexist 9410
  792. Beebe 9410
  793. Taoism 9410
  794. Connally 9410
  795. fetched 9410
  796. checkpoints 9410
  797. rusting 9410
  798. galling 9410
  799. obliterates 9410
  800. traitor 9410
  801. resumes 9410
  802. analyzable 9410
  803. terminator 9410
  804. gritty 9410
  805. firearm 9410
  806. minima 9410
  807. Selfridge 9410
  808. disable 9410
  809. witchcraft 9410
  810. betroth 9410
  811. Manhattanize 9410
  812. imprint 9410
  813. peeked 9410
  814. swelling 9410
  815. interrelationships 9410
  816. riser 9410
  817. Gandhian 9410
  818. peacock 9410
  819. bee 9410
  820. kanji 9410
  821. dental 9410
  822. scarf 9410
  823. chasm 9410
  824. insolence 9410
  825. syndicate 9410
  826. alike 9410
  827. imperial 9410
  828. convulsion 9410
  829. railway 9410
  830. validate 9410
  831. normalizes 9410
  832. comprehensive 9410
  833. chewing 9410
  834. denizen 9410
  835. schemer 9410
  836. chronicle 9410
  837. Kline 9410
  838. Anatole 9410
  839. partridges 9410
  840. brunch 9410
  841. recruited 9410
  842. dimensions 9410
  843. Chicana 9410
  844. announced 9410
  845. praised 9410
  846. employing 9410
  847. linear 9410
  848. quagmire 9410
  849. western 9410
  850. relishing 9410
  851. serving 9410
  852. scheduling 9410
  853. lore 9410
  854. eventful 9410
  855. arteriole 9410
  856. disentangle 9410
  857. cured 9410
  858. Fenton 9410
  859. avoidable 9410
  860. drains 9410
  861. detectably 9410
  862. husky 9410
  863. impelling 9410
  864. undoes 9410
  865. evened 9410
  866. squeezes 9410
  867. destroyer 9410
  868. rudeness 9410
  869. beaner 9410
  870. boorish 9410
  871. Everhart 9410
  872. encompass 9410
  873. mushrooms 9410
  874. Alison 9410
  875. externally 9410
  876. pellagra 9410
  877. cult 9410
  878. creek 9410
  879. Huffman 9410
  880. Majorca 9410
  881. governing 9410
  882. gadfly 9410
  883. reassigned 9410
  884. intentness 9410
  885. craziness 9410
  886. psychic 9410
  887. squabbled 9410
  888. burlesque 9410
  889. capped 9410
  890. extracted 9410
  891. DiMaggio 9410
  892. exclamation 9410
  893. subdirectory 9410
  894. Gothicism 9410
  895. feminine 9410
  896. metaphysically 9410
  897. sanding 9410
  898. Miltonism 9410
  899. freakish 9410
  900. index 9410
  901. straight 9410
  902. flurried 9410
  903. denotative 9410
  904. coming 9410
  905. commencements 9410
  906. gentleman 9410
  907. gifted 9410
  908. Shanghais 9410
  909. sportswriting 9410
  910. sloping 9410
  911. navies 9410
  912. leaflet 9410
  913. shooter 9410
  914. Joplin 9410
  915. babies 9410
  916. assails 9410
  917. admiring 9410
  918. swaying 9410
  919. Goldstine 9410
  920. fitting 9410
  921. Norwalk 9410
  922. analogy 9410
  923. deludes 9410
  924. cokes 9410
  925. Clayton 9410
  926. exhausts 9410
  927. causality 9410
  928. sating 9410
  929. icon 9410
  930. throttles 9410
  931. communicants 9410
  932. dehydrate 9410
  933. priceless 9410
  934. publicly 9410
  935. incidentals 9410
  936. commonplace 9410
  937. mumbles 9410
  938. furthermore 9410
  939. cautioned 9410
  940. parametrized 9410
  941. registration 9410
  942. sadly 9410
  943. positioning 9410
  944. babysitting 9410
  945. eternal 9410
  946. hoarder 9410
  947. congregates 9410
  948. rains 9410
  949. workers 9410
  950. sags 9410
  951. unplug 9410
  952. garage 9410
  953. boulder 9410
  954. specifics 9410
  955. Teresa 9410
  956. Winsett 9410
  957. convenient 9410
  958. buckboards 9410
  959. amenities 9410
  960. resplendent 9410
  961. sews 9410
  962. participated 9410
  963. Simon 9410
  964. certificates 9410
  965. Fitzpatrick 9410
  966. Evanston 9410
  967. misted 9410
  968. textures 9410
  969. save 9410
  970. count 9410
  971. rightful 9410
  972. chaperone 9410
  973. Lizzy 9410
  974. clenched 9410
  975. effortlessly 9410
  976. accessed 9410
  977. beaters 9410
  978. Hornblower 9410
  979. vests 9410
  980. indulgences 9410
  981. infallibly 9410
  982. unwilling 9410
  983. excrete 9410
  984. spools 9410
  985. crunches 9410
  986. overestimating 9410
  987. ineffective 9410
  988. humiliation 9410
  989. sophomore 9410
  990. star 9410
  991. rifles 9410
  992. dialysis 9410
  993. arriving 9410
  994. indulge 9410
  995. clockers 9410
  996. languages 9410
  997. Antarctica 9410
  998. percentage 9410
  999. ceiling 9410
  1000. specification 9410
  1001. regimented 9410
  1002. ciphers 9410
  1003. pictures 9410
  1004. serpents 9410
  1005. allot 9410
  1006. realized 9410
  1007. mayoral 9410
  1008. opaquely 9410
  1009. hostess 9410
  1010. fiftieth 9410
  1011. incorrectly 9410
  1012. decomposition 9410
  1013. stranglings 9410
  1014. mixture 9410
  1015. electroencephalography 9410
  1016. similarities 9410
  1017. charges 9410
  1018. freest 9410
  1019. Greenberg 9410
  1020. tinting 9410
  1021. expelled 9410
  1022. warm 9410
  1023. smoothed 9410
  1024. deductions 9410
  1025. Romano 9410
  1026. bitterroot 9410
  1027. corset 9410
  1028. securing 9410
  1029. environing 9410
  1030. cute 9410
  1031. Crays 9410
  1032. heiress 9410
  1033. inform 9410
  1034. avenge 9410
  1035. universals 9410
  1036. Kinsey 9410
  1037. ravines 9410
  1038. bestseller 9410
  1039. equilibrium 9410
  1040. extents 9410
  1041. relatively 9410
  1042. pressure 9410
  1043. critiques 9410
  1044. befouled 9410
  1045. rightfully 9410
  1046. mechanizing 9410
  1047. Latinizes 9410
  1048. timesharing 9410
  1049. Aden 9410
  1050. embassies 9410
  1051. males 9410
  1052. shapelessly 9410
  1053. mastering 9410
  1054. Newtonian 9410
  1055. finishers 9410
  1056. abates 9410
  1057. teem 9410
  1058. kiting 9410
  1059. stodgy 9410
  1060. feed 9410
  1061. guitars 9410
  1062. airships 9410
  1063. store 9410
  1064. denounces 9410
  1065. Pyle 9410
  1066. Saxony 9410
  1067. serializations 9410
  1068. Peruvian 9410
  1069. taxonomically 9410
  1070. kingdom 9410
  1071. stint 9410
  1072. Sault 9410
  1073. faithful 9410
  1074. Ganymede 9410
  1075. tidiness 9410
  1076. gainful 9410
  1077. contrary 9410
  1078. Tipperary 9410
  1079. tropics 9410
  1080. theorizers 9410
  1081. renew 9410
  1082. already 9410
  1083. terminal 9410
  1084. Hegelian 9410
  1085. hypothesizer 9410
  1086. warningly 9410
  1087. journalizing 9410
  1088. nested 9410
  1089. Lars 9410
  1090. saplings 9410
  1091. foothill 9410
  1092. labeled 9410
  1093. imperiously 9410
  1094. reporters 9410
  1095. furnishings 9410
  1096. precipitable 9410
  1097. discounts 9410
  1098. excises 9410
  1099. Stalin 9410
  1100. despot 9410
  1101. ripeness 9410
  1102. Arabia 9410
  1103. unruly 9410
  1104. mournfulness 9410
  1105. boom 9410
  1106. slaughter 9410
  1107. Sabine 9410
  1108. handy 9410
  1109. rural 9410
  1110. organizer 9410
  1111. shipyard 9410
  1112. civics 9410
  1113. inaccuracy 9410
  1114. rules 9410
  1115. juveniles 9410
  1116. comprised 9410
  1117. investigations 9410
  1118. stabilizes 9410
  1119. seminaries 9410
  1120. Hunter 9410
  1121. sporty 9410
  1122. test 9410
  1123. weasels 9410
  1124. CERN 9410
  1125. tempering 9410
  1126. afore 9410
  1127. Galatean 9410
  1128. techniques 9410
  1129. error 9410
  1130. veranda 9410
  1131. severely 9410
  1132. Cassites 9410
  1133. forthcoming 9410
  1134. guides 9410
  1135. vanish 9410
  1136. lied 9410
  1137. sawtooth 9410
  1138. fated 9410
  1139. gradually 9410
  1140. widens 9410
  1141. preclude 9410
  1142. evenhandedly 9410
  1143. percentage 9410
  1144. disobedience 9410
  1145. humility 9410
  1146. gleaning 9410
  1147. petted 9410
  1148. bloater 9410
  1149. minion 9410
  1150. marginal 9410
  1151. apiary 9410
  1152. measures 9410
  1153. precaution 9410
  1154. repelled 9410
  1155. primary 9410
  1156. coverings 9410
  1157. Artemia 9410
  1158. navigate 9410
  1159. spatial 9410
  1160. Gurkha 9410
  1161. meanwhile 9410
  1162. Melinda 9410
  1163. Butterfield 9410
  1164. Aldrich 9410
  1165. previewing 9410
  1166. glut 9410
  1167. unaffected 9410
  1168. inmate 9410
  1169. mineral 9410
  1170. impending 9410
  1171. meditation 9410
  1172. ideas 9410
  1173. miniaturizes 9410
  1174. lewdly 9410
  1175. title 9410
  1176. youthfulness 9410
  1177. creak 9410
  1178. Chippewa 9410
  1179. clamored 9410
  1180. freezes 9410
  1181. forgivably 9410
  1182. reduce 9410
  1183. McGovern 9410
  1184. Nazis 9410
  1185. epistle 9410
  1186. socializes 9410
  1187. conceptions 9410
  1188. Kevin 9410
  1189. uncovering 9410
  1190. chews 9410
  1191. appendixes 9410
  1192. appendixes 9410
  1193. appendixes 9410
  1194. appendixes 9410
  1195. appendixes 9410
  1196. appendixes 9410
  1197. raining 9410
  1198. infest 9410
  1199. compartment 9410
  1200. minting 9410
  1201. ducks 9410
  1202. roped 9410
  1203. waltz 9410
  1204. Lillian 9410
  1205. repressions 9410
  1206. chillingly 9410
  1207. noncritical 9410
  1208. lithograph 9410
  1209. spongers 9410
  1210. parenthood 9410
  1211. posed 9410
  1212. instruments 9410
  1213. filial 9410
  1214. fixedly 9410
  1215. relives 9410
  1216. Pandora 9410
  1217. watering 9410
  1218. ungrateful 9410
  1219. secures 9410
  1220. poison 9410
  1221. dusted 9410
  1222. encompasses 9410
  1223. presentation 9410
  1224. Kantian 9410
  1225. select fld3,period,price,price2 from t2,t3 where t2.fld1=t3.t2nr and period >= 1001 and period <= 1002 and t2.companynr = 37 order by fld3,period, price;
  1226. fld3 period price price2
  1227. admonishing 1002 28357832 8723648
  1228. analyzable 1002 28357832 8723648
  1229. annihilates 1001 5987435 234724
  1230. Antares 1002 28357832 8723648
  1231. astound 1001 5987435 234724
  1232. audiology 1001 5987435 234724
  1233. Augustine 1002 28357832 8723648
  1234. Baird 1002 28357832 8723648
  1235. bewilderingly 1001 5987435 234724
  1236. breaking 1001 5987435 234724
  1237. Conley 1001 5987435 234724
  1238. dentally 1002 28357832 8723648
  1239. dissociate 1002 28357832 8723648
  1240. elite 1001 5987435 234724
  1241. eschew 1001 5987435 234724
  1242. Eulerian 1001 5987435 234724
  1243. flanking 1001 5987435 234724
  1244. foldout 1002 28357832 8723648
  1245. funereal 1002 28357832 8723648
  1246. galling 1002 28357832 8723648
  1247. Graves 1001 5987435 234724
  1248. grazing 1001 5987435 234724
  1249. groupings 1001 5987435 234724
  1250. handgun 1001 5987435 234724
  1251. humility 1002 28357832 8723648
  1252. impulsive 1002 28357832 8723648
  1253. inch 1001 5987435 234724
  1254. intelligibility 1001 5987435 234724
  1255. jarring 1001 5987435 234724
  1256. lawgiver 1001 5987435 234724
  1257. lectured 1002 28357832 8723648
  1258. Merritt 1002 28357832 8723648
  1259. neonatal 1001 5987435 234724
  1260. offload 1002 28357832 8723648
  1261. parters 1002 28357832 8723648
  1262. pityingly 1002 28357832 8723648
  1263. puddings 1002 28357832 8723648
  1264. Punjab 1001 5987435 234724
  1265. quitter 1002 28357832 8723648
  1266. realtor 1001 5987435 234724
  1267. relaxing 1001 5987435 234724
  1268. repetitions 1001 5987435 234724
  1269. resumes 1001 5987435 234724
  1270. Romans 1002 28357832 8723648
  1271. rusting 1001 5987435 234724
  1272. scholastics 1001 5987435 234724
  1273. skulking 1002 28357832 8723648
  1274. stated 1002 28357832 8723648
  1275. suites 1002 28357832 8723648
  1276. sureties 1001 5987435 234724
  1277. testicle 1002 28357832 8723648
  1278. tinily 1002 28357832 8723648
  1279. tragedies 1001 5987435 234724
  1280. trimmings 1001 5987435 234724
  1281. vacuuming 1001 5987435 234724
  1282. ventilate 1001 5987435 234724
  1283. wallet 1001 5987435 234724
  1284. Weissmuller 1002 28357832 8723648
  1285. Wotan 1002 28357832 8723648
  1286. select t2.fld1,fld3,period,price,price2 from t2,t3 where t2.fld1>= 18201 and t2.fld1 <= 18811 and t2.fld1=t3.t2nr and period = 1001 and t2.companynr = 37;
  1287. fld1 fld3 period price price2
  1288. 018201 relaxing 1001 5987435 234724
  1289. 018601 vacuuming 1001 5987435 234724
  1290. 018801 inch 1001 5987435 234724
  1291. 018811 repetitions 1001 5987435 234724
  1292. create table t4 (
  1293. companynr tinyint(2) unsigned zerofill NOT NULL default '00',
  1294. companyname char(30) NOT NULL default '',
  1295. PRIMARY KEY (companynr),
  1296. UNIQUE KEY companyname(companyname)
  1297. ) ENGINE=MyISAM MAX_ROWS=50 PACK_KEYS=1 COMMENT='companynames';
  1298. select STRAIGHT_JOIN t2.companynr,companyname from t4,t2 where t2.companynr=t4.companynr group by t2.companynr;
  1299. companynr companyname
  1300. 00 Unknown
  1301. 29 company 1
  1302. 34 company 2
  1303. 36 company 3
  1304. 37 company 4
  1305. 40 company 5
  1306. 41 company 6
  1307. 50 company 11
  1308. 53 company 7
  1309. 58 company 8
  1310. 65 company 9
  1311. 68 company 10
  1312. select SQL_SMALL_RESULT t2.companynr,companyname from t4,t2 where t2.companynr=t4.companynr group by t2.companynr;
  1313. companynr companyname
  1314. 00 Unknown
  1315. 29 company 1
  1316. 34 company 2
  1317. 36 company 3
  1318. 37 company 4
  1319. 40 company 5
  1320. 41 company 6
  1321. 50 company 11
  1322. 53 company 7
  1323. 58 company 8
  1324. 65 company 9
  1325. 68 company 10
  1326. select * from t1,t1 t12;
  1327. Period Varor_period Period Varor_period
  1328. 9410 9412 9410 9412
  1329. select t2.fld1,t22.fld1 from t2,t2 t22 where t2.fld1 >= 250501 and t2.fld1 <= 250505 and t22.fld1 >= 250501 and t22.fld1 <= 250505;
  1330. fld1 fld1
  1331. 250501 250501
  1332. 250502 250501
  1333. 250503 250501
  1334. 250504 250501
  1335. 250505 250501
  1336. 250501 250502
  1337. 250502 250502
  1338. 250503 250502
  1339. 250504 250502
  1340. 250505 250502
  1341. 250501 250503
  1342. 250502 250503
  1343. 250503 250503
  1344. 250504 250503
  1345. 250505 250503
  1346. 250501 250504
  1347. 250502 250504
  1348. 250503 250504
  1349. 250504 250504
  1350. 250505 250504
  1351. 250501 250505
  1352. 250502 250505
  1353. 250503 250505
  1354. 250504 250505
  1355. 250505 250505
  1356. insert into t2 (fld1, companynr) values (999999,99);
  1357. select t2.companynr,companyname from t2 left join t4 using (companynr) where t4.companynr is null;
  1358. companynr companyname
  1359. 99 NULL
  1360. select count(*) from t2 left join t4 using (companynr) where t4.companynr is not null;
  1361. count(*)
  1362. 1199
  1363. explain select t2.companynr,companyname from t2 left join t4 using (companynr) where t4.companynr is null;
  1364. id select_type table type possible_keys key key_len ref rows Extra
  1365. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1200
  1366. 1 SIMPLE t4 eq_ref PRIMARY PRIMARY 1 test.t2.companynr 1 Using where; Not exists
  1367. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr is null;
  1368. id select_type table type possible_keys key key_len ref rows Extra
  1369. 1 SIMPLE t4 ALL NULL NULL NULL NULL 12
  1370. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1200 Using where; Not exists
  1371. select companynr,companyname from t2 left join t4 using (companynr) where companynr is null;
  1372. companynr companyname
  1373. select count(*) from t2 left join t4 using (companynr) where companynr is not null;
  1374. count(*)
  1375. 1200
  1376. explain select companynr,companyname from t2 left join t4 using (companynr) where companynr is null;
  1377. id select_type table type possible_keys key key_len ref rows Extra
  1378. 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL Impossible WHERE
  1379. explain select companynr,companyname from t4 left join t2 using (companynr) where companynr is null;
  1380. id select_type table type possible_keys key key_len ref rows Extra
  1381. 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL Impossible WHERE
  1382. delete from t2 where fld1=999999;
  1383. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0;
  1384. id select_type table type possible_keys key key_len ref rows Extra
  1385. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1386. 1 SIMPLE t4 eq_ref PRIMARY PRIMARY 1 test.t2.companynr 1
  1387. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 or t2.companynr < 0;
  1388. id select_type table type possible_keys key key_len ref rows Extra
  1389. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1390. 1 SIMPLE t4 eq_ref PRIMARY PRIMARY 1 test.t2.companynr 1
  1391. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 and t4.companynr > 0;
  1392. id select_type table type possible_keys key key_len ref rows Extra
  1393. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1394. 1 SIMPLE t4 eq_ref PRIMARY PRIMARY 1 test.t2.companynr 1
  1395. explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0;
  1396. id select_type table type possible_keys key key_len ref rows Extra
  1397. 1 SIMPLE t4 ALL PRIMARY NULL NULL NULL 12 Using where
  1398. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1399. explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 or companynr < 0;
  1400. id select_type table type possible_keys key key_len ref rows Extra
  1401. 1 SIMPLE t4 ALL PRIMARY NULL NULL NULL 12 Using where
  1402. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1403. explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 and companynr > 0;
  1404. id select_type table type possible_keys key key_len ref rows Extra
  1405. 1 SIMPLE t4 ALL PRIMARY NULL NULL NULL 12 Using where
  1406. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1407. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 or t2.companynr is null;
  1408. id select_type table type possible_keys key key_len ref rows Extra
  1409. 1 SIMPLE t4 ALL NULL NULL NULL NULL 12
  1410. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1411. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 or t2.companynr < 0 or t4.companynr > 0;
  1412. id select_type table type possible_keys key key_len ref rows Extra
  1413. 1 SIMPLE t4 ALL PRIMARY NULL NULL NULL 12
  1414. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1415. explain select t2.companynr,companyname from t4 left join t2 using (companynr) where ifnull(t2.companynr,1)>0;
  1416. id select_type table type possible_keys key key_len ref rows Extra
  1417. 1 SIMPLE t4 ALL NULL NULL NULL NULL 12
  1418. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1419. explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 or companynr is null;
  1420. id select_type table type possible_keys key key_len ref rows Extra
  1421. 1 SIMPLE t4 ALL PRIMARY NULL NULL NULL 12 Using where
  1422. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1423. explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 or companynr < 0 or companynr > 0;
  1424. id select_type table type possible_keys key key_len ref rows Extra
  1425. 1 SIMPLE t4 ALL PRIMARY NULL NULL NULL 12 Using where
  1426. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1427. explain select companynr,companyname from t4 left join t2 using (companynr) where ifnull(companynr,1)>0;
  1428. id select_type table type possible_keys key key_len ref rows Extra
  1429. 1 SIMPLE t4 ALL NULL NULL NULL NULL 12 Using where
  1430. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1431. select distinct t2.companynr,t4.companynr from t2,t4 where t2.companynr=t4.companynr+1;
  1432. companynr companynr
  1433. 37 36
  1434. 41 40
  1435. explain select distinct t2.companynr,t4.companynr from t2,t4 where t2.companynr=t4.companynr+1;
  1436. id select_type table type possible_keys key key_len ref rows Extra
  1437. 1 SIMPLE t4 index NULL PRIMARY 1 NULL 12 Using index; Using temporary
  1438. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1439. select t2.fld1,t2.companynr,fld3,period from t3,t2 where t2.fld1 = 38208 and t2.fld1=t3.t2nr and period = 1008 or t2.fld1 = 38008 and t2.fld1 =t3.t2nr and period = 1008;
  1440. fld1 companynr fld3 period
  1441. 038008 37 reporters 1008
  1442. 038208 37 Selfridge 1008
  1443. select t2.fld1,t2.companynr,fld3,period from t3,t2 where (t2.fld1 = 38208 or t2.fld1 = 38008) and t2.fld1=t3.t2nr and period>=1008 and period<=1009;
  1444. fld1 companynr fld3 period
  1445. 038008 37 reporters 1008
  1446. 038208 37 Selfridge 1008
  1447. select t2.fld1,t2.companynr,fld3,period from t3,t2 where (t3.t2nr = 38208 or t3.t2nr = 38008) and t2.fld1=t3.t2nr and period>=1008 and period<=1009;
  1448. fld1 companynr fld3 period
  1449. 038008 37 reporters 1008
  1450. 038208 37 Selfridge 1008
  1451. select period from t1 where (((period > 0) or period < 10000 or (period = 1900)) and (period=1900 and period <= 1901) or (period=1903 and (period=1903)) and period>=1902) or ((period=1904 or period=1905) or (period=1906 or period>1907)) or (period=1908 and period = 1909);
  1452. period
  1453. 9410
  1454. select period from t1 where ((period > 0 and period < 1) or (((period > 0 and period < 100) and (period > 10)) or (period > 10)) or (period > 0 and (period > 5 or period > 6)));
  1455. period
  1456. 9410
  1457. select a.fld1 from t2 as a,t2 b where ((a.fld1 = 250501 and a.fld1=b.fld1) or a.fld1=250502 or a.fld1=250503 or (a.fld1=250505 and a.fld1<=b.fld1 and b.fld1>=a.fld1)) and a.fld1=b.fld1;
  1458. fld1
  1459. 250501
  1460. 250502
  1461. 250503
  1462. 250505
  1463. select fld1 from t2 where fld1 in (250502,98005,98006,250503,250605,250606) and fld1 >=250502 and fld1 not in (250605,250606);
  1464. fld1
  1465. 250502
  1466. 250503
  1467. select fld1 from t2 where fld1 between 250502 and 250504;
  1468. fld1
  1469. 250502
  1470. 250503
  1471. 250504
  1472. select fld3 from t2 where (((fld3 like "_%L%" ) or (fld3 like "%ok%")) and ( fld3 like "L%" or fld3 like "G%")) and fld3 like "L%" ;
  1473. fld3
  1474. label
  1475. labeled
  1476. labeled
  1477. landslide
  1478. laterally
  1479. leaflet
  1480. lewdly
  1481. Lillian
  1482. luckily
  1483. select count(*) from t1;
  1484. count(*)
  1485. 1
  1486. select companynr,count(*),sum(fld1) from t2 group by companynr;
  1487. companynr count(*) sum(fld1)
  1488. 00 82 10355753
  1489. 29 95 14473298
  1490. 34 70 17788966
  1491. 36 215 22786296
  1492. 37 588 83602098
  1493. 40 37 6618386
  1494. 41 52 12816335
  1495. 50 11 1595438
  1496. 53 4 793210
  1497. 58 23 2254293
  1498. 65 10 2284055
  1499. 68 12 3097288
  1500. select companynr,count(*) from t2 group by companynr order by companynr desc limit 5;
  1501. companynr count(*)
  1502. 68 12
  1503. 65 10
  1504. 58 23
  1505. 53 4
  1506. 50 11
  1507. select count(*),min(fld4),max(fld4),sum(fld1),avg(fld1),std(fld1),variance(fld1) from t2 where companynr = 34 and fld4<>"";
  1508. count(*) min(fld4) max(fld4) sum(fld1) avg(fld1) std(fld1) variance(fld1)
  1509. 70 absentee vest 17788966 254128.0857 3272.5940 10709871.3069
  1510. explain extended select count(*),min(fld4),max(fld4),sum(fld1),avg(fld1),std(fld1),variance(fld1) from t2 where companynr = 34 and fld4<>"";
  1511. id select_type table type possible_keys key key_len ref rows Extra
  1512. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199 Using where
  1513. Warnings:
  1514. Note 1003 select count(0) AS `count(*)`,min(`test`.`t2`.`fld4`) AS `min(fld4)`,max(`test`.`t2`.`fld4`) AS `max(fld4)`,sum(`test`.`t2`.`fld1`) AS `sum(fld1)`,avg(`test`.`t2`.`fld1`) AS `avg(fld1)`,std(`test`.`t2`.`fld1`) AS `std(fld1)`,variance(`test`.`t2`.`fld1`) AS `variance(fld1)` from `test`.`t2` where ((`test`.`t2`.`companynr` = 34) and (`test`.`t2`.`fld4` <> _latin1''))
  1515. select companynr,count(*),min(fld4),max(fld4),sum(fld1),avg(fld1),std(fld1),variance(fld1) from t2 group by companynr limit 3;
  1516. companynr count(*) min(fld4) max(fld4) sum(fld1) avg(fld1) std(fld1) variance(fld1)
  1517. 00 82 Anthony windmills 10355753 126289.6707 115550.9757 13352027981.7087
  1518. 29 95 abut wetness 14473298 152350.5053 8368.5480 70032594.9026
  1519. 34 70 absentee vest 17788966 254128.0857 3272.5940 10709871.3069
  1520. select companynr,t2nr,count(price),sum(price),min(price),max(price),avg(price) from t3 where companynr = 37 group by companynr,t2nr limit 10;
  1521. companynr t2nr count(price) sum(price) min(price) max(price) avg(price)
  1522. 37 1 1 5987435 5987435 5987435 5987435.0000
  1523. 37 2 1 28357832 28357832 28357832 28357832.0000
  1524. 37 3 1 39654943 39654943 39654943 39654943.0000
  1525. 37 11 1 5987435 5987435 5987435 5987435.0000
  1526. 37 12 1 28357832 28357832 28357832 28357832.0000
  1527. 37 13 1 39654943 39654943 39654943 39654943.0000
  1528. 37 21 1 5987435 5987435 5987435 5987435.0000
  1529. 37 22 1 28357832 28357832 28357832 28357832.0000
  1530. 37 23 1 39654943 39654943 39654943 39654943.0000
  1531. 37 31 1 5987435 5987435 5987435 5987435.0000
  1532. select /*! SQL_SMALL_RESULT */ companynr,t2nr,count(price),sum(price),min(price),max(price),avg(price) from t3 where companynr = 37 group by companynr,t2nr limit 10;
  1533. companynr t2nr count(price) sum(price) min(price) max(price) avg(price)
  1534. 37 1 1 5987435 5987435 5987435 5987435.0000
  1535. 37 2 1 28357832 28357832 28357832 28357832.0000
  1536. 37 3 1 39654943 39654943 39654943 39654943.0000
  1537. 37 11 1 5987435 5987435 5987435 5987435.0000
  1538. 37 12 1 28357832 28357832 28357832 28357832.0000
  1539. 37 13 1 39654943 39654943 39654943 39654943.0000
  1540. 37 21 1 5987435 5987435 5987435 5987435.0000
  1541. 37 22 1 28357832 28357832 28357832 28357832.0000
  1542. 37 23 1 39654943 39654943 39654943 39654943.0000
  1543. 37 31 1 5987435 5987435 5987435 5987435.0000
  1544. select companynr,count(price),sum(price),min(price),max(price),avg(price) from t3 group by companynr ;
  1545. companynr count(price) sum(price) min(price) max(price) avg(price)
  1546. 37 12543 309394878010 5987435 39654943 24666736.6667
  1547. 78 8362 414611089292 726498 98439034 49582766.0000
  1548. 101 4181 3489454238 834598 834598 834598.0000
  1549. 154 4181 4112197254950 983543950 983543950 983543950.0000
  1550. 311 4181 979599938 234298 234298 234298.0000
  1551. 447 4181 9929180954 2374834 2374834 2374834.0000
  1552. 512 4181 3288532102 786542 786542 786542.0000
  1553. select distinct mod(companynr,10) from t4 group by companynr;
  1554. mod(companynr,10)
  1555. 0
  1556. 9
  1557. 4
  1558. 6
  1559. 7
  1560. 1
  1561. 3
  1562. 8
  1563. 5
  1564. select distinct 1 from t4 group by companynr;
  1565. 1
  1566. 1
  1567. select count(distinct fld1) from t2;
  1568. count(distinct fld1)
  1569. 1199
  1570. select companynr,count(distinct fld1) from t2 group by companynr;
  1571. companynr count(distinct fld1)
  1572. 00 82
  1573. 29 95
  1574. 34 70
  1575. 36 215
  1576. 37 588
  1577. 40 37
  1578. 41 52
  1579. 50 11
  1580. 53 4
  1581. 58 23
  1582. 65 10
  1583. 68 12
  1584. select companynr,count(*) from t2 group by companynr;
  1585. companynr count(*)
  1586. 00 82
  1587. 29 95
  1588. 34 70
  1589. 36 215
  1590. 37 588
  1591. 40 37
  1592. 41 52
  1593. 50 11
  1594. 53 4
  1595. 58 23
  1596. 65 10
  1597. 68 12
  1598. select companynr,count(distinct concat(fld1,repeat(65,1000))) from t2 group by companynr;
  1599. companynr count(distinct concat(fld1,repeat(65,1000)))
  1600. 00 82
  1601. 29 95
  1602. 34 70
  1603. 36 215
  1604. 37 588
  1605. 40 37
  1606. 41 52
  1607. 50 11
  1608. 53 4
  1609. 58 23
  1610. 65 10
  1611. 68 12
  1612. select companynr,count(distinct concat(fld1,repeat(65,200))) from t2 group by companynr;
  1613. companynr count(distinct concat(fld1,repeat(65,200)))
  1614. 00 82
  1615. 29 95
  1616. 34 70
  1617. 36 215
  1618. 37 588
  1619. 40 37
  1620. 41 52
  1621. 50 11
  1622. 53 4
  1623. 58 23
  1624. 65 10
  1625. 68 12
  1626. select companynr,count(distinct floor(fld1/100)) from t2 group by companynr;
  1627. companynr count(distinct floor(fld1/100))
  1628. 00 47
  1629. 29 35
  1630. 34 14
  1631. 36 69
  1632. 37 108
  1633. 40 16
  1634. 41 11
  1635. 50 9
  1636. 53 1
  1637. 58 1
  1638. 65 1
  1639. 68 1
  1640. select companynr,count(distinct concat(repeat(65,1000),floor(fld1/100))) from t2 group by companynr;
  1641. companynr count(distinct concat(repeat(65,1000),floor(fld1/100)))
  1642. 00 47
  1643. 29 35
  1644. 34 14
  1645. 36 69
  1646. 37 108
  1647. 40 16
  1648. 41 11
  1649. 50 9
  1650. 53 1
  1651. 58 1
  1652. 65 1
  1653. 68 1
  1654. select sum(fld1),fld3 from t2 where fld3="Romans" group by fld1 limit 10;
  1655. sum(fld1) fld3
  1656. 11402 Romans
  1657. select name,count(*) from t3 where name='cloakroom' group by name;
  1658. name count(*)
  1659. cloakroom 4181
  1660. select name,count(*) from t3 where name='cloakroom' and price>10 group by name;
  1661. name count(*)
  1662. cloakroom 4181
  1663. select count(*) from t3 where name='cloakroom' and price2=823742;
  1664. count(*)
  1665. 4181
  1666. select name,count(*) from t3 where name='cloakroom' and price2=823742 group by name;
  1667. name count(*)
  1668. cloakroom 4181
  1669. select name,count(*) from t3 where name >= "extramarital" and price <= 39654943 group by name;
  1670. name count(*)
  1671. extramarital 4181
  1672. gazer 4181
  1673. gems 4181
  1674. Iranizes 4181
  1675. spates 4181
  1676. tucked 4181
  1677. violinist 4181
  1678. select t2.fld3,count(*) from t2,t3 where t2.fld1=158402 and t3.name=t2.fld3 group by t3.name;
  1679. fld3 count(*)
  1680. spates 4181
  1681. select companynr|0,companyname from t4 group by 1;
  1682. companynr|0 companyname
  1683. 0 Unknown
  1684. 29 company 1
  1685. 34 company 2
  1686. 36 company 3
  1687. 37 company 4
  1688. 40 company 5
  1689. 41 company 6
  1690. 50 company 11
  1691. 53 company 7
  1692. 58 company 8
  1693. 65 company 9
  1694. 68 company 10
  1695. select t2.companynr,companyname,count(*) from t2,t4 where t2.companynr=t4.companynr group by t2.companynr order by companyname;
  1696. companynr companyname count(*)
  1697. 29 company 1 95
  1698. 68 company 10 12
  1699. 50 company 11 11
  1700. 34 company 2 70
  1701. 36 company 3 215
  1702. 37 company 4 588
  1703. 40 company 5 37
  1704. 41 company 6 52
  1705. 53 company 7 4
  1706. 58 company 8 23
  1707. 65 company 9 10
  1708. 00 Unknown 82
  1709. select t2.fld1,count(*) from t2,t3 where t2.fld1=158402 and t3.name=t2.fld3 group by t3.name;
  1710. fld1 count(*)
  1711. 158402 4181
  1712. select sum(Period)/count(*) from t1;
  1713. sum(Period)/count(*)
  1714. 9410.0000
  1715. select companynr,count(price) as "count",sum(price) as "sum" ,abs(sum(price)/count(price)-avg(price)) as "diff",(0+count(price))*companynr as func from t3 group by companynr;
  1716. companynr count sum diff func
  1717. 37 12543 309394878010 0.0000 464091
  1718. 78 8362 414611089292 0.0000 652236
  1719. 101 4181 3489454238 0.0000 422281
  1720. 154 4181 4112197254950 0.0000 643874
  1721. 311 4181 979599938 0.0000 1300291
  1722. 447 4181 9929180954 0.0000 1868907
  1723. 512 4181 3288532102 0.0000 2140672
  1724. select companynr,sum(price)/count(price) as avg from t3 group by companynr having avg > 70000000 order by avg;
  1725. companynr avg
  1726. 154 983543950.0000
  1727. select companynr,count(*) from t2 group by companynr order by 2 desc;
  1728. companynr count(*)
  1729. 37 588
  1730. 36 215
  1731. 29 95
  1732. 00 82
  1733. 34 70
  1734. 41 52
  1735. 40 37
  1736. 58 23
  1737. 68 12
  1738. 50 11
  1739. 65 10
  1740. 53 4
  1741. select companynr,count(*) from t2 where companynr > 40 group by companynr order by 2 desc;
  1742. companynr count(*)
  1743. 41 52
  1744. 58 23
  1745. 68 12
  1746. 50 11
  1747. 65 10
  1748. 53 4
  1749. select t2.fld4,t2.fld1,count(price),sum(price),min(price),max(price),avg(price) from t3,t2 where t3.companynr = 37 and t2.fld1 = t3.t2nr group by fld1,t2.fld4;
  1750. fld4 fld1 count(price) sum(price) min(price) max(price) avg(price)
  1751. teethe 000001 1 5987435 5987435 5987435 5987435.0000
  1752. dreaded 011401 1 5987435 5987435 5987435 5987435.0000
  1753. scholastics 011402 1 28357832 28357832 28357832 28357832.0000
  1754. audiology 011403 1 39654943 39654943 39654943 39654943.0000
  1755. wallet 011501 1 5987435 5987435 5987435 5987435.0000
  1756. parters 011701 1 5987435 5987435 5987435 5987435.0000
  1757. eschew 011702 1 28357832 28357832 28357832 28357832.0000
  1758. quitter 011703 1 39654943 39654943 39654943 39654943.0000
  1759. neat 012001 1 5987435 5987435 5987435 5987435.0000
  1760. Steinberg 012003 1 39654943 39654943 39654943 39654943.0000
  1761. balled 012301 1 5987435 5987435 5987435 5987435.0000
  1762. persist 012302 1 28357832 28357832 28357832 28357832.0000
  1763. attainments 012303 1 39654943 39654943 39654943 39654943.0000
  1764. capably 012501 1 5987435 5987435 5987435 5987435.0000
  1765. impulsive 012602 1 28357832 28357832 28357832 28357832.0000
  1766. starlet 012603 1 39654943 39654943 39654943 39654943.0000
  1767. featherweight 012701 1 5987435 5987435 5987435 5987435.0000
  1768. pessimist 012702 1 28357832 28357832 28357832 28357832.0000
  1769. daughter 012703 1 39654943 39654943 39654943 39654943.0000
  1770. lawgiver 013601 1 5987435 5987435 5987435 5987435.0000
  1771. stated 013602 1 28357832 28357832 28357832 28357832.0000
  1772. readable 013603 1 39654943 39654943 39654943 39654943.0000
  1773. testicle 013801 1 5987435 5987435 5987435 5987435.0000
  1774. Parsifal 013802 1 28357832 28357832 28357832 28357832.0000
  1775. leavings 013803 1 39654943 39654943 39654943 39654943.0000
  1776. squeaking 013901 1 5987435 5987435 5987435 5987435.0000
  1777. contrasted 016001 1 5987435 5987435 5987435 5987435.0000
  1778. leftover 016201 1 5987435 5987435 5987435 5987435.0000
  1779. whiteners 016202 1 28357832 28357832 28357832 28357832.0000
  1780. erases 016301 1 5987435 5987435 5987435 5987435.0000
  1781. Punjab 016302 1 28357832 28357832 28357832 28357832.0000
  1782. Merritt 016303 1 39654943 39654943 39654943 39654943.0000
  1783. sweetish 018001 1 5987435 5987435 5987435 5987435.0000
  1784. dogging 018002 1 28357832 28357832 28357832 28357832.0000
  1785. scornfully 018003 1 39654943 39654943 39654943 39654943.0000
  1786. fetters 018012 1 28357832 28357832 28357832 28357832.0000
  1787. bivalves 018013 1 39654943 39654943 39654943 39654943.0000
  1788. skulking 018021 1 5987435 5987435 5987435 5987435.0000
  1789. flint 018022 1 28357832 28357832 28357832 28357832.0000
  1790. flopping 018023 1 39654943 39654943 39654943 39654943.0000
  1791. Judas 018032 1 28357832 28357832 28357832 28357832.0000
  1792. vacuuming 018033 1 39654943 39654943 39654943 39654943.0000
  1793. medical 018041 1 5987435 5987435 5987435 5987435.0000
  1794. bloodbath 018042 1 28357832 28357832 28357832 28357832.0000
  1795. subschema 018043 1 39654943 39654943 39654943 39654943.0000
  1796. interdependent 018051 1 5987435 5987435 5987435 5987435.0000
  1797. Graves 018052 1 28357832 28357832 28357832 28357832.0000
  1798. neonatal 018053 1 39654943 39654943 39654943 39654943.0000
  1799. sorters 018061 1 5987435 5987435 5987435 5987435.0000
  1800. epistle 018062 1 28357832 28357832 28357832 28357832.0000
  1801. Conley 018101 1 5987435 5987435 5987435 5987435.0000
  1802. lectured 018102 1 28357832 28357832 28357832 28357832.0000
  1803. Abraham 018103 1 39654943 39654943 39654943 39654943.0000
  1804. cage 018201 1 5987435 5987435 5987435 5987435.0000
  1805. hushes 018202 1 28357832 28357832 28357832 28357832.0000
  1806. Simla 018402 1 28357832 28357832 28357832 28357832.0000
  1807. reporters 018403 1 39654943 39654943 39654943 39654943.0000
  1808. coexist 018601 1 5987435 5987435 5987435 5987435.0000
  1809. Beebe 018602 1 28357832 28357832 28357832 28357832.0000
  1810. Taoism 018603 1 39654943 39654943 39654943 39654943.0000
  1811. Connally 018801 1 5987435 5987435 5987435 5987435.0000
  1812. fetched 018802 1 28357832 28357832 28357832 28357832.0000
  1813. checkpoints 018803 1 39654943 39654943 39654943 39654943.0000
  1814. gritty 018811 1 5987435 5987435 5987435 5987435.0000
  1815. firearm 018812 1 28357832 28357832 28357832 28357832.0000
  1816. minima 019101 1 5987435 5987435 5987435 5987435.0000
  1817. Selfridge 019102 1 28357832 28357832 28357832 28357832.0000
  1818. disable 019103 1 39654943 39654943 39654943 39654943.0000
  1819. witchcraft 019201 1 5987435 5987435 5987435 5987435.0000
  1820. betroth 030501 1 5987435 5987435 5987435 5987435.0000
  1821. Manhattanize 030502 1 28357832 28357832 28357832 28357832.0000
  1822. imprint 030503 1 39654943 39654943 39654943 39654943.0000
  1823. swelling 031901 1 5987435 5987435 5987435 5987435.0000
  1824. interrelationships 036001 1 5987435 5987435 5987435 5987435.0000
  1825. riser 036002 1 28357832 28357832 28357832 28357832.0000
  1826. bee 038001 1 5987435 5987435 5987435 5987435.0000
  1827. kanji 038002 1 28357832 28357832 28357832 28357832.0000
  1828. dental 038003 1 39654943 39654943 39654943 39654943.0000
  1829. railway 038011 1 5987435 5987435 5987435 5987435.0000
  1830. validate 038012 1 28357832 28357832 28357832 28357832.0000
  1831. normalizes 038013 1 39654943 39654943 39654943 39654943.0000
  1832. Kline 038101 1 5987435 5987435 5987435 5987435.0000
  1833. Anatole 038102 1 28357832 28357832 28357832 28357832.0000
  1834. partridges 038103 1 39654943 39654943 39654943 39654943.0000
  1835. recruited 038201 1 5987435 5987435 5987435 5987435.0000
  1836. dimensions 038202 1 28357832 28357832 28357832 28357832.0000
  1837. Chicana 038203 1 39654943 39654943 39654943 39654943.0000
  1838. select t3.companynr,fld3,sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 512 group by companynr,fld3;
  1839. companynr fld3 sum(price)
  1840. 512 boat 786542
  1841. 512 capably 786542
  1842. 512 cupboard 786542
  1843. 512 decliner 786542
  1844. 512 descendants 786542
  1845. 512 dopers 786542
  1846. 512 erases 786542
  1847. 512 Micronesia 786542
  1848. 512 Miles 786542
  1849. 512 skies 786542
  1850. select t2.companynr,count(*),min(fld3),max(fld3),sum(price),avg(price) from t2,t3 where t3.companynr >= 30 and t3.companynr <= 58 and t3.t2nr = t2.fld1 and 1+1=2 group by t2.companynr;
  1851. companynr count(*) min(fld3) max(fld3) sum(price) avg(price)
  1852. 00 1 Omaha Omaha 5987435 5987435.0000
  1853. 36 1 dubbed dubbed 28357832 28357832.0000
  1854. 37 83 Abraham Wotan 1908978016 22999735.1325
  1855. 50 2 scribbled tapestry 68012775 34006387.5000
  1856. select t3.companynr+0,t3.t2nr,fld3,sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 37 group by 1,t3.t2nr,fld3,fld3,fld3,fld3,fld3 order by fld1;
  1857. t3.companynr+0 t2nr fld3 sum(price)
  1858. 37 1 Omaha 5987435
  1859. 37 11401 breaking 5987435
  1860. 37 11402 Romans 28357832
  1861. 37 11403 intercepted 39654943
  1862. 37 11501 bewilderingly 5987435
  1863. 37 11701 astound 5987435
  1864. 37 11702 admonishing 28357832
  1865. 37 11703 sumac 39654943
  1866. 37 12001 flanking 5987435
  1867. 37 12003 combed 39654943
  1868. 37 12301 Eulerian 5987435
  1869. 37 12302 dubbed 28357832
  1870. 37 12303 Kane 39654943
  1871. 37 12501 annihilates 5987435
  1872. 37 12602 Wotan 28357832
  1873. 37 12603 snatching 39654943
  1874. 37 12701 grazing 5987435
  1875. 37 12702 Baird 28357832
  1876. 37 12703 celery 39654943
  1877. 37 13601 handgun 5987435
  1878. 37 13602 foldout 28357832
  1879. 37 13603 mystic 39654943
  1880. 37 13801 intelligibility 5987435
  1881. 37 13802 Augustine 28357832
  1882. 37 13803 teethe 39654943
  1883. 37 13901 scholastics 5987435
  1884. 37 16001 audiology 5987435
  1885. 37 16201 wallet 5987435
  1886. 37 16202 parters 28357832
  1887. 37 16301 eschew 5987435
  1888. 37 16302 quitter 28357832
  1889. 37 16303 neat 39654943
  1890. 37 18001 jarring 5987435
  1891. 37 18002 tinily 28357832
  1892. 37 18003 balled 39654943
  1893. 37 18012 impulsive 28357832
  1894. 37 18013 starlet 39654943
  1895. 37 18021 lawgiver 5987435
  1896. 37 18022 stated 28357832
  1897. 37 18023 readable 39654943
  1898. 37 18032 testicle 28357832
  1899. 37 18033 Parsifal 39654943
  1900. 37 18041 Punjab 5987435
  1901. 37 18042 Merritt 28357832
  1902. 37 18043 Quixotism 39654943
  1903. 37 18051 sureties 5987435
  1904. 37 18052 puddings 28357832
  1905. 37 18053 tapestry 39654943
  1906. 37 18061 trimmings 5987435
  1907. 37 18062 humility 28357832
  1908. 37 18101 tragedies 5987435
  1909. 37 18102 skulking 28357832
  1910. 37 18103 flint 39654943
  1911. 37 18201 relaxing 5987435
  1912. 37 18202 offload 28357832
  1913. 37 18402 suites 28357832
  1914. 37 18403 lists 39654943
  1915. 37 18601 vacuuming 5987435
  1916. 37 18602 dentally 28357832
  1917. 37 18603 humanness 39654943
  1918. 37 18801 inch 5987435
  1919. 37 18802 Weissmuller 28357832
  1920. 37 18803 irresponsibly 39654943
  1921. 37 18811 repetitions 5987435
  1922. 37 18812 Antares 28357832
  1923. 37 19101 ventilate 5987435
  1924. 37 19102 pityingly 28357832
  1925. 37 19103 interdependent 39654943
  1926. 37 19201 Graves 5987435
  1927. 37 30501 neonatal 5987435
  1928. 37 30502 scribbled 28357832
  1929. 37 30503 chafe 39654943
  1930. 37 31901 realtor 5987435
  1931. 37 36001 elite 5987435
  1932. 37 36002 funereal 28357832
  1933. 37 38001 Conley 5987435
  1934. 37 38002 lectured 28357832
  1935. 37 38003 Abraham 39654943
  1936. 37 38011 groupings 5987435
  1937. 37 38012 dissociate 28357832
  1938. 37 38013 coexist 39654943
  1939. 37 38101 rusting 5987435
  1940. 37 38102 galling 28357832
  1941. 37 38103 obliterates 39654943
  1942. 37 38201 resumes 5987435
  1943. 37 38202 analyzable 28357832
  1944. 37 38203 terminator 39654943
  1945. select sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 512 and t3.t2nr = 38008 and t2.fld1 = 38008 or t2.fld1= t3.t2nr and t3.t2nr = 38008 and t2.fld1 = 38008;
  1946. sum(price)
  1947. 234298
  1948. select t2.fld1,sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 512 and t3.t2nr = 38008 and t2.fld1 = 38008 or t2.fld1 = t3.t2nr and t3.t2nr = 38008 and t2.fld1 = 38008 or t3.t2nr = t2.fld1 and t2.fld1 = 38008 group by t2.fld1;
  1949. fld1 sum(price)
  1950. 038008 234298
  1951. explain select fld3 from t2 where 1>2 or 2>3;
  1952. id select_type table type possible_keys key key_len ref rows Extra
  1953. 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL Impossible WHERE
  1954. explain select fld3 from t2 where fld1=fld1;
  1955. id select_type table type possible_keys key key_len ref rows Extra
  1956. 1 SIMPLE t2 ALL NULL NULL NULL NULL 1199
  1957. select companynr,fld1 from t2 HAVING fld1=250501 or fld1=250502;
  1958. companynr fld1
  1959. 34 250501
  1960. 34 250502
  1961. select companynr,fld1 from t2 WHERE fld1>=250501 HAVING fld1<=250502;
  1962. companynr fld1
  1963. 34 250501
  1964. 34 250502
  1965. select companynr,count(*) as count,sum(fld1) as sum from t2 group by companynr having count > 40 and sum/count >= 120000;
  1966. companynr count sum
  1967. 00 82 10355753
  1968. 29 95 14473298
  1969. 34 70 17788966
  1970. 37 588 83602098
  1971. 41 52 12816335
  1972. select companynr from t2 group by companynr having count(*) > 40 and sum(fld1)/count(*) >= 120000 ;
  1973. companynr
  1974. 00
  1975. 29
  1976. 34
  1977. 37
  1978. 41
  1979. select t2.companynr,companyname,count(*) from t2,t4 where t2.companynr=t4.companynr group by companyname having t2.companynr >= 40;
  1980. companynr companyname count(*)
  1981. 68 company 10 12
  1982. 50 company 11 11
  1983. 40 company 5 37
  1984. 41 company 6 52
  1985. 53 company 7 4
  1986. 58 company 8 23
  1987. 65 company 9 10
  1988. select count(*) from t2;
  1989. count(*)
  1990. 1199
  1991. select count(*) from t2 where fld1 < 098024;
  1992. count(*)
  1993. 387
  1994. select min(fld1) from t2 where fld1>= 098024;
  1995. min(fld1)
  1996. 98024
  1997. select max(fld1) from t2 where fld1>= 098024;
  1998. max(fld1)
  1999. 1232609
  2000. select count(*) from t3 where price2=76234234;
  2001. count(*)
  2002. 4181
  2003. select count(*) from t3 where companynr=512 and price2=76234234;
  2004. count(*)
  2005. 4181
  2006. explain select min(fld1),max(fld1),count(*) from t2;
  2007. id select_type table type possible_keys key key_len ref rows Extra
  2008. 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL Select tables optimized away
  2009. select min(fld1),max(fld1),count(*) from t2;
  2010. min(fld1) max(fld1) count(*)
  2011. 0 1232609 1199
  2012. select min(t2nr),max(t2nr) from t3 where t2nr=2115 and price2=823742;
  2013. min(t2nr) max(t2nr)
  2014. 2115 2115
  2015. select count(*),min(t2nr),max(t2nr) from t3 where name='spates' and companynr=78;
  2016. count(*) min(t2nr) max(t2nr)
  2017. 4181 4 41804
  2018. select t2nr,count(*) from t3 where name='gems' group by t2nr limit 20;
  2019. t2nr count(*)
  2020. 9 1
  2021. 19 1
  2022. 29 1
  2023. 39 1
  2024. 49 1
  2025. 59 1
  2026. 69 1
  2027. 79 1
  2028. 89 1
  2029. 99 1
  2030. 109 1
  2031. 119 1
  2032. 129 1
  2033. 139 1
  2034. 149 1
  2035. 159 1
  2036. 169 1
  2037. 179 1
  2038. 189 1
  2039. 199 1
  2040. select max(t2nr) from t3 where price=983543950;
  2041. max(t2nr)
  2042. 41807
  2043. select t1.period from t3 = t1 limit 1;
  2044. period
  2045. 1001
  2046. select t1.period from t1 as t1 limit 1;
  2047. period
  2048. 9410
  2049. select t1.period as "Nuvarande period" from t1 as t1 limit 1;
  2050. Nuvarande period
  2051. 9410
  2052. select period as ok_period from t1 limit 1;
  2053. ok_period
  2054. 9410
  2055. select period as ok_period from t1 group by ok_period limit 1;
  2056. ok_period
  2057. 9410
  2058. select 1+1 as summa from t1 group by summa limit 1;
  2059. summa
  2060. 2
  2061. select period as "Nuvarande period" from t1 group by "Nuvarande period" limit 1;
  2062. Nuvarande period
  2063. 9410
  2064. show tables;
  2065. Tables_in_test
  2066. t1
  2067. t2
  2068. t3
  2069. t4
  2070. show tables from test like "s%";
  2071. Tables_in_test (s%)
  2072. show tables from test like "t?";
  2073. Tables_in_test (t?)
  2074. show full columns from t2;
  2075. Field Type Collation Null Key Default Extra Privileges Comment
  2076. auto int(11) NULL NO PRI NULL auto_increment #
  2077. fld1 int(6) unsigned zerofill NULL NO UNI 000000 #
  2078. companynr tinyint(2) unsigned zerofill NULL NO 00 #
  2079. fld3 char(30) latin1_swedish_ci NO MUL #
  2080. fld4 char(35) latin1_swedish_ci NO #
  2081. fld5 char(35) latin1_swedish_ci NO #
  2082. fld6 char(4) latin1_swedish_ci NO #
  2083. show full columns from t2 from test like 'f%';
  2084. Field Type Collation Null Key Default Extra Privileges Comment
  2085. fld1 int(6) unsigned zerofill NULL NO UNI 000000 #
  2086. fld3 char(30) latin1_swedish_ci NO MUL #
  2087. fld4 char(35) latin1_swedish_ci NO #
  2088. fld5 char(35) latin1_swedish_ci NO #
  2089. fld6 char(4) latin1_swedish_ci NO #
  2090. show full columns from t2 from test like 's%';
  2091. Field Type Collation Null Key Default Extra Privileges Comment
  2092. show keys from t2;
  2093. Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
  2094. t2 0 PRIMARY 1 auto A 1199 NULL NULL BTREE
  2095. t2 0 fld1 1 fld1 A 1199 NULL NULL BTREE
  2096. t2 1 fld3 1 fld3 A NULL NULL NULL BTREE
  2097. drop table t4, t3, t2, t1;
  2098. CREATE TABLE t1 (
  2099. cont_nr int(11) NOT NULL auto_increment,
  2100. ver_nr int(11) NOT NULL default '0',
  2101. aufnr int(11) NOT NULL default '0',
  2102. username varchar(50) NOT NULL default '',
  2103. hdl_nr int(11) NOT NULL default '0',
  2104. eintrag date NOT NULL default '0000-00-00',
  2105. st_klasse varchar(40) NOT NULL default '',
  2106. st_wert varchar(40) NOT NULL default '',
  2107. st_zusatz varchar(40) NOT NULL default '',
  2108. st_bemerkung varchar(255) NOT NULL default '',
  2109. kunden_art varchar(40) NOT NULL default '',
  2110. mcbs_knr int(11) default NULL,
  2111. mcbs_aufnr int(11) NOT NULL default '0',
  2112. schufa_status char(1) default '?',
  2113. bemerkung text,
  2114. wirknetz text,
  2115. wf_igz int(11) NOT NULL default '0',
  2116. tarifcode varchar(80) default NULL,
  2117. recycle char(1) default NULL,
  2118. sim varchar(30) default NULL,
  2119. mcbs_tpl varchar(30) default NULL,
  2120. emp_nr int(11) NOT NULL default '0',
  2121. laufzeit int(11) default NULL,
  2122. hdl_name varchar(30) default NULL,
  2123. prov_hdl_nr int(11) NOT NULL default '0',
  2124. auto_wirknetz varchar(50) default NULL,
  2125. auto_billing varchar(50) default NULL,
  2126. touch timestamp NOT NULL,
  2127. kategorie varchar(50) default NULL,
  2128. kundentyp varchar(20) NOT NULL default '',
  2129. sammel_rech_msisdn varchar(30) NOT NULL default '',
  2130. p_nr varchar(9) NOT NULL default '',
  2131. suffix char(3) NOT NULL default '',
  2132. PRIMARY KEY (cont_nr),
  2133. KEY idx_aufnr(aufnr),
  2134. KEY idx_hdl_nr(hdl_nr),
  2135. KEY idx_st_klasse(st_klasse),
  2136. KEY ver_nr(ver_nr),
  2137. KEY eintrag_idx(eintrag),
  2138. KEY emp_nr_idx(emp_nr),
  2139. KEY wf_igz(wf_igz),
  2140. KEY touch(touch),
  2141. KEY hdl_tag(eintrag,hdl_nr),
  2142. KEY prov_hdl_nr(prov_hdl_nr),
  2143. KEY mcbs_aufnr(mcbs_aufnr),
  2144. KEY kundentyp(kundentyp),
  2145. KEY p_nr(p_nr,suffix)
  2146. ) ENGINE=MyISAM;
  2147. INSERT INTO t1 VALUES (3359356,405,3359356,'Mustermann Musterfrau',52500,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1485525,2122316,'+','','N',1909160,'MobilComSuper92000D2',NULL,NULL,'MS9ND2',3,24,'MobilCom Shop Koeln',52500,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
  2148. INSERT INTO t1 VALUES (3359357,468,3359357,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1503580,2139699,'+','','P',1909171,'MobilComSuper9D1T10SFreisprech(Akquise)',NULL,NULL,'MS9NS1',327,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
  2149. INSERT INTO t1 VALUES (3359358,407,3359358,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1501358,2137473,'N','','N',1909159,'MobilComSuper92000D2',NULL,NULL,'MS9ND2',325,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
  2150. INSERT INTO t1 VALUES (3359359,468,3359359,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1507831,2143894,'+','','P',1909162,'MobilComSuper9D1T10SFreisprech(Akquise)',NULL,NULL,'MS9NS1',327,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
  2151. INSERT INTO t1 VALUES (3359360,0,0,'Mustermann Musterfrau',29674907,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1900169997,2414578,'+',NULL,'N',1909148,'',NULL,NULL,'RV99066_2',20,NULL,'POS',29674907,NULL,NULL,20010202105916,'Mobilfunk','','','97317481','007');
  2152. INSERT INTO t1 VALUES (3359361,406,3359361,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag storniert','','(7001-84):Storno, Kd. möchte nicht mehr','privat',NULL,0,'+','','P',1909150,'MobilComSuper92000D1(Akquise)',NULL,NULL,'MS9ND1',325,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
  2153. INSERT INTO t1 VALUES (3359362,406,3359362,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1509984,2145874,'+','','P',1909154,'MobilComSuper92000D1(Akquise)',NULL,NULL,'MS9ND1',327,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
  2154. SELECT ELT(FIELD(kundentyp,'PP','PPA','PG','PGA','FK','FKA','FP','FPA','K','KA','V','VA',''), 'Privat (Private Nutzung)','Privat (Private Nutzung) Sitz im Ausland','Privat (geschaeftliche Nutzung)','Privat (geschaeftliche Nutzung) Sitz im Ausland','Firma (Kapitalgesellschaft)','Firma (Kapitalgesellschaft) Sitz im Ausland','Firma (Personengesellschaft)','Firma (Personengesellschaft) Sitz im Ausland','oeff. rechtl. Koerperschaft','oeff. rechtl. Koerperschaft Sitz im Ausland','Eingetragener Verein','Eingetragener Verein Sitz im Ausland','Typ unbekannt') AS Kundentyp ,kategorie FROM t1 WHERE hdl_nr < 2000000 AND kategorie IN ('Prepaid','Mobilfunk') AND st_klasse = 'Workflow' GROUP BY kundentyp ORDER BY kategorie;
  2155. Kundentyp kategorie
  2156. Privat (Private Nutzung) Mobilfunk
  2157. Warnings:
  2158. Warning 1052 Column 'kundentyp' in group statement is ambiguous
  2159. drop table t1;
  2160. SHOW STATUS LIKE 'Ssl_cipher';
  2161. Variable_name Value
  2162. Ssl_cipher DHE-RSA-AES256-SHA
  2163. SHOW STATUS LIKE 'Compression';
  2164. Variable_name Value
  2165. Compression ON