1
DROP TABLE IF EXISTS `t1`;
3
Note 1051 Unknown table 't1'
4
select memc_servers_set('127.0.0.1:19191');
5
memc_servers_set('127.0.0.1:19191')
7
CREATE TABLE `t1` (id integer NOT NULL auto_increment primary key, bcol text);
8
INSERT INTO `t1` (bcol) values ('This documentation is NOT distributed under a GPL license. Use of this documentation is subject to the following terms: You may create a printed copy of this documentation solely for your own personal use. Conversion to other formats is allowed as long as the actual content is not altered or edited in any way. You shall not publish or distribute this documentation in any form or on any media, except if you distribute the documentation in a manner similar to how MySQL disseminates it (that is, electronically for download on a Web site with the software) or on a CD-ROM or similar medium, provided however that the documentation is disseminated together with the software on the same medium. Any other use, such as any dissemination of printed copies or use of this documentation, in whole or in part, in another publication, requires the prior written consent from an authorized representative of MySQL AB. MySQL AB reserves any and all rights to this documentation not expressly granted above.');
9
select memc_set('mysql:doc1', bcol) from t1;
10
memc_set('mysql:doc1', bcol)
12
select memc_get('mysql:doc1');
13
memc_get('mysql:doc1')
14
This documentation is NOT distributed under a GPL license. Use of this documentation is subject to the following terms: You may create a printed copy of this documentation solely for your own personal use. Conversion to other formats is allowed as long as the actual content is not altered or edited in any way. You shall not publish or distribute this documentation in any form or on any media, except if you distribute the documentation in a manner similar to how MySQL disseminates it (that is, electronically for download on a Web site with the software) or on a CD-ROM or similar medium, provided however that the documentation is disseminated together with the software on the same medium. Any other use, such as any dissemination of printed copies or use of this documentation, in whole or in part, in another publication, requires the prior written consent from an authorized representative of MySQL AB. MySQL AB reserves any and all rights to this documentation not expressly granted above.
15
select memc_delete('mysql:doc1');
16
memc_delete('mysql:doc1')
18
select memc_get('mysql:doc1');
19
memc_get('mysql:doc1')
21
select memc_set('spot:test', ' Spot ');
22
memc_set('spot:test', ' Spot ')
24
select memc_get('spot:test');
27
select memc_prepend('spot:test', 'See');
28
memc_prepend('spot:test', 'See')
30
select memc_get('spot:test');
33
select memc_append('spot:test', 'run.');
34
memc_append('spot:test', 'run.')
36
select memc_get('spot:test');
39
select memc_delete('spot:test');
40
memc_delete('spot:test')
42
select memc_set('increment:test', 1);
43
memc_set('increment:test', 1)
45
select memc_get('increment:test');
46
memc_get('increment:test')
48
select memc_increment('increment:test');
49
memc_increment('increment:test')
51
select memc_get('increment:test');
52
memc_get('increment:test')
54
select memc_increment('increment:test', 5);
55
memc_increment('increment:test', 5)
57
select memc_get('increment:test');
58
memc_get('increment:test')
60
select memc_increment('increment:test', 20);
61
memc_increment('increment:test', 20)
63
select memc_get('increment:test');
64
memc_get('increment:test')
66
select memc_decrement('increment:test', 20);
67
memc_decrement('increment:test', 20)
69
select memc_get('increment:test');
70
memc_get('increment:test')
72
select memc_decrement('increment:test');
73
memc_decrement('increment:test')
75
select memc_get('increment:test');
76
memc_get('increment:test')
78
select memc_delete('increment:test');
79
memc_delete('increment:test')
81
select memc_set('this_should_expire', '10 seconds', 10);
82
memc_set('this_should_expire', '10 seconds', 10)
84
select memc_get('this_should_expire');
85
memc_get('this_should_expire')
90
select memc_get('this_should_expire');
91
memc_get('this_should_expire')
96
select memc_get('this_should_expire');
97
memc_get('this_should_expire')
99
select memc_set('add:test', 'someval');
100
memc_set('add:test', 'someval')
102
select memc_add('add:test', 'someval');
103
memc_add('add:test', 'someval')
105
select memc_delete('add:test');
106
memc_delete('add:test')
108
select memc_add('add:test', 'someval');
109
memc_add('add:test', 'someval')
111
select memc_get('add:test');
114
select memc_delete('add:test');
115
memc_delete('add:test')
117
select memc_add('add:test', 'someval');
118
memc_add('add:test', 'someval')
120
select memc_get('add:test');
123
select memc_replace('replace:test', 'replaced');
124
memc_replace('replace:test', 'replaced')
126
select memc_set('replace:test', 'initial');
127
memc_set('replace:test', 'initial')
129
select memc_get('replace:test');
130
memc_get('replace:test')
132
select memc_replace('replace:test', 'replaced');
133
memc_replace('replace:test', 'replaced')
135
select memc_get('replace:test');
136
memc_get('replace:test')
138
select memc_replace('replace:test', 'replaced again');
139
memc_replace('replace:test', 'replaced again')
141
select memc_get('replace:test');
142
memc_get('replace:test')
144
select memc_delete('replace:test');
145
memc_delete('replace:test')
147
select memc_add_by_key('A', 'add:test', 'someval');
148
memc_add_by_key('A', 'add:test', 'someval')
150
select memc_get_by_key('A', 'add:test');
151
memc_get_by_key('A', 'add:test')
153
select memc_set_by_key('A', 'replace:test', 'initial');
154
memc_set_by_key('A', 'replace:test', 'initial')
156
select memc_get_by_key('A', 'replace:test');
157
memc_get_by_key('A', 'replace:test')
159
select memc_add_by_key('A', 'add:test', 'someotherval');
160
memc_add_by_key('A', 'add:test', 'someotherval')
162
select memc_get_by_key('A', 'add:test');
163
memc_get_by_key('A', 'add:test')
165
select memc_replace_by_key('A', 'replace:test', 'replaced');
166
memc_replace_by_key('A', 'replace:test', 'replaced')
168
select memc_get_by_key('A', 'replace:test');
169
memc_get_by_key('A', 'replace:test')
171
select memc_delete_by_key('A', 'replace:test');
172
memc_delete_by_key('A', 'replace:test')
174
select memc_get_by_key('A', 'replace:test');
175
memc_get_by_key('A', 'replace:test')
177
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_NO_BLOCK');
181
select memc_behavior_set('MEMCACHED_BEHAVIOR_NO_BLOCK', '1');
182
memc_behavior_set('MEMCACHED_BEHAVIOR_NO_BLOCK', '1')
184
select memc_behavior_get('MEMCACHED_BEHAVIOR_NO_BLOCK');
185
memc_behavior_get('MEMCACHED_BEHAVIOR_NO_BLOCK')
187
select memc_behavior_set('MEMCACHED_BEHAVIOR_NO_BLOCK', @behavior);
188
memc_behavior_set('MEMCACHED_BEHAVIOR_NO_BLOCK', @behavior)
190
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_SUPPORT_CAS');
194
select memc_behavior_set('MEMCACHED_BEHAVIOR_SUPPORT_CAS', '1');
195
memc_behavior_set('MEMCACHED_BEHAVIOR_SUPPORT_CAS', '1')
197
select memc_behavior_get('MEMCACHED_BEHAVIOR_SUPPORT_CAS');
198
memc_behavior_get('MEMCACHED_BEHAVIOR_SUPPORT_CAS')
200
select memc_behavior_set('MEMCACHED_BEHAVIOR_SUPPORT_CAS', @behavior);
201
memc_behavior_set('MEMCACHED_BEHAVIOR_SUPPORT_CAS', @behavior)
203
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_TCP_NODELAY');
204
select memc_behavior_set('MEMCACHED_BEHAVIOR_TCP_NODELAY', '1');
205
memc_behavior_set('MEMCACHED_BEHAVIOR_TCP_NODELAY', '1')
207
select memc_behavior_get('MEMCACHED_BEHAVIOR_TCP_NODELAY');
208
memc_behavior_get('MEMCACHED_BEHAVIOR_TCP_NODELAY')
210
select memc_behavior_set('MEMCACHED_BEHAVIOR_TCP_NODELAY', @behavior);
211
memc_behavior_set('MEMCACHED_BEHAVIOR_TCP_NODELAY', @behavior)
213
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS');
214
select memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', '1');
215
memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', '1')
217
select memc_behavior_get('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS');
218
memc_behavior_get('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS')
220
select memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', @behavior);
221
memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', @behavior)
223
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_USER_DATA');
224
select memc_behavior_set('MEMCACHED_BEHAVIOR_USER_DATA', '1');
225
memc_behavior_set('MEMCACHED_BEHAVIOR_USER_DATA', '1')
227
select memc_behavior_get('MEMCACHED_BEHAVIOR_USER_DATA');
228
memc_behavior_get('MEMCACHED_BEHAVIOR_USER_DATA')
230
select memc_behavior_set('MEMCACHED_BEHAVIOR_USER_DATA', @behavior);
231
memc_behavior_set('MEMCACHED_BEHAVIOR_USER_DATA', @behavior)
233
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_SORT_HOSTS');
234
select memc_behavior_set('MEMCACHED_BEHAVIOR_SORT_HOSTS', '1');
235
memc_behavior_set('MEMCACHED_BEHAVIOR_SORT_HOSTS', '1')
237
select memc_behavior_get('MEMCACHED_BEHAVIOR_SORT_HOSTS');
238
memc_behavior_get('MEMCACHED_BEHAVIOR_SORT_HOSTS')
240
select memc_behavior_set('MEMCACHED_BEHAVIOR_SORT_HOSTS', @behavior);
241
memc_behavior_set('MEMCACHED_BEHAVIOR_SORT_HOSTS', @behavior)
243
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_VERIFY_KEY');
244
select memc_behavior_set('MEMCACHED_BEHAVIOR_VERIFY_KEY', '1');
245
memc_behavior_set('MEMCACHED_BEHAVIOR_VERIFY_KEY', '1')
247
select memc_behavior_get('MEMCACHED_BEHAVIOR_VERIFY_KEY');
248
memc_behavior_get('MEMCACHED_BEHAVIOR_VERIFY_KEY')
250
select memc_behavior_set('MEMCACHED_BEHAVIOR_VERIFY_KEY', @behavior);
251
memc_behavior_set('MEMCACHED_BEHAVIOR_VERIFY_KEY', @behavior)
253
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_KETAMA');
254
select memc_behavior_set('MEMCACHED_BEHAVIOR_KETAMA', '1');
255
memc_behavior_set('MEMCACHED_BEHAVIOR_KETAMA', '1')
257
select memc_behavior_get('MEMCACHED_BEHAVIOR_KETAMA');
258
memc_behavior_get('MEMCACHED_BEHAVIOR_KETAMA')
260
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS');
261
select memc_behavior_set('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS', '1');
262
memc_behavior_set('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS', '1')
264
select memc_behavior_get('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS');
265
memc_behavior_get('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS')
267
select memc_behavior_set('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS', @behavior);
268
memc_behavior_set('MEMCACHED_BEHAVIOR_CACHE_LOOKUPS', @behavior)
270
set @behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS');
271
select memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', '1');
272
memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', '1')
274
select memc_behavior_get('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS');
275
memc_behavior_get('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS')
277
select memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', @behavior);
278
memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', @behavior)
280
set @preserve_behavior = memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
281
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_DEFAULT' );
282
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_DEFAULT' )
284
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
285
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
286
MEMCACHED_HASH_DEFAULT
287
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_MD5' );
288
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_MD5' )
290
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
291
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
293
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_CRC' );
294
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_CRC' )
296
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
297
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
299
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1_64' );
300
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1_64' )
302
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
303
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
304
MEMCACHED_HASH_FNV1_64
305
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1A_64' );
306
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1A_64' )
308
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
309
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
310
MEMCACHED_HASH_FNV1A_64
311
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1_32' );
312
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1_32' )
314
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
315
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
316
MEMCACHED_HASH_FNV1_32
317
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1A_32' );
318
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_FNV1A_32' )
320
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
321
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
322
MEMCACHED_HASH_FNV1A_32
323
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_JENKINS' );
324
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_JENKINS' )
326
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
327
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
328
MEMCACHED_HASH_JENKINS
329
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_HSIEH' );
330
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_HSIEH' )
332
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
333
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
334
MEMCACHED_HASH_JENKINS
335
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_MURMUR' );
336
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_MURMUR' )
338
select memc_behavior_get('MEMCACHED_BEHAVIOR_HASH');
339
memc_behavior_get('MEMCACHED_BEHAVIOR_HASH')
340
MEMCACHED_HASH_MURMUR
341
select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH', @preserve_behavior);
342
memc_behavior_set('MEMCACHED_BEHAVIOR_HASH', @preserve_behavior)
344
set @preserve_dist= memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION');
345
select memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', 'MEMCACHED_DISTRIBUTION_MODULA');
346
memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', 'MEMCACHED_DISTRIBUTION_MODULA')
348
select memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION');
349
memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION')
350
MEMCACHED_DISTRIBUTION_MODULA
351
select memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', 'MEMCACHED_DISTRIBUTION_CONSISTENT');
352
memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', 'MEMCACHED_DISTRIBUTION_CONSISTENT')
354
select memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION');
355
memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION')
356
MEMCACHED_DISTRIBUTION_CONSISTENT
357
select memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', 'MEMCACHED_DISTRIBUTION_CONSISTENT_KETAMA');
358
memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', 'MEMCACHED_DISTRIBUTION_CONSISTENT_KETAMA')
360
select memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION');
361
memc_behavior_get('MEMCACHED_BEHAVIOR_DISTRIBUTION')
362
MEMCACHED_DISTRIBUTION_CONSISTENT_KETAMA
363
select memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', @preserve_dist);
364
memc_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', @preserve_dist)
366
set @size = memc_behavior_get('MEMCACHED_BEHAVIOR_POLL_TIMEOUT');
370
select memc_behavior_set('MEMCACHED_BEHAVIOR_POLL_TIMEOUT', 100);
371
memc_behavior_set('MEMCACHED_BEHAVIOR_POLL_TIMEOUT', 100)
373
select memc_behavior_get('MEMCACHED_BEHAVIOR_POLL_TIMEOUT');
374
memc_behavior_get('MEMCACHED_BEHAVIOR_POLL_TIMEOUT')
376
select memc_behavior_set('MEMCACHED_BEHAVIOR_POLL_TIMEOUT', @size);
377
memc_behavior_set('MEMCACHED_BEHAVIOR_POLL_TIMEOUT', @size)
379
set @size = memc_behavior_get('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT');
383
select memc_behavior_set('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT', 5);
384
memc_behavior_set('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT', 5)
386
select memc_behavior_get('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT');
387
memc_behavior_get('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT')
389
select memc_behavior_set('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT', @size);
390
memc_behavior_set('MEMCACHED_BEHAVIOR_RETRY_TIMEOUT', @size)
392
set @size = memc_behavior_get('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK');
396
select memc_behavior_set('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK', 5);
397
memc_behavior_set('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK', 5)
399
select memc_behavior_get('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK');
400
memc_behavior_get('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK')
402
select memc_behavior_set('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK', @size);
403
memc_behavior_set('MEMCACHED_BEHAVIOR_IO_MSG_WATERMARK', @size)
405
set @size = memc_behavior_get('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK');
409
select memc_behavior_set('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK', 5);
410
memc_behavior_set('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK', 5)
412
select memc_behavior_get('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK');
413
memc_behavior_get('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK')
415
select memc_behavior_set('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK', @size);
416
memc_behavior_set('MEMCACHED_BEHAVIOR_IO_BYTES_WATERMARK', @size)