MySQL/Ruby
[English]
¤³¤ì¤Ï MySQL ¤Î Ruby API ¤Ç¤¹¡£MySQL ¤Î C API ¤È¤Û¤ÜƱÅù¤Îµ¡Ç½¤¬¤¢¤ê¤Þ¤¹¡£
¥À¥¦¥ó¥í¡¼¥É
ɬÍפʤâ¤Î
- MySQL 5.0.67
- Ruby 1.8.7, 1.9.1
¤³¤ì¤é°Ê³°¤Ç¤â make ¤Ç¤¤ë¤«¤â¤·¤ì¤Þ¤»¤ó¤¬¡¢³Îǧ¤·¤Æ¤Þ¤»¤ó¡£
¥é¥¤¥»¥ó¥¹
¤³¤Î¥×¥í¥°¥é¥à¤Ï Ruby ¥é¥¤¥»¥ó¥¹ ¤Ë½¾¤¤¤Þ¤¹¡£
¥¤¥ó¥¹¥È¡¼¥ë
¼¡¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£
% ruby extconf.rb
¤Þ¤¿¤Ï
% ruby extconf.rb --with-mysql-dir=/usr/local/mysql
¤Þ¤¿¤Ï
% ruby extconf.rb --with-mysql-config
¤½¤ì¤«¤é
% make
extconf.rb ¤Ë¤Ï¼¡¤Î¥ª¥×¥·¥ç¥ó¤ò»ØÄê¤Ç¤¤Þ¤¹¡£
- --with-mysql-include=dir
-
MySQL ¤Î¤Ø¥Ã¥À¥Õ¥¡¥¤¥ë¤Î¾ì½ê¤È¤·¤Æ /usr/local/include ¤ÎÂå¤ï¤ê¤Î¥Ç¥£¥ì¥¯¥È¥ê¤ò»ØÄꤷ¤Þ¤¹¡£
- --with-mysql-lib=dir
-
MySQL ¤Î¥é¥¤¥Ö¥é¥ê¤Î¾ì½ê¤È¤·¤Æ /usr/local/lib ¤ÎÂå¤ï¤ê¤Î¥Ç¥£¥ì¥¯¥È¥ê¤ò»ØÄꤷ¤Þ¤¹¡£
- --with-mysql-dir=dir
- --with-mysql-include=dir/include, --with-mysql-lib=dir/lib ¤ÈƱ¤¸¤Ç¤¹¡£
- --with-mysql-config[=/path/to/mysql_config]
- mysql_config ¥³¥Þ¥ó¥É¤Î·ë²Ì¤«¤é¥³¥ó¥Ñ¥¤¥ë¥Ñ¥é¥á¡¼¥¿¤òÆÀ¤Þ¤¹¡£
¼¡¤Ç´Êñ¤Ê¥Æ¥¹¥È¤¬¤Ç¤¤Þ¤¹¡£
% ruby ./test.rb -- [hostname [user [passwd [dbname [port [socket [flag]]]]]]]
test.rb ¤ËÍ¿¤¨¤ë°ú¿ô¤Ï Mysql.real_connect() ¤Î°ú¿ô¤ÈƱ¤¸¤Ç¤¹¡£
ÌäÂê¤Ê¤±¤ì¤Ð¡¢¥¹¡¼¥Ñ¡¼¥æ¡¼¥¶¤Ç¥¤¥ó¥¹¥È¡¼¥ë¤·¤Æ¤¯¤À¤µ¤¤¡£
# make install
Ãí°Õ
¥Æ¥¹¥È»þ¤Ë¥é¥¤¥Ö¥é¥ê libmysqlclient ¤¬¸«¤Ä¤«¤é¤Ê¤¤¤È¤¤¤¦¥¨¥é¡¼¤¬½Ð¤ë¾ì¹ç¤Ï¡¢make »þ¤Ë¥é¥¤¥Ö¥é¥ê¤Î¾ì½ê¤ò»ØÄꤹ¤ëɬÍפ¬¤¢¤ê¤Þ¤¹¡£¼¡¤Î¤è¤¦¤Ë¤·¤Æ make ¤·¤Æ¤ß¤Æ¤¯¤À¤µ¤¤¡£
% env LD_RUN_PATH=libmysqlclient.so¤Î¾ì½ê make
test.rb ¤Ï Linux ¾å¤Ç¤ÎÆ°ºî¤·¤«³Îǧ¤·¤Æ¤¤¤Þ¤»¤ó¡£
¾¤Î¥×¥é¥Ã¥È¥Õ¥©¡¼¥à¤Ç¤Ï¥¨¥é¡¼¤¬½Ð¤ë¤«¤â¤·¤ì¤Þ¤»¤ó¡£
»È¤¤Êý
¥á¥½¥Ã¥É̾¤Ï C API ¤Î´Ø¿ô¤«¤é mysql_ ÀÜƬ¼¤ò½ü¤¤¤¿¤â¤Î¤ÈƱ¤¸¤Ç¤¹¡£¥á¥½¥Ã¥É¤Î»ÈÍÑÊýË¡¤â´ðËÜŪ¤ËÂбþ¤¹¤ë C API ´Ø¿ô¤ÈƱÍͤǤ¹¤Î¤Ç¡¢¾ÜºÙ¤Ï MySQL ¤Î¥Þ¥Ë¥å¥¢¥ë¤ò¸«¤Æ¤¯¤À¤µ¤¤¡£
¥á¥½¥Ã¥ÉÃæ¤Ç¥¨¥é¡¼¤¬È¯À¸¤·¤¿¾ì¹ç¤Ï Mysql::Error Îã³°¤¬È¯À¸¤·¤Þ¤¹¡£
Æä˰ÕÌ£¤Î¤¢¤ëÃͤòÊÖ¤µ¤Ê¤¤´Ø¿ô¤Ï self ¤òÊÖ¤·¤Þ¤¹¡£
Mysql ¥¯¥é¥¹
MySQL ¤òÁàºî¤¹¤ë¤¿¤á¤Î¥¯¥é¥¹¤Ç¤¹¡£
¥¯¥é¥¹¥á¥½¥Ã¥É
- init()
-
Mysql ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£mysqld ¤ËÀܳ¤Ï¤·¤Þ¤»¤ó¡£
Mysql#options() ¤¬É¬Íפʾì¹ç¤Ï¡¢¤³¤ì¤ò¸Æ¤ó¤À¸å¤Ë¹Ô¤Ê¤¤¤Þ¤¹¡£
- real_connect(host=nil, user=nil, passwd=nil, db=nil, port=nil, sock=nil, flag=nil)
- connect(host=nil, user=nil, passwd=nil, db=nil, port=nil, sock=nil, flag=nil)
- new(host=nil, user=nil, passwd=nil, db=nil, port=nil, sock=nil, flag=nil)
-
mysqld ¤ËÀܳ¤·¡¢Mysql ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
flag ¤ÎÄê¿ô¤Ï C API ¤Î¤â¤Î¤ÈƱ¤¸¤Ç¤¹¡£
Îã) Mysql::CLIENT_FOUND_ROWS
- escape_string(str)
- quote(str)
-
insert, update ÍѤËʸ»úÎó¤ò¥¯¥ª¡¼¥È¤·¤Þ¤¹¡£
- get_client_info()
- client_info()
-
¥¯¥é¥¤¥¢¥ó¥È¥Ð¡¼¥¸¥ç¥ó¾ðÊó¤Îʸ»úÎó¤òÊÖ¤·¤Þ¤¹¡£
- get_client_version()
- client_version()
-
¥¯¥é¥¤¥¢¥ó¥È¥Ð¡¼¥¸¥ç¥ó¾ðÊó¤ò¿ôÃͤÇÊÖ¤·¤Þ¤¹¡£
- debug(str)
-
C API mysql_debug() ¤ÈƱ¤¸¡£
¥ª¥Ö¥¸¥§¥¯¥È¥á¥½¥Ã¥É
- options(opt, val=nil)
-
C API ¤Î mysql_options() ¤ÈƱ¤¸¤Ç¤¹¡£
opt ¤Ë»ØÄꤹ¤ëÄê¿ô¤Ï C API ¤«¤é MYSQL_ ÀÜƬ¼¤ò¼è¤ê½ü¤¤¤¿¤â¤Î¤Ç¤¹¡£
Îã) Mysql::OPT_CONNECT_TIMEOUT
- real_connect(host=nil, user=nil, passwd=nil, db=nil, port=nil, sock=nil, flag=nil)
- connect(host=nil, user=nil, passwd=nil, db=nil, port=nil, sock=nil, flag=nil)
-
Mysql.real_connect() ¤ÈƱ¤¸¤Ç¤¹¡£Mysql.init() ¤ÇÀ¸À®¤·¤¿¥ª¥Ö¥¸¥§¥¯¥È¤ò¥µ¡¼¥Ð¤ËÀܳ¤¹¤ë¤¿¤á¤Ë»ÈÍѤ·¤Þ¤¹¡£
- affected_rows()
-
±Æ¶Á¤µ¤ì¤¿¹Ô¿ô¤òÊÖ¤·¤Þ¤¹¡£
- autocommit(mode)
-
autocommit ¥â¡¼¥É¤ò mode ¤ËÀßÄꤷ¤Þ¤¹¡£mode ¤¬ nil, false, 0 ¤Î»þ¤Ï¥ª¥Õ¡¢¤½¤ì°Ê³°¤Î¾ì¹ç¤Ï¥ª¥ó¤Ç¤¹¡£
- change_user(user=nil, passwd=nil, db=nil)
-
Àܳ¥æ¡¼¥¶¤òÊѹ¹¤·¤Þ¤¹¡£
- character_set_name()
-
¸½ºß¤Îʸ»ú¥»¥Ã¥È¤òÊÖ¤·¤Þ¤¹¡£
- close()
-
Àܳ¤òÀÚÃǤ·¤Þ¤¹¡£
- commit()
-
¥È¥é¥ó¥¶¥¯¥·¥ç¥ó¤ò¥³¥ß¥Ã¥È¤·¤Þ¤¹¡£
- create_db(db)
-
¥Ç¡¼¥¿¥Ù¡¼¥¹¤òºîÀ®¤·¤Þ¤¹¡£
- drop_db(db)
-
¥Ç¡¼¥¿¥Ù¡¼¥¹¤òÇË´þ¤·¤Þ¤¹¡£
- dump_debug_info()
-
C API mysql_dump_debug_info() ¤ÈƱ¤¸¡£
- errno()
-
¥¨¥é¡¼ÈÖ¹æ¤òÊÖ¤·¤Þ¤¹¡£
- error()
-
¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¤òÊÖ¤·¤Þ¤¹¡£
- escape_string(str)
- quote(str)
-
insert, update ÍѤËʸ»úÎó¤ò¥¯¥ª¡¼¥È¤·¤Þ¤¹¡£
C API ¤Î mysql_real_escape_string() ¤ÈƱ¤¸¡£
- field_count()
-
ºÇ¸å¤Ë¼Â¹Ô¤µ¤ì¤¿¥¯¥¨¥ê¤Î¹àÌÜ¿ô¤òÊÖ¤·¤Þ¤¹¡£
- get_client_info()
- client_info()
-
¥¯¥é¥¤¥¢¥ó¥È¥Ð¡¼¥¸¥ç¥ó¾ðÊó¤Îʸ»úÎó¤òÊÖ¤·¤Þ¤¹¡£
- get_client_version()
- client_version()
-
¥¯¥é¥¤¥¢¥ó¥È¥Ð¡¼¥¸¥ç¥ó¾ðÊó¤ò¿ôÃͤÇÊÖ¤·¤Þ¤¹¡£
- get_host_info()
- host_info()
-
Àܳ¾ðÊó¤òʸ»úÎó¤ÇÊÖ¤·¤Þ¤¹¡£
- get_proto_info()
- proto_info()
-
Àܳ¥×¥í¥È¥³¥ë¥Ð¡¼¥¸¥ç¥ó¤ò¿ôÃͤÇÊÖ¤·¤Þ¤¹¡£
- get_server_info()
- server_info()
-
¥µ¡¼¥Ð¤Î¥Ð¡¼¥¸¥ç¥ó¾ðÊó¤òʸ»úÎó¤ÇÊÖ¤·¤Þ¤¹¡£
- get_server_version()
- server_version()
-
¥µ¡¼¥Ð¤Î¥Ð¡¼¥¸¥ç¥ó¾ðÊó¤ò¿ôÃͤÇÊÖ¤·¤Þ¤¹¡£
- info()
-
ľÁ°¤Î¥¯¥¨¥ê¤Î¾ðÊó¤òʸ»úÎó¤ÇÊÖ¤·¤Þ¤¹¡£Æä˾ðÊ󤬤ʤ±¤ì¤Ð nil ¤¬ÊÖ¤ê¤Þ¤¹¡£
- insert_id()
-
ºÇ¸å¤ËÀ¸À®¤µ¤ì¤¿ AUTO_INCREMENT ¹àÌܤÎÃͤòÊÖ¤·¤Þ¤¹¡£
- kill(id)
-
id ¤Ç»ØÄꤷ¤¿¥¹¥ì¥Ã¥É¤ò»¦¤·¤Þ¤¹¡£
- list_dbs(db=nil)
-
¥Ç¡¼¥¿¥Ù¡¼¥¹¤Î°ìÍ÷¤òÇÛÎó¤ÇÊÖ¤·¤Þ¤¹¡£
- list_fields(table, field=nil)
-
¥Æ¡¼¥Ö¥ëÆâ¤Î¹àÌܾðÊó¤Î°ìÍ÷¤ò¼¨¤¹ Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
- list_processes()
-
¥µ¡¼¥Ð¾å¤Î¸½ºß¤Î¥¹¥ì¥Ã¥É¤Î°ìÍ÷¤ò¼¨¤¹ Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
- list_tables(table=nil)
-
¥Æ¡¼¥Ö¥ë¤Î°ìÍ÷¤òÇÛÎó¤ÇÊÖ¤·¤Þ¤¹¡£
- more_results?()
-
¼èÆÀ¤·¤Æ¤¤¤Ê¤¤¥¯¥¨¥ê·ë²Ì¤¬¤¢¤ë¾ì¹ç¤Ï¿¿¤òÊÖ¤·¤Þ¤¹¡£
- next_result()
-
¼èÆÀ¤·¤Æ¤¤¤Ê¤¤¥¯¥¨¥ê·ë²Ì¤¬¤¢¤ë¾ì¹ç¤Ï¿¿¤òÊÖ¤·¤Þ¤¹¡£
¤³¤Î¸å¤Ë store_result() ¤ò¼Â¹Ô¤¹¤ë¤È¥¯¥¨¥ê·ë²Ì¤ò¼èÆÀ¤Ç¤¤Þ¤¹¡£
- ping()
-
¥µ¡¼¥Ð¤¬À¸¤¤Æ¤¤¤ë¤«¤É¤¦¤«¤ò¥Á¥§¥Ã¥¯¤·¤Þ¤¹¡£
- prepare(q)
-
¥¯¥¨¥ê¤ò¥µ¡¼¥Ð¤ËÁ÷¤ê¤Þ¤¹¡£¤³¤Î»þÅÀ¤Ç¤Ï¤Þ¤À¼Â¹Ô¤µ¤ì¤Þ¤»¤ó¡£
Mysql::Stmt ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
Mysql#stmt_init.prepare(q) ¤ÈƱ¤¸¤Ç¤¹¡£
- query(q)
- real_query(q)
-
¥¯¥¨¥ê¤ò¼Â¹Ô¤·¤Þ¤¹¡£
¥¯¥¨¥ê¤¬·ë²Ì¤òÊÖ¤¹¾ì¹ç¡¢¼«Æ°Åª¤Ë store_result() ¤â¼Â¹Ô¤·¤Æ¡¢Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
query_with_result ¤Ë false ¤¬ÀßÄꤵ¤ì¤Æ¤¤¤ì¤Ð¡¢store_result() ¤Ï¼Â¹Ô¤·¤Þ¤»¤ó¡£
- query(q) {|res| ...}
- real_query(q) {|res| ...}
-
¥¯¥¨¥ê¤ò¼Â¹Ô¤·¤Þ¤¹¡£
¥¯¥¨¥ê¤¬·ë²Ì¤òÊÖ¤¹¾ì¹ç¡¢Mysql::Result ¥ª¥Ö¥¸¥§¥¯¥È¤ò°ú¿ô¤È¤·¤Æ¥Ö¥í¥Ã¥¯¤ò¼Â¹Ô¤·¤Þ¤¹¡£
¥Ö¥í¥Ã¥¯½ªÎ»»þ¤Ë Mysql::Result ¥ª¥Ö¥¸¥§¥¯¥È¤Ï²òÊü¤µ¤ì¤Þ¤¹¡£
¥Þ¥ë¥Á¥¹¥Æ¡¼¥È¥á¥ó¥È¥â¡¼¥É¤Ç¡¢°ú¿ô¤Ë¡Ö;¡×¤Ç¶èÀÚ¤é¤ì¤¿Ê£¿ô¤Î¥¯¥¨¥ê¤ò»ØÄꤷ¤¿¾ì¹ç¤Ï¡¢¥¯¥¨¥ê¤Î¿ô¤À¤±¥Ö¥í¥Ã¥¯¤ò·«¤êÊÖ¤·¤Þ¤¹¡£
MySQL/Ruby 2.8 ¤«¤é¤Ï¡¢¼«Æ°Åª¤Ë¥Þ¥ë¥Á¥¹¥Æ¡¼¥È¥á¥ó¥È¥â¡¼¥É¤Ë¤Ï¤Ê¤é¤Ê¤¯¤Ê¤ê¤Þ¤·¤¿¡£
Mysql.connect ¤Î flag ¤Ë Mysql::CLIENT_MULTI_STATEMENTS ¤ò»ØÄꤹ¤ë¤«¡¢Mysql#set_server_option(Mysql::OPTION_MULTI_STATEMENTS_ON) ¤ò¼Â¹Ô¤·¤Æ¤¯¤À¤µ¤¤¡£
- refresh(r)
-
¥µ¡¼¥Ð¤Î¥í¥°¤ä¥¥ã¥Ã¥·¥åÅù¤ò¥Õ¥é¥Ã¥·¥å¤·¤Þ¤¹¡£
- reload()
-
¥¢¥¯¥»¥¹¸¢¥Æ¡¼¥Ö¥ë¤òºÆÆɤ߹þ¤ß¤·¤Þ¤¹¡£
- rollback()
-
¥È¥é¥ó¥¶¥¯¥·¥ç¥ó¤ò¥í¡¼¥ë¥Ð¥Ã¥¯¤·¤Þ¤¹¡£
- select_db(db)
-
¥Ç¡¼¥¿¥Ù¡¼¥¹¤òÁªÂò¤·¤Þ¤¹¡£
- set_server_option(opt)
-
°ú¿ô¤Ç»ØÄꤷ¤¿¥ª¥×¥·¥ç¥ó¤ò¥µ¡¼¥Ð¤ËÀßÄꤷ¤Þ¤¹¡£
°ú¿ô¤Ë¤Ï¡¢Mysql::OPTION_MULTI_STATEMENTS_ON, Mysql::OPTION_MULTI_STATEMENTS_OFF ¤¬»ØÄê¤Ç¤¤Þ¤¹¡£
- shutdown()
-
¥µ¡¼¥Ð¤òÄä»ß¤·¤Þ¤¹¡£
- ssl_set(key=nil, cert=nil, ca=nil, capath=nil, cipher=nil)
-
SSLÀܳ¤ò»ÈÍѤ·¤Þ¤¹¡£Mysql.init() ¸å¡¢Mysql#connect() Á°¤Ë¹Ô¤Ê¤¦É¬Íפ¬¤¢¤ê¤Þ¤¹¡£
- stat()
-
¥µ¡¼¥Ð¤Î¾õÂÖ¤òʸ»úÎó¤ÇÊÖ¤·¤Þ¤¹¡£
- stmt_init()
-
Mysql::Stmt ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
- store_result()
-
¥¯¥¨¥ê¤Î·ë²Ì¤Î Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
- thread_id()
-
¸½ºß¤ÎÀܳ¤Î¥¹¥ì¥Ã¥ÉID¤òÊÖ¤·¤Þ¤¹¡£
- use_result()
-
¥¯¥¨¥ê¤Î·ë²Ì¤Î Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
- warning_count()
-
ľÁ°¤Î¥¯¥¨¥ê¤Î·Ù¹ð¿ô¤òÊÖ¤·¤Þ¤¹¡£
¥ª¥Ö¥¸¥§¥¯¥ÈÊÑ¿ô
- query_with_result
-
true ¤ËÀßÄꤹ¤ë¤È query() »þ¤Ë store_result() ¤â¼Â¹Ô¤·¤Æ¡¢Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
false ¤ËÀßÄꤹ¤ë¤È¤½¤ÎÆ°ºî¤Ï¹Ô¤ï¤ì¤Þ¤»¤ó¡£¥Ç¥Õ¥©¥ë¥È¤Ï true ¤Ç¤¹¡£
- reconnect
-
true ¤ËÀßÄꤹ¤ë¤È MySQL ¥µ¡¼¥Ð¤È¤ÎÀܳ¤¬Àڤ줿¤È¤¤Ë¼«Æ°Åª¤ËºÆÀܳ¤·¤Þ¤¹¡£
¥Ç¥Õ¥©¥ë¥È¤Ï false ¤Ç¤¹¡£
Mysql::Result ¥¯¥é¥¹
¥¯¥¨¥ê·ë²Ì¤Î¥¯¥é¥¹¤Ç¤¹¡£
¥ª¥Ö¥¸¥§¥¯¥È¥á¥½¥Ã¥É
- free()
-
·ë²Ì¥Æ¡¼¥Ö¥ëÍÑ¥á¥â¥ê¤ò²òÊü¤·¤Þ¤¹¡£
- data_seek(offset)
-
¸½ºß¤Î¹Ô¤Î°ÌÃÖ¤ò offset ÈÖÌܤιԤˤ·¤Þ¤¹¡£
- fetch_field()
-
¸½ºß¤Î¹àÌܤΠMysql::Field ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
¼¡¤Ë¸Æ¤Ð¤ì¤¿»þ¤Ï¼¡¤Î¹àÌܤòÊÖ¤·¤Þ¤¹¡£
- fetch_fields()
-
¹àÌÜÁ´ÂΤòɽ¤¹ Mysql::Field ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤ÎÇÛÎó¤òÊÖ¤·¤Þ¤¹¡£
- fetch_field_direct(fieldnr)
-
fieldnr ÈÖÌܤιàÌܤΠMysql::Field ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤òÊÖ¤·¤Þ¤¹¡£
- fetch_lengths()
-
¸½ºß¤Î¹Ô¤Î³Æ¹àÌÜÃͤÎŤµ¤ÎÇÛÎó¤òÊÖ¤·¤Þ¤¹¡£
- fetch_row()
-
¸¡º÷·ë²Ì¤Î£±¹Ô¤òÊÖ¤·¤Þ¤¹¡£¼¡¤Ë¸Æ¤Ð¤ì¤¿»þ¤Ï¼¡¤Î¹Ô¤òÊÖ¤·¤Þ¤¹¡£
Ìá¤êÃͤϹàÌÜÃͤÎÇÛÎó¤Ç¤¹¡£
- fetch_hash(with_table=false)
-
¸¡º÷·ë²Ì¤Î£±¹Ô¤òÊÖ¤·¤Þ¤¹¡£¼¡¤Ë¸Æ¤Ð¤ì¤¿»þ¤Ï¼¡¤Î¹Ô¤òÊÖ¤·¤Þ¤¹¡£
Ìá¤êÃͤϹàÌÜ̾¤ò¥¡¼¤È¤·¤¿¹àÌÜÃͤΥϥå·¥å¤Ç¤¹¡£
with_table ¤¬ true ¤Î¾ì¹ç¤Ï¥¡¼¤Ë¥Æ¡¼¥Ö¥ë̾¤âÉղ䵤졢"¥Æ¡¼¥Ö¥ë̾.¹àÌÜ̾" ¤È¤¤¤¦·Á¼°¤Î¥¡¼¤Ë¤Ê¤ê¤Þ¤¹¡£
- field_seek(offset)
-
¸½ºß¤Î¹àÌÜ°ÌÃÖ¤ò offset ÈÖÌܤιàÌܤˤ·¤Þ¤¹¡£
- field_tell()
-
¸½ºß¤Î¹àÌܤΰÌÃÖ¤òÊÖ¤·¤Þ¤¹¡£
- num_fields()
-
¹àÌÜ¿ô¤òÊÖ¤·¤Þ¤¹¡£
- num_rows()
-
¸¡º÷·ï¿ô¤òÊÖ¤·¤Þ¤¹¡£
- row_seek(offset)
-
¸½ºß¤Î¹Ô¤Î°ÌÃÖ¤òÀßÄꤷ¤Þ¤¹¡£
offset ¤ÏÆâÉôɽ¸½¤Ç row_tell() ¤¬ÊÖ¤·¤¿ Mysql::RowOffset ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤Ç¤¹¡£
- row_tell()
-
¸½ºß¤Î¹Ô¤Î°ÌÃÖ¤ò Mysql::RowOffset ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤ÇÊÖ¤·¤Þ¤¹¡£
¥¤¥Æ¥ì¡¼¥¿
- each() {|x| ¡Á}
-
¸¡º÷·ë²Ì¤Î³Æ¹Ô¤´¤È¤Ë {¡Á} ¤ò·«¤êÊÖ¤·¤Þ¤¹¡£x ¤Ï¹àÌÜÃͤÎÇÛÎó¤Ç¤¹¡£
- each_hash(with_table=false) {|x| ¡Á}
-
¸¡º÷·ë²Ì¤Î³Æ¹Ô¤´¤È¤Ë {¡Á} ¤ò·«¤êÊÖ¤·¤Þ¤¹¡£
x ¤Ï¹àÌÜ̾¤ò¥¡¼¤È¤·¤¿¹àÌÜÃͤΥϥå·¥å¤Ç¤¹¡£
with_table ¤¬ true ¤Î¾ì¹ç¤Ï¥¡¼¤Ë¥Æ¡¼¥Ö¥ë̾¤âÉղ䵤졢"¥Æ¡¼¥Ö¥ë̾.¹àÌÜ̾" ¤È¤¤¤¦·Á¼°¤Î¥¡¼¤Ë¤Ê¤ê¤Þ¤¹¡£
Mysql::Field ¥¯¥é¥¹
¹àÌܤξܺ٤òɽ¤¹¥¯¥é¥¹¤Ç¤¹¡£C API ¤È°Û¤Ê¤ê¡¢¥ª¥Ö¥¸¥§¥¯¥È¤Ï Mysql::Result ¤È¤ÏÆÈΩ¤·¤Æ¸ºß¤¹¤ë¤Î¤Ç¡¢Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤¬²òÊü¤µ¤ì¤¿¸å¤Ç¤âÍøÍѤǤ¤Þ¤¹¡£¤¬¡¢¤½¤Î¤¿¤á C API ¤è¤ê¤â¥á¥â¥ê¤ò»ÈÍѤ·¤Þ¤¹¡£
¥ª¥Ö¥¸¥§¥¯¥ÈÊÑ¿ô(Æɤ߽Ф·¤Î¤ß)
- name
- ¹àÌÜ̾
- table
- ¥Æ¡¼¥Ö¥ë̾
- def
- ¥Ç¥Õ¥©¥ë¥ÈÃÍ
- type
- ¹àÌܤη¿
- length
- ¹àÌܤÎŤµ
- max_length
- ¸¡º÷·ë²ÌÃæ¤Î¹àÌÜÃͤκÇÂçĹ
- flags
- ¥Õ¥é¥°
- decimals
- ¾®¿ôÉô·å¿ô
type ¤ËÂбþ¤¹¤ëÄê¿ô¤Ï C API ¤Î¤â¤Î¤«¤é FIELD_ ÀÜƬ¼¤ò½ü¤¤¤¿¤â¤Î¤Ç¤¹¡£
Îã) Mysql::Field::TYPE_STRING
flag ¤ËÂбþ¤¹¤ëÄê¿ô¤Ï C API ¤Î¤â¤Î¤ÈƱ¤¸¤Ç¤¹¡£
Îã) Mysql::Field::BLOB_FLAG
¥ª¥Ö¥¸¥§¥¯¥È¥á¥½¥Ã¥É
- hash()
-
¾åµ¤ÎÊÑ¿ô̾¤ò¥¡¼¤È¤¹¤ë¥Ï¥Ã¥·¥å¤òÊÖ¤·¤Þ¤¹¡£
Îã) obj.name == obj.hash['name']
- is_not_null?()
-
¥Õ¥£¡¼¥ë¥É¤¬ "NOT NULL" ¤ÈÄêµÁ¤µ¤ì¤Æ¤¤¤ì¤Ð¿¿¤òÊÖ¤·¤Þ¤¹¡£
- is_num?()
-
¥Õ¥£¡¼¥ë¥É¤¬¿ôÃͤξì¹ç¤Ï¿¿¤òÊÖ¤·¤Þ¤¹¡£
- is_pri_key?()
-
¥Õ¥£¡¼¥ë¥É¤¬¥×¥é¥¤¥Þ¥ê¥¡¼¤Î¾ì¹ç¤Ï¿¿¤òÊÖ¤·¤Þ¤¹¡£
- inspect()
-
ʸ»úÎó "#<Mysql::Field:¹àÌÜ̾>" ¤òÊÖ¤·¤Þ¤¹¡£
Mysql::Stmt ¥¯¥é¥¹
MySQL ¤Ç¥×¥ê¥Ú¥¢¥É¥¹¥Æ¡¼¥È¥á¥ó¥È¤ò°·¤¦¤¿¤á¤Î¥¯¥é¥¹¤Ç¤¹¡£
»ÈÍÑÎã:
my = Mysql.new(hostname, username, password, databasename)
st = my.prepare("insert into tblname (col1,col2,col3) values (?,?,?)")
st.execute("abc",123,Time.now)
st.prepare("select col1,col2,col3 from tblname")
st.execute
st.fetch # => ["abc", 123, #<Mysql::Time:2005-07-24 23:52:55>]
st.close
¥ª¥Ö¥¸¥§¥¯¥È¥á¥½¥Ã¥É
- affected_rows()
-
±Æ¶Á¤µ¤ì¤¿¹Ô¿ô¤òÊÖ¤·¤Þ¤¹¡£
- bind_result(class, ...)
-
·ë²Ì¤òÊÖ¤¹¥¯¥¨¥ê¤Î¾ì¹ç¤Ë¡¢¼è¤ê½Ð¤µ¤ì¤ëÃͤΥ¯¥é¥¹¤ò»ØÄꤷ¤Þ¤¹¡£
»ØÄê¤Ç¤¤ë¥¯¥é¥¹¤Ï¡¢Numeric, Integer, Fixnum, Float, Mysql::Time ¤Ç¤¹¡£
nil ¤ò»ØÄꤹ¤ë¤È¡¢¼«Æ°È½Ê̤·¤Þ¤¹¡£
bind_result ¤ò¼Â¹Ô¤·¤Ê¤¤¾ì¹ç¤Ï¼«Æ°È½Ê̤·¤Þ¤¹¡£
- close()
-
Mysql::Stmt ¥ª¥Ö¥¸¥§¥¯¥È¤ò²òÊü¤·¤Þ¤¹¡£
- data_seek(offset)
-
¼¡¤Ë fetch() ¤Ç¼è¤ê½Ð¤µ¤ì¤ë¹Ô¤ò offset ÈÖÌܤιԤˤ·¤Þ¤¹¡£
offset ¤Ï 0 ¤«¤é»Ï¤Þ¤ê¤Þ¤¹¡£
- execute(arg, ...)
-
prepare() ¤·¤¿¥¯¥¨¥ê¤Ë¥Ñ¥é¥á¡¼¥¿¤òÍ¿¤¨¤Æ¼Â¹Ô¤·¤Þ¤¹¡£
- fetch()
-
execute() ¤Ç¼Â¹Ô¤·¤¿¥¯¥¨¥ê¤Î·ë²Ì¤ÎÃͤòÇÛÎó¤Ç¼è¤ê½Ð¤·¤Þ¤¹¡£
ÃͤòÊÖ¤µ¤Ê¤¤¥¯¥¨¥ê¤Î¾ì¹ç¤ä¡¢ºÇ¸å¤Þ¤Ç¼è¤ê½Ð¤·¤¿¾ì¹ç¤Ï nil ¤òÊÖ¤·¤Þ¤¹¡£
ÇÛÎó¤Î³ÆÍ×ÁÇ¤Ï MySQL ¤Î·¿¤Ë±þ¤¸¤Æ¼¡¤Î¤è¤¦¤Ë¤Ê¤ê¤Þ¤¹¡£
MySQL¤Î·¿ | Ruby¤Î¥¯¥é¥¹
|
---|
TINYINT, SMALLINT, MEDIUMINT, YEAR | Fixnum
|
INT, BIGINT | Fixnum¤Þ¤¿¤ÏBignum
|
FLOAT, DOUBLE | Float
|
DECIMAL | String
|
DATE, DATETIME, TIMESTAMP, TIME | Mysql::Time
|
CHAR, VARCHAR, BINARY, VARBINARY, TINYBLOB, TINYTEXT, TINYBLOB, TINYTEXT, MEDIUMBLOB, MEDIUMTEXT, LONGBLOB, LONGTEXT, ENUM, SET, BIT | String
|
NULL | NilClass
|
- field_count()
-
prepare ¤·¤¿¥¯¥¨¥ê¤¬ÊÖ¤¹·ë²Ì¤Î¥Õ¥£¡¼¥ë¥É¿ô¤òÊÖ¤·¤Þ¤¹¡£
- free_result()
-
¸¡º÷·ë²Ì¤ò²òÊü¤·¤Þ¤¹¡£
- insert_id()
-
À¸À®¤µ¤ì¤¿ AUTO_INCREMENT ¹àÌܤÎÃͤòÊÖ¤·¤Þ¤¹¡£
- num_rows()
-
¸¡º÷·ë²Ì¤Î¹Ô¿ô¤òÊÖ¤·¤Þ¤¹¡£
- param_count()
-
prepare() ¤·¤¿¥¯¥¨¥ê¤Î¥Ñ¥é¥á¡¼¥¿¡Ö?¡×¤Î¿ô¤òÊÖ¤·¤Þ¤¹¡£
- prepare(q)
-
¥¯¥¨¥ê¤ò¥µ¡¼¥Ð¤ËÁ÷¤ê¤Þ¤¹¡£¤³¤Î»þÅÀ¤Ç¤Ï¤Þ¤À¼Â¹Ô¤µ¤ì¤Þ¤»¤ó¡£
execute() ¤Ç¼Â¹Ô¤µ¤ì¤Þ¤¹¡£
- result_metadata()
-
prepare() ¤·¤¿¥¯¥¨¥ê¤ÎÊÖ¤µ¤ì¤ë·ë²Ì¤Î¥Õ¥£¡¼¥ë¥É¤ò Mysql::Result ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤ÇÊÖ¤·¤Þ¤¹¡£
- row_seek(offset)
-
¼¡¤Ë fetch() ¤Ç¼è¤ê½Ð¤µ¤ì¤ë¹Ô¤ò offset ¤Î°ÌÃ֤ˤ·¤Þ¤¹¡£
data_seek ¤È°Û¤Ê¤ê offset ¤Ï row_tell() ¤ÇÊÖ¤µ¤ì¤ë Mysql::RowOffset ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤Ç¤¹¡£
- row_tell()
-
¸½ºß¤Î¹Ô¤Î°ÌÃÖ¤ò Mysql::RowOffset ¥¯¥é¥¹¥ª¥Ö¥¸¥§¥¯¥È¤ÇÊÖ¤·¤Þ¤¹¡£
- sqlstate()
-
¥¨¥é¡¼¥³¡¼¥É¤ò SQLSTATE ʸ»úÎó¤ÇÊÖ¤·¤Þ¤¹¡£
¥¤¥Æ¥ì¡¼¥¿
- each() {|x| ¡Á}
-
¸¡º÷·ë²Ì¤Î³Æ¹Ô¤´¤È¤Ë {¡Á} ¤ò·«¤êÊÖ¤·¤Þ¤¹¡£
x ¤Ï fetch() ¤ÇÊÖ¤µ¤ì¤ë¤â¤Î¤ÈƱ¤¸ÇÛÎó¤Ç¤¹¡£
Mysql::Time ¥¯¥é¥¹
Mysql::Stmt ¤Ç»È¤ï¤ì¤ëÆü»þ¤òɽ¤¹¤¿¤á¤Î¥¯¥é¥¹¤Ç¤¹¡£
¥¯¥é¥¹¥á¥½¥Ã¥É
- new(year=0,month=0,day=0,hour=0,minute=0,second=0,neg=false,second_part=0)
-
Mysql::Time¥¯¥é¥¹¤òºîÀ®¤·¤Þ¤¹¡£
¥ª¥Ö¥¸¥§¥¯¥ÈÊÑ¿ô
- year
-
ǯ
- month
-
·î
- day
-
Æü
- hour
-
»þ
- minute
-
ʬ
- second
-
ÉÃ
- neg
-
»þ¹ï¤¬Àµ¤Î¾ì¹ç¤Ï false, Éé¤Î¾ì¹ç¤Ï true
- second_part
-
Éäξ®¿ôÅÀ°Ê²¼¡£Ì¤»ÈÍÑ
Mysql::Error ¥¯¥é¥¹
MySQL ¤Î¥¨¥é¡¼¤òɽ¤ï¤¹¥¯¥é¥¹¤Ç¤¹¡£
MySQL ¤Î¥¨¥é¡¼¤¬È¯À¸¤·¤¿¾ì¹ç¤ËÎã³°¤È¤·¤ÆÀ¸À®¤µ¤ì¤Þ¤¹¡£
¥ª¥Ö¥¸¥§¥¯¥ÈÊÑ¿ô(Æɤ߽Ф·¤Î¤ß)
- error
- ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸
- errno
- ¥¨¥é¡¼ÈÖ¹æ
errno ¤ËÂбþ¤¹¤ëÄê¿ô¤Ï C API ¤Î¤â¤Î¤ÈƱ¤¸¤Ç¤¹¡£
Îã) Mysql::Error::CR_UNKNOWN_HOST
ÍúÎò
- 2010-02-11
-
version 2.8.2
- Fix: Mysql#insert_id ¤¬ 2**32 °Ê¾å¤Î»þ¤ËÉÔÀµ¤ÊÃͤòÊÖ¤¹¡£
- 2009-02-01
-
version 2.8.1
- 2008-09-29
-
version 2.8
version 2.7.7
- MySQL¤Ø¤ÎÀܳ»þ¤Ë SIGVTALRM ¤Ç EINTR ¤Ë¤Ê¤ë¤³¤È¤¬¤¢¤ëÌäÂê¤ò½¤Àµ ([ruby-dev:31842])
- MySQL/Ruby 2.7.* ¤¬ Ruby 1.8.5 ¤Ç¥³¥ó¥Ñ¥¤¥ë¤Ç¤¤Ê¤«¤Ã¤¿¡£
- 2008-06-20
-
version 2.8pre4
- ¥¨¥é¡¼ÄêµÁ¥Õ¥¡¥¤¥ë¤ò³°¤À¤·¡£¤½¤Î¾¡£[ruby-dev:35152]
- 2008-06-17
-
version 2.8pre3
version 2.7.6
- 64bit ´Ä¶¤Ç Mysql::Stmt#execute ¤ÇÂ礤ʿôÃÍ(2**30 °Ê¾å)¤Ç¥¨¥é¡¼¤Ë¤Ê¤ëÌäÂê¤ò½¤Àµ¡£
- 2008-03-08
-
version 2.8pre2
version 2.7.5
- 64bit ´Ä¶¤Ç Mysql::Stmt#fetch ¤Ç¿ôÃͤ¬²õ¤ì¤ëÌäÂê¤ò½¤Àµ¡£
- 2007-12-26
-
version 2.8pre1
- Ruby 1.9.0 Âбþ
- Incompat: Mysql::Result#each_hash ¤¬¹ÔËè¤Ë¥«¥é¥à̾ʸ»úÎó¤òÀ¸À®¤¹¤ë¤Î¤Ç¤Ï¤Ê¤¯¡¢¶¦Í¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
- Incompat: ¥Ö¥í¥Ã¥¯¤Ä¤ Mysql#query ¤Ç¼«Æ°Åª¤Ë¥Þ¥ë¥Á¥¹¥Æ¡¼¥È¥á¥ó¥È¥â¡¼¥É¤Ë¤Ê¤é¤Ê¤¤¤è¤¦¤Ë¤·¤¿¡£
- 2007-08-22
-
version 2.7.4
- BUG: Mysql::Stmt#execute ¤¬¥á¥â¥ê¥ê¡¼¥¯¤·¤Æ¤¤¤¿¡£
- 2006-12-20
-
version 2.7.3
- BUG: ¥Ö¥í¥Ã¥¯¤Ä¤ Mysql#query ¤¬¡¢ºÇ¸å¤Î¥¯¥¨¥ê¤¬¥¨¥é¡¼¤Î¾ì¹ç¤ËÄä»ß¤·¤Æ¤·¤Þ¤¦¡£
- 2006-10-28
-
version 2.7.2
- BUG: ·ë²Ì¤òÊÖ¤µ¤Ê¤¤¥¯¥¨¥ê¤Ç Mysql::Stmt#result_metadata ¤¬ nil ¤òÊѤ¨¤¹¤è¤¦¤Ë¤·¤¿ (Thanks to Hidetoshi)
- BUG: Mysql#close ¤Ç mysql_errno ¤ò¸«¤Ê¤¤¤è¤¦¤ËÊѹ¹
- BUG: ¥Ö¥í¥Ã¥¯¤Ä¤ Mysql#query ¤ÇÊ£¿ô¥¹¥Æ¡¼¥È¥á¥ó¥È»þ¤Ë¥¨¥é¡¼¤ò̵»ë¤·¤Æ¤¤¤¿¡£
- extconf.rb ¤Î Visual C++ Âбþ (Thanks to Shugo Maeda)
- BIT·¿¤ËÂбþ
- Mysql::Field ¤Ë TYPE_BIT, TYPE_NEWDECIMAL ÄɲÃ
- 2006-06-04
-
version 2.7.1
- free() ¤ò xfree() ¤ËÊѹ¹¡£Windows ¤Ç¤Î¥¯¥é¥Ã¥·¥å¤Î²óÈò¤Î¤¿¤á¡£(Tobias Grimm ¤Ë´¶¼Õ)
- 2005-08-22
-
version 2.7
- Mysql#optionsÍÑÄê¿ôÄɲá£Mysql::OPT_GUESS_CONNECTION, Mysql::OPT_USE_EMBEDDED_CONNECTION, Mysql::OPT_USE_REMOTE_CONNECTION, Mysql::SET_CLIENT_IP
- test.rb: 4.0.x, 5.0.x Âбþ
- 2005-08-16
-
version 2.7-beta3
- Mysql::Stmt#bind_result ÄɲÃ
- 2005-08-02
-
version 2.7-beta2
- BUG: mysql.c.in: fetch_hash: Ãͤ¬ nil ¤ÎÍ×ÁǤ¬¥Ï¥Ã¥·¥å¤Ë´Þ¤Þ¤ì¤Ê¤¤¡£(Stefan Kaes ¤Ë´¶¼Õ)
- Äê¿ô Mysql::VERSION ÄɲÃ
- Mysql#prepare ÄɲÃ
- 2005-07-24
-
version 2.7-beta
- Mysql#stmt_init ÄɲÃ
- Mysql::Stmt, Mysql::Time, Mysql::RowOffset ¥¯¥é¥¹ÄɲÃ
- Mysql::Error#sqlstate ÄɲÃ
- Mysql::Result#row_seek,row_tell ¤¬°·¤¦ offset Ãͤò Mysql::RowOffset ¥ª¥Ö¥¸¥§¥¯¥È¤ËÊѹ¹
- 2005-07-31
-
version 2.6.3
- 2005-07-26
-
version 2.6.2
- BUG: mysql.c.in: fetch_hash: Ãͤ¬ nil ¤ÎÍ×ÁǤ¬¥Ï¥Ã¥·¥å¤Ë´Þ¤Þ¤ì¤Ê¤¤¡£(Stefan Kaes ¤Ë´¶¼Õ)
- 2005-06-28
-
version 2.6.1
- mysql.c.in: MacOSX ¤Ç¤Î¥³¥ó¥Ñ¥¤¥ë¥¨¥é¡¼¤ò½¤Àµ¡£
- 2005-04-25
-
version 2.6
- Mysql#option() ÍѤÎÄê¿ôÄɲÃ
Mysql::OPT_PROTOCOL, Mysql::OPT_READ_TIMEOUT,
Mysql::OPT_WRITE_TIMEOUT, Mysql::SET_CHARSET_DIR,
Mysql::SET_CHARSET_NAME, Mysql::SHARED_MEMORY_BASE_NAME,
Mysql::SECURE_AUTH
- Mysql#more_results?(), Mysql#next_result(),
Mysql#set_server_option(), Mysql#sqlstate() ÄɲÃ
- Mysql#connect() ¤Î¥Õ¥é¥°ÍÑÄê¿ôÄɲÃ
Mysql::CLIENT_MULTI_STATEMENTS, Mysql::CLIENT_MULTI_RESULTS
- Mysql#set_server_option() ÍѤÎÄê¿ôÄɲÃ
Mysql::OPTION_MULTI_STATEMENTS_ON,
Mysql::OPTION_MULTI_STATEMENTS_OFF
- ¥Ö¥í¥Ã¥¯ÉÕ¤ Mysql#query()
- Mysql#reconnect(), Mysql#reconnect=() ÄɲÃ
- MySQL ¤È¤ÎÀܳ¤¬Àڤ줿¤È¤¤Ë¡¢¥Ç¥Õ¥©¥ë¥È¤Ç¤ÏºÆÀܳ¤·¤Ê¤¤¤è¤¦¤Ë¤·¤¿¡£
- 2005-02-12
-
version 2.5.2
- BUG: Mysql#connect ¤ÇÀܳ¤¹¤ë¤ÈÀܳ¤¬ÀÚÃǤµ¤ì¤Ê¤¤¡£(Andres Salomon ¤Ë´¶¼Õ)
- 2004-09-20
-
version 2.5.1
- 2004-08-31
-
version 2.5
- MySQL 4.1.x Âбþ
- MysqlRes, MysqlField, MysqlError ¤ò Mysql::Result, Mysql::Field,
Mysql::Error ¤ËÊѹ¹¡£
- Mysql.client_version(), Mysql.get_client_version(),
Mysql#client_version(), Mysql#get_client_version(),
Mysql#server_version(), Mysql#get_server_version(),
Mysql#warning_count(), Mysql#commit(), Mysql#rollback(),
Mysql#autocommit() Äɲá£
- Mysql::Field#is_not_null?(), Mysql::Field#is_pri_key?(),
Mysql::Field#is_num?() Äɲá£
- MysqlField::TYPE_VAR_STRING Äɲá£
- 2003-08-10
-
version 2.4.5
- extconf.rb: MySQL 4.1 Âбþ¡£
- mysql.c.in: Ruby 1.8 Âбþ¡£
- 2003-02-23
-
version 2.4.4a
- extconf.rb ¤Î Ruby 1.8.0 Âбþ¡£
- 2003-01-29
-
version 2.4.4
- Mysql::OPT_LOCAL_INFILE ¤òÄɲá£
- extconf.rb ¤Ë --with-mysql-config ¥ª¥×¥·¥ç¥ó¤òÄɲÃ
- extconf.rb »þ¤Ë¼ç¤Ê¥é¥¤¥Ö¥é¥ê¤ò¼«Æ°¸¡½Ð¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
- 2003-01-05
-
version 2.4.3c
- ±Ñ¸ì¤Î README ¤Î²þÈÇ¡£Paul DuBois ¤Ë´¶¼Õ¡£
- 2002-12-24
-
version 2.4.3b
- extconf.rb ¤Î Ruby 1.6.8 Âбþ¡£
- 2002-11-07
-
version 2.4.3a
- ¥¨¥é¡¼Äê¿ô¤¬½ÅÊ£ÄêµÁ¤µ¤ì¤ë¤³¤È¤¬¤¢¤ë¥Ð¥°¤ò½¤Àµ¡£
- 2002-09-10
-
version 2.4.3
- ER_ ¤Ç»Ï¤Þ¤ë¥¨¥é¡¼Äê¿ô¤Ë¤âÂбþ¤·¤¿¡£
- errmsg.h ¤È mysqld_error.h ¤«¤é¼«Æ°Åª¤Ë¥¨¥é¡¼Äê¿ô¤ò¼èÆÀ¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
- 2002-01-07
-
version 2.4.2
- MySQL 4.0 Âбþ¡£
- uint ¤ò unsigned int ¤ËÊѹ¹¡ÊmswinÂбþ¡Ë¡£
- 2001-12-02
-
version 2.4.1
- ÉÔÍ×¤Ê extern ¤òºï½ü¡ÊCygiwnÂбþ¡Ë¡£
- extconf.rb ¤Î¥ª¥×¥·¥ç¥ó¤òÊѹ¹¡£
- 2001-10-12
-
version 2.4.0
- Ruby 1.7 ¤ËÂбþ¡£
- Mysql::debug(), Mysql#change_user(), Mysql#character_set_name(),
Mysql#dump_debug_info() ¤òÄɲá£
- 2001-03-25
-
version 2.3.2a
- t/50update.rb ¤ÎȽÄêÊýË¡¤òÊѹ¹
- 2001-03-19
-
version 2.3.2
- °ìÄê¿ô(20²ó) MysqlRes ¥ª¥Ö¥¸¥§¥¯¥È¤òÀ¸À®¤·¤¿¤é¡¢¶¯À©Åª¤Ë GC ¤¹¤ë¤è¤¦¤Ë¤·¤¿¡£
- Mysql#escape_string(), Mysql#quote() ¤Ï mysql_real_escape_string() ¤ò»ÈÍѤ¹¤ë¤è¤¦¤Ë¤·¤¿¡£
- 2000-09-02
-
version 2.3.1
- Mysql#initialize() ¤òÄɲÃ(Ruby 1.6 Âбþ)¡£
- 2000-07-22
-
version 2.3.0
- MysqlRes#free() ¤òÄɲá£
- Mysql#initialize(), MysqlRes#initialize() ¤ò͸ú¤Ë¤·¤¿¡£
- true ¤òÊÖ¤·¤Æ¤¤¤¿¥á¥½¥Ã¥É¤ò¡¢self ¤òÊÖ¤¹¤è¤¦¤Ë¤·¤¿¡£
- 2000-05-27
-
version 2.2.1a
- test.rb ¤ò°ú¿ô¤Ç¥Ñ¥é¥á¡¼¥¿¤ò»ØÄê¤Ç¤¤ë¤è¤¦¤Ë¤·¤¿¡£
- 2000-05-10
-
version 2.2.1
- ¥Ç¡¼¥¿¥Ù¡¼¥¹¤«¤é¤Î¥Ç¡¼¥¿¤ò¡Ö±øÀ÷¤µ¤ì¤¿¡×ʸ»úÎó¤ËÊѹ¹¡£
- ¥Æ¥¹¥È¥¹¥¯¥ê¥×¥ÈÄɲá£
- 1999-09-28
-
version 2.2.0
- Mysql::init(), Mysql#options(), Mysql#real_connect() ¤òÄɲá£
- Mysql#field_count ¤òÄɲá£
- 1999-09-24
-
version 2.1.7
- MySQL 3.22.26 ¤ËÂбþ¡£
- MysqlField#inspect() ¤òÄɲá£
- 1999-06-17
-
version 2.1.6
- fetch_field ¤ÇÍî¤Á¤ë¤³¤È¤¬¤¢¤Ã¤¿¡£
- 1999-06-12
-
version 2.1.5
- Ruby 1.3.x Âбþ¤¬ÃæÅÓȾü¤À¤Ã¤¿¡£
- 1999-05-30
-
version 2.1.4
- 1999-04-13
-
version 2.1.3
- fetch_hash/each_hash ¤Î°ú¿ô¤Î¿ô¤ÎÄêµÁ¤¬´Ö°ã¤Ã¤Æ¤¤¤¿¡£
- fetch_hash/each_hash ¤Ë true ¤ò»ØÄꤷ¤¿»þ¤Î¹àÌÜ̾¤¬·ç¤±¤Æ¤¤¤¿¡£
- NULLÃͤιàÌܤ¬¤¢¤ë¤È fetch_hash/each_hash ¤ÎÆ°¤¤¬¤ª¤«¤·¤«¤Ã¤¿¡£
- 1999-02-01
-
version 2.1.2
- Mysql#refresh() ¤È Mysql::REFRESH_* ¤òÄɲá£
- MySQL 3.21.xx ¤Ë¤âÂбþ(¤µ¤»¤¿¤Ä¤â¤ê¡Ä)¡£
- 1999-01-24
-
version 2.1.1
- MysqlError#error(), MysqlError#errno() ¤òÄɲá£
- MysqlError::CR_* ¤òÄɲá£
- 1999-01-17
-
version 2.1
- fetch_hash, each_hash ¤ò C ¥½¡¼¥¹¤Ë°ÜÆ°¡£
- MysqlField#hash() ¤òÄɲá£
- escape_string, get_client_info ¤ò¥ª¥Ö¥¸¥§¥¯¥È¥á¥½¥Ã¥É¤È¤·¤Æ¤â»È¤¨¤ë¤è¤¦¤Ë¤·¤¿¡£
- 1998-11-29
-
version 2.0.1
- fetch_hash, each_hash ¤Ë with_table °ú¿ô¤òÄɲá£
- ¤ä¤Ã¤Ñ¤ê get_* ¥á¥½¥Ã¥É̾¤â C API ¤ÈƱ¤¸¤Ë¤·¤¿¡£
- mysql-compat.rb ¤ò alias ¤Ç½ñ¤Ä¾¤·¤¿¡£
- Mysql ¤ÎÄê¿ô CLIENT_* ¤¬ MysqlField ¤ÎÄê¿ô¤Ë¤Ê¤Ã¤Æ¤¤¤¿¡£
- 1998-11-15
-
version 2.0
- ¥á¥½¥Ã¥É̾¤ò C API ¤ÈƱ¤¸¤Ë¤·¤¿¡£
- C++ ¤Ç¤âÄ̤ë¤è¤¦¤Ë½ñ¤Ä¾¤·¤¿¡£
- 1998-08-13
-
version 1.0
ºî¼Ô
e-mail: ¤È¤ß¤¿¤Þ¤µ¤Ò¤í [email protected]
http://tmtm.org
TOMITA Masahiro
Last modified: Sun Feb 1 17:48:26 JST 2009