Easy instant MySQL image for a coding test, classes, just playground, etc. You can use characters of utf-8, so you can input Japanese.
dockerdocker run -d --name playground -p 3306:3306 hpprc/mysql-playgrounddocker exec -it playground mysql -uroot -prootdocker exec -i -t playground bash
you can enter mysql to do this.
# inside container
mysql -uroot -proot
sample queries.
show databases;
# result
#
# +--------------------+
# | Database |
# +--------------------+
# | information_schema |
# | mysql |
# | performance_schema |
# | play |
# | sys |
# +--------------------+
use play;
show tables;
# result
#
# Empty set (0.00 sec)
You can add any SQL queries in init directory.
CREATE TABLE `供給` (
`部門番号` int(11) NOT NULL,
`部品番号` int(11) NOT NULL,
`業者番号` int(11) NOT NULL,
`単価` int(11) NOT NULL,
`数量` int(11) NOT NULL
) ENGINE=InnoDB;
INSERT INTO `供給` (`部門番号`, `部品番号`, `業者番号`, `単価`, `数量`) VALUES
(1, 1, 1, 25000, 1000),
(1, 1, 2, 26000, 200),
(2, 1, 1, 24980, 800),
(3, 1, 1, 25000, 2000),
(3, 2, 3, 820, 200),
(3, 4, 3, 5100, 2000);
docker exec -i -t playground mysql -uroot -proot
Content type
Image
Digest
Size
150.3 MB
Last updated
over 6 years ago
docker pull hpprc/mysql-playground