IT Talks/Database 3

[MySQL] INT ์ž๋ฃŒํ˜• (TINYINT / SMALLINT / MEDIUMINT / INT / BIGINT)

๋งค๋ฒˆ ๊ฒ€์ƒ‰ํ•˜๊ธฐ ๊ท€์ฐฎ์•„์„œ ํผ์˜ด ใ…Žใ…Ž Table 11.1 Required Storage and Range for Integer Types Supported by MySQL Type Storage (Bytes) ์ตœ์†Œ๊ฐ’ (signed) ์ตœ์†Œ๊ฐ’ (unsigned) ์ตœ๋Œ€๊ฐ’ (signed) ์ตœ๋Œ€๊ฐ’ (unsigned) TINYINT 1 -128 0 127 255 SMALLINT 2 -32768 0 32767 65535 MEDIUMINTINT 3 -8388608 0 8388607 16777215 INT 4 -2147483648 0 2147483647 4294967295 BIGINT 8 -2^63 0 2^63 - 1 2^64 - 1 * ์ถœ์ฒ˜ : https://dev.mysql.com/doc/refman/8.0/en/int..

IT Talks/Database 2023.07.23

๋น„๋ฐ€๋ฒˆํ˜ธ ์ž…๋ ฅ ์—†์ด MySQL ์ ‘์†ํ•˜๊ธฐ

MySQL ๋ฒ„์ „์ด ์ ์  ์˜ฌ๋ผ๊ฐ€๋ฉด์„œ ์–ธ์ œ๋ถ€ํ„ฐ์ธ๊ฐ€ mysql ๋ช…๋ น์–ด๋กœ ์ ‘์†์‹œ ๋น„๋ฐ€๋ฒˆํ˜ธ๋ฅผ ๊ฐ™์ด ์ž…๋ ฅํ•˜๋ฉด ์•„๋ž˜์™€ ๊ฐ™์ด ์•ˆ์ „ํ•˜์ง€ ์•Š๋‹ค๋Š” ๊ฒฝ๊ณ ๊ฐ€ ๋‚˜์˜จ๋‹ค. $ mysql -hlocalhost -udb_user -pdb_password mysql: [Warning] Using a password on the command line interface can be insecure. ์‰˜ ์Šคํฌ๋ฆฝํŠธ๋กœ DB ์ ‘์†ํ•˜๋Š” ์ž‘์—…์„ ํ•˜๋Š” ๊ฒฝ์šฐ ์œ„์™€ ๊ฐ™์ด ๋ช…๋ น์–ด์— ๋น„๋ฐ€๋ฒˆํ˜ธ๊นŒ์ง€ ๊ฐ™์ด ์ž…๋ ฅํ•˜๋Š” ๊ฒฝ์šฐ๊ฐ€ ๋งŽ์€๋ฐ ์‹คํ–‰์€ ๋˜์ง€๋งŒ ๊ฒฝ๊ณ ๊ฐ€ ๋‚˜์˜ค๋Š”๊ฒŒ ๋งค์šฐ ๊ฑฐ์Šฌ๋ฆฐ๋‹ค. ์ด๋Ÿฐ ๊ฒฝ์šฐ๋Š” ์•„๋ž˜ 2๊ฐ€์ง€ ๋ฐฉ๋ฒ•์œผ๋กœ ํ•ด๊ฒฐ์ด ๊ฐ€๋Šฅํ•˜๋‹ค. ๋ฐฉ๋ฒ•1) ๊ณ„์ • home path (๋ฆฌ๋ˆ…์Šค ๊ธฐ์ค€ /home/userid ๋“ฑ) ์— .my.cnf ํŒŒ์ผ์„ ์ƒ์„ฑํ•˜๊ณ  ์•„๋ž˜์™€ ๊ฐ™์ด ๋‚ด์šฉ์„ ์ž…๋ ฅํ•œ๋‹ค. ..

IT Talks/Database 2023.02.09

Sqlite ์ •๋ณด

๋งํฌ sqlite3 ํ™ˆํŽ˜์ด์ง€ : http://www.sqlite.org sqlite3 ํ‚ค์›Œ๋“œ : http://www.sqlite.org/lang_keywords.html KLDP sqlite3 : http://wiki.kldp.org/wiki.php/SQLite sqlite3 on rails : http://blog.superkdk.com/79 ๋ ˆ๋“œ์œ„ํ‚ค sqllite3 ์†Œ๊ฐœ : http://www.redwiki.net/wiki/wiki.php/SQLite sqlite/ruby faq : http://sqlite-ruby.rubyforge.org/sqlite3/faq.html sqlite basic sql ; http://www.shokhirev.com/nikolai/abc/sql/sql.html sqli..

IT Talks/Database 2010.04.06
728x90