MYSQL DB 사용자 추가
mysql> insert into db values ('%','databaseName','Y','Y','Y','Y','Y','Y','Y','N','Y','Y','Y','Y','Y'); Query OK, 1 row affected (0.00 sec) mysql> INSERT INTO `user` ( `Host` , `User` , `password` , `Select_priv` , `Insert_priv` , `Update_priv` , `Delete_priv` , `Create_priv` , `Drop_priv` , `Reload_priv` , `Shutdown_priv` , `Process_priv` , `File_priv` , `Grant_priv` , `References_priv` , `Index..
2008. 10. 10.
MYSQL group by 의 예
$query="SELECT ex_id, sum(0h) as 0h, sum(1h) as 1h, sum(2h) as 2h, sum(3h) as 3h, sum(4h) as 4h, sum(5h) as 5h, sum(6h) as 6h, sum(7h) as 7h, sum(8h) as 8h, sum(9h) as 9h, sum(10h) as 10h, sum(11h) as 11h, sum(12h) as 12h, sum(search_total) as search_total from log_backup where search_date>='$pre_date' and search_date
2008. 10. 9.