rabbit-slide-tommy-mysql-sushi 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 2d7dfb132c7b45bf18e3ab6a85972a7da30db7b3
4
+ data.tar.gz: 1f19a6d78942d20730c80b75f7fabf77afad460f
5
+ SHA512:
6
+ metadata.gz: de4dfb16456cfc034257872b5fb61c3f728f85410dc612d6c97f65be4c54eca849f867bdd3b7eee7f1e9c47cb4185402609b4fa0cb0c174a1717616d19f9c842
7
+ data.tar.gz: 8188eeb441d4cea55c398707b92fd6c3db4d237e26864317c12d73a34bc68049d6592dd3421cd356574bd82dfa32fded0deef96d03fdd8acf878fd29b12db735
data/.rabbit ADDED
@@ -0,0 +1 @@
1
+ mysql-sushi.rab
@@ -0,0 +1,24 @@
1
+ = 🍣=🍺
2
+
3
+ MySQLでは🍣と🍺は同じ
4
+
5
+ == 作者向け
6
+
7
+ === 表示
8
+
9
+ rake
10
+
11
+ === 公開
12
+
13
+ rake publish
14
+
15
+ == 閲覧者向け
16
+
17
+ === インストール
18
+
19
+ gem install rabbit-slide-tommy-mysql-sushi
20
+
21
+ === 表示
22
+
23
+ rabbit rabbit-slide-tommy-mysql-sushi.gem
24
+
@@ -0,0 +1,24 @@
1
+ = 🍣=🍺
2
+
3
+ MySQLでは🍣と🍺は同じ
4
+
5
+ == 作者向け
6
+
7
+ ### 表示
8
+
9
+ rake
10
+
11
+ ### 公開
12
+
13
+ rake publish
14
+
15
+ ## 閲覧者向け
16
+
17
+ ### インストール
18
+
19
+ gem install rabbit-slide-tommy-sushi
20
+
21
+ ### 表示
22
+
23
+ rabbit rabbit-slide-tommy-sushi.gem
24
+
@@ -0,0 +1,17 @@
1
+ require "rabbit/task/slide"
2
+
3
+ # Edit ./config.yaml to customize meta data
4
+
5
+ spec = nil
6
+ Rabbit::Task::Slide.new do |task|
7
+ spec = task.spec
8
+ # spec.files += Dir.glob("doc/**/*.*")
9
+ # spec.files -= Dir.glob("private/**/*.*")
10
+ # spec.add_runtime_dependency("YOUR THEME")
11
+ end
12
+
13
+ desc "Tag #{spec.version}"
14
+ task :tag do
15
+ sh("git", "tag", "-a", spec.version.to_s, "-m", "Publish #{spec.version}")
16
+ sh("git", "push", "--tags")
17
+ end
@@ -0,0 +1,19 @@
1
+ ---
2
+ id: mysql-sushi
3
+ base_name: mysql-sushi
4
+ tags: []
5
+ presentation_date:
6
+ version: 1.0.0
7
+ licenses: []
8
+ slideshare_id:
9
+ speaker_deck_id:
10
+ ustream_id:
11
+ vimeo_id:
12
+ youtube_id:
13
+ author:
14
+ markup_language: :rd
15
+ name: "とみたまさひろ"
16
+ email: tommy@tmtm.org
17
+ rubygems_user: tommy
18
+ slideshare_user: tmtm
19
+ speaker_deck_user:
Binary file
@@ -0,0 +1,286 @@
1
+ = 🍣=🍺
2
+
3
+ :author
4
+ とみたまさひろ
5
+ :content_source
6
+ MyNA会
7
+ :date
8
+ 2015/04/22
9
+ :allotted-time
10
+ 45m
11
+ :theme
12
+ clear-blue+
13
+
14
+ = 自己紹介
15
+
16
+ # image
17
+ # src = icon.jpg
18
+ # relative-height = 30
19
+ # align = right
20
+ # relative-margin-top = -30
21
+ # relative-margin-right = -10
22
+
23
+ * とみた まさひろ
24
+ * http://((*tmtms*)).hatenablog.com
25
+ * http://twitter.com/((*tmtms*))
26
+ * https://github.com/((*tmtm*))
27
+ * MySQL 3.21 に日本語charsetを追加
28
+ * MySQLのRubyバインディング作成
29
+
30
+ = 自己紹介
31
+
32
+ * もっともRTされたツイート
33
+
34
+ # image
35
+ # src = サンチーム.png
36
+
37
+ = 自己紹介
38
+
39
+ * もっともブクマされたブログ
40
+
41
+ # image
42
+ # src = メールアドレス正規表現.png
43
+
44
+ = 自己紹介
45
+
46
+ * 長野県北部在住
47
+ * 日本MySQLユーザ会代表
48
+ * 名ばかり代表
49
+ * 「たまには何かしゃべれや (#゚Д゚)ゴルァ!!」\nと言われたのでしゃべります
50
+
51
+ = 🍣=🍺 問題
52
+
53
+ = MySQL的には🍣と🍺は同じ
54
+
55
+ # image
56
+ # src = 寿司=ビール.png
57
+
58
+ = ちなみに🍛と💩も(ry
59
+
60
+ = PostgreSQLなら問題ないらしい
61
+
62
+ # image
63
+ # src = postgresql.png
64
+ # relative_height = 90
65
+ (('note:http://soudai1025.blogspot.jp/2015/03/postgresqlunicode-6.html'))
66
+
67
+ = 何故?
68
+
69
+ = kamipo++
70
+
71
+ * (('tag:small:utf8_unicode_ci に対する日本の開発者の見解'))\n
72
+ (('tag:x-small:http://blog.kamipo.net/entry/2015/03/08/145045'))
73
+
74
+ * (('tag:small:MySQL と Unicode Collation Algorithm (UCA)'))\n
75
+ (('tag:x-small:http://blog.kamipo.net/entry/2015/03/17/103457'))
76
+
77
+ * (('tag:small:MySQL と寿司ビール問題'))\n
78
+ (('tag:x-small:http://blog.kamipo.net/entry/2015/03/23/093052'))
79
+
80
+ = MySQLの文字は Charset と Collation がある
81
+
82
+ = Charset
83
+
84
+ = いわゆる文字コード
85
+
86
+ = 文字のバイト表現
87
+
88
+ = Charset: utf8mb4
89
+
90
+ * 「A」 = 41
91
+
92
+ * 「あ」= E3 81 82
93
+
94
+ * 「🍣」= F0 9F 8D A3
95
+
96
+ * 「🍺」= F0 9F 8D BA
97
+
98
+ = Collation
99
+
100
+ = 文字の照合規則・照合順序
101
+
102
+ = Collation 一覧
103
+
104
+ mysql> show collation;
105
+ +--------------------------+----------+-----+---------+----------+---------+
106
+ | Collation | Charset | Id | Default | Compiled | Sortlen |
107
+ +--------------------------+----------+-----+---------+----------+---------+
108
+ | big5_chinese_ci | big5 | 1 | Yes | Yes | 1 |
109
+ | big5_bin | big5 | 84 | | Yes | 1 |
110
+ | dec8_swedish_ci | dec8 | 3 | Yes | Yes | 1 |
111
+ | dec8_bin | dec8 | 69 | | Yes | 1 |
112
+ | cp850_general_ci | cp850 | 4 | Yes | Yes | 1 |
113
+ | cp850_bin | cp850 | 80 | | Yes | 1 |
114
+ | hp8_english_ci | hp8 | 6 | Yes | Yes | 1 |
115
+ | hp8_bin | hp8 | 72 | | Yes | 1 |
116
+ | koi8r_general_ci | koi8r | 7 | Yes | Yes | 1 |
117
+ | koi8r_bin | koi8r | 74 | | Yes | 1 |
118
+ | latin1_german1_ci | latin1 | 5 | | Yes | 1 |
119
+ | latin1_swedish_ci | latin1 | 8 | Yes | Yes | 1 |
120
+ | latin1_danish_ci | latin1 | 15 | | Yes | 1 |
121
+ | latin1_german2_ci | latin1 | 31 | | Yes | 2 |
122
+ | latin1_bin | latin1 | 47 | | Yes | 1 |
123
+ | latin1_general_ci | latin1 | 48 | | Yes | 1 |
124
+ | latin1_general_cs | latin1 | 49 | | Yes | 1 |
125
+
126
+ = Charset 毎に Collation がある
127
+
128
+ = utf8mb4 の Collation
129
+
130
+ 全部で16個
131
+
132
+ mysql> show collation like 'utf8mb4%';
133
+ +------------------------+---------+-----+---------+----------+---------+
134
+ | Collation | Charset | Id | Default | Compiled | Sortlen |
135
+ +------------------------+---------+-----+---------+----------+---------+
136
+ | utf8mb4_general_ci | utf8mb4 | 45 | Yes | Yes | 1 |
137
+ | utf8mb4_bin | utf8mb4 | 46 | | Yes | 1 |
138
+ | utf8mb4_unicode_ci | utf8mb4 | 224 | | Yes | 8 |
139
+ | utf8mb4_icelandic_ci | utf8mb4 | 225 | | Yes | 8 |
140
+ | utf8mb4_latvian_ci | utf8mb4 | 226 | | Yes | 8 |
141
+ | utf8mb4_romanian_ci | utf8mb4 | 227 | | Yes | 8 |
142
+ | utf8mb4_slovenian_ci | utf8mb4 | 228 | | Yes | 8 |
143
+ | utf8mb4_polish_ci | utf8mb4 | 229 | | Yes | 8 |
144
+ | utf8mb4_estonian_ci | utf8mb4 | 230 | | Yes | 8 |
145
+ | utf8mb4_spanish_ci | utf8mb4 | 231 | | Yes | 8 |
146
+ | utf8mb4_swedish_ci | utf8mb4 | 232 | | Yes | 8 |
147
+
148
+ = utf8mb4 の Collation
149
+
150
+ | utf8mb4_turkish_ci | utf8mb4 | 233 | | Yes | 8 |
151
+ | utf8mb4_czech_ci | utf8mb4 | 234 | | Yes | 8 |
152
+ | utf8mb4_danish_ci | utf8mb4 | 235 | | Yes | 8 |
153
+ | utf8mb4_lithuanian_ci | utf8mb4 | 236 | | Yes | 8 |
154
+ | utf8mb4_slovak_ci | utf8mb4 | 237 | | Yes | 8 |
155
+ | utf8mb4_spanish2_ci | utf8mb4 | 238 | | Yes | 8 |
156
+ | utf8mb4_roman_ci | utf8mb4 | 239 | | Yes | 8 |
157
+ | utf8mb4_persian_ci | utf8mb4 | 240 | | Yes | 8 |
158
+ | utf8mb4_esperanto_ci | utf8mb4 | 241 | | Yes | 8 |
159
+ | utf8mb4_hungarian_ci | utf8mb4 | 242 | | Yes | 8 |
160
+ | utf8mb4_sinhala_ci | utf8mb4 | 243 | | Yes | 8 |
161
+ | utf8mb4_german2_ci | utf8mb4 | 244 | | Yes | 8 |
162
+ | utf8mb4_croatian_ci | utf8mb4 | 245 | | Yes | 8 |
163
+ | utf8mb4_unicode_520_ci | utf8mb4 | 246 | | Yes | 8 |
164
+ | utf8mb4_vietnamese_ci | utf8mb4 | 247 | | Yes | 8 |
165
+ +------------------------+---------+-----+---------+----------+---------+
166
+
167
+ = utf8mb4 の Collation
168
+
169
+ * utf8mb4_general_ci
170
+ * utf8mb4_bin
171
+ * utf8mb4_unicode_ci
172
+ * utf8mb4_unicode_520_ci
173
+ * utf8mb4_言語_ci\n(('tag:small:(utf8m4_japanese_ci は無い)'))
174
+
175
+ = utf8mb4_general_ci
176
+
177
+ * utf8mb4 charset のデフォルト collation
178
+ * ASCII大文字小文字を区別しない(A=a)\n
179
+ * 絵文字を((*区別しない*))(🍣=🍺)
180
+
181
+ = utf8mb4_bin
182
+
183
+ * varchar(99) binary
184
+ * 全文字を((*区別する*))(A≠a, 🍣≠🍺)
185
+ * PostgreSQLと同じならこれでいい
186
+
187
+ = utf8mb4_unicode_ci
188
+
189
+ * Unicode Collation Algorithm 4.0.0\n
190
+ (('note:http://www.unicode.org/reports/tr10/'))\n
191
+ (('note:http://dev.mysql.com/doc/refman/5.6/en/charset-unicode-sets.html'))
192
+ * ASCII大文字小文字を区別しない(A=a)
193
+ * 絵文字を((*区別しない*))(🍣=🍺)
194
+ * ひらがな、カタカナ、濁点有無、全角、半角を区別しない
195
+ (は=ば=ぱ=ハ=バ=パ=ハ)
196
+
197
+ = utf8mb4_unicode_520_ci
198
+
199
+ * Unicode Collation Algorithm 5.2.0
200
+ * ASCII大文字小文字を区別しない(A=a)
201
+ * 絵文字を((*区別する*))(🍣≠🍺)
202
+ * ひらがな、カタカナ、濁点有無、全角、半角を区別しない
203
+ (は=ば=ぱ=ハ=バ=パ=ハ)
204
+
205
+ = ハハ=パパ=ババ 問題
206
+
207
+ = utf8mb4_*_ci
208
+
209
+ # RT
210
+
211
+ Collation, A : a, 🍣 : 🍺, は : ぱ
212
+
213
+ general, =, =, ≠
214
+ bin, ≠, ≠, ≠
215
+ unicode, =, =, =
216
+ unicode_520, =, ≠, =
217
+
218
+ = ぼくらが本当に欲しかったもの
219
+
220
+ # RT
221
+
222
+ Collation, A : a, 🍣 : 🍺, は : ぱ
223
+
224
+ general, ((*=*)), =, ((*≠*))
225
+ bin, ≠, ((*≠*)), ((*≠*))
226
+ unicode, ((*=*)), =, =
227
+ unicode_520, ((*=*)), ((*≠*)), =
228
+ ((*japanese*)), ((*=*)), ((*≠*)), ((*≠*))
229
+
230
+ = だ、だれか utf8mb4_japanese_ci を作って (;´Д`)
231
+
232
+ = おまけ
233
+
234
+ = 同じ文字とみなされるかどうかは weight_string() で確かめられる
235
+
236
+ = utf8mb4_general_ci
237
+
238
+ mysql> select hex(weight_string('🍣' collate utf8mb4_general_ci));
239
+ +----------------------------------------------------+
240
+ | hex(weight_string('?' collate utf8mb4_general_ci)) |
241
+ +----------------------------------------------------+
242
+ | FFFD |
243
+ +----------------------------------------------------+
244
+
245
+ mysql> select hex(weight_string('🍺' collate utf8mb4_general_ci));
246
+ +----------------------------------------------------+
247
+ | hex(weight_string('?' collate utf8mb4_general_ci)) |
248
+ +----------------------------------------------------+
249
+ | FFFD |
250
+ +----------------------------------------------------+
251
+
252
+
253
+ = utf8mb4_unicode_520_ci
254
+
255
+ mysql> select hex(weight_string('🍣' collate utf8mb4_unicode_520_ci));
256
+ +--------------------------------------------------------+
257
+ | hex(weight_string('?' collate utf8mb4_unicode_520_ci)) |
258
+ +--------------------------------------------------------+
259
+ | FBC3F363 |
260
+ +--------------------------------------------------------+
261
+
262
+ mysql> select hex(weight_string('🍺' collate utf8mb4_unicode_520_ci));
263
+ +--------------------------------------------------------+
264
+ | hex(weight_string('?' collate utf8mb4_unicode_520_ci)) |
265
+ +--------------------------------------------------------+
266
+ | FBC3F37A |
267
+ +--------------------------------------------------------+
268
+
269
+
270
+ = おまけ2
271
+
272
+ = パ と パ
273
+
274
+ * utf8_unicode_ci では「パ」=「ハ」=「ハ」
275
+ * 「パ」は一文字、「パ」は二文字
276
+ * 'パ' LIKE 'パ' => 偽
277
+ * (('wait'))'パ' = 'パ' => ((*真*))
278
+
279
+ = = と LIKE は違うらしい
280
+
281
+ # blockquote
282
+ Per the SQL standard, LIKE performs matching on a per-character basis, thus it can produce results different from the = comparison operator
283
+
284
+ (('note:http://dev.mysql.com/doc/refman/5.6/en/string-comparison-functions.html#operator_like'))
285
+
286
+ = おわり
Binary file
metadata ADDED
@@ -0,0 +1,69 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: rabbit-slide-tommy-mysql-sushi
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - "とみたまさひろ"
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-04-22 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: rabbit
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 2.0.2
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: 2.0.2
27
+ description: "MySQLでは\U0001F363と\U0001F37Aは同じ"
28
+ email:
29
+ - tommy@tmtm.org
30
+ executables: []
31
+ extensions: []
32
+ extra_rdoc_files: []
33
+ files:
34
+ - ".rabbit"
35
+ - README.rd
36
+ - README.rd~
37
+ - Rakefile
38
+ - config.yaml
39
+ - icon.jpg
40
+ - mysql-sushi.rab
41
+ - pdf/mysql-sushi-mysql-sushi.pdf
42
+ - postgresql.png
43
+ - "サンチーム.png"
44
+ - "メールアドレス正規表現.png"
45
+ - "寿司=ビール.png"
46
+ homepage: http://slide.rabbit-shocker.org/authors/tommy/mysql-sushi/
47
+ licenses: []
48
+ metadata: {}
49
+ post_install_message:
50
+ rdoc_options: []
51
+ require_paths:
52
+ - lib
53
+ required_ruby_version: !ruby/object:Gem::Requirement
54
+ requirements:
55
+ - - ">="
56
+ - !ruby/object:Gem::Version
57
+ version: '0'
58
+ required_rubygems_version: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - ">="
61
+ - !ruby/object:Gem::Version
62
+ version: '0'
63
+ requirements: []
64
+ rubyforge_project:
65
+ rubygems_version: 2.4.5
66
+ signing_key:
67
+ specification_version: 4
68
+ summary: "\U0001F363=\U0001F37A"
69
+ test_files: []