A problem with privileges
Hi everyone, My environment: - Linux 2.6.7-1.7asp #1 Thu Jul 15 17:36:07 YEKST 2004 i686 i386 GNU/Linux - server version: 4.0.13 I wrote a script-SQL like this: #Begin of script-SQL ... DATA_BEGIN=$1 DATA_END=$2 TIME_BEGIN=$3 TIME_END=$4 USER_NAME=$5 PRICE=$6 CUR_TABLE=acc_cur TMP_TABLE=acc_tmp mysql -h 198.168.68.1 -u info blg <= '$DATA_BEGIN' AND cur_date < '$DATA_END' AND cur_time >= '$TIME_BEGIN' AND cur_time <= '$TIME_END' GROUP BY cur_date,cur_time; SELECT (count(*)*($PRICE)/60) FROM $TMP_TABLE; DROP TABLE $TMP_TABLE; TTT2 #End of script-SQL When I grant privileges for user 'info' like this: +--+ | Grants for [EMAIL PROTECTED]/255.255.255.0 | +--+ | GRANT SHOW DATABASES, CREATE TEMPORARY TABLES, LOCK TABLES ON *.* TO 'info'@'198.168.68.0/255.255.255.0' | | GRANT SELECT, INSERT, DELETE, CREATE, DROP ON `blg`.* TO 'info'@'198.168.68.0/255.255.255.0' | +--+ The script-SQL, printed above, execute Ok. When I grant privileges for user 'info' like this: +--+ | Grants for [EMAIL PROTECTED]/255.255.255.0 | +--+ | GRANT USAGE ON *.* TO 'info'@'198.168.68.0/255.255.255.0'| | GRANT SELECT ON `blg`.* TO 'info'@'198.168.68.0/255.255.255.0' | | GRANT INSERT, DELETE, CREATE, DROP ON `blg`.`acc_tmp` TO 'info'@'198.168.68.0/255.255.255.0' | +--+ When I tried to execute the script-SQL, I get error: ERROR 1142 (0) at line 2: drop command denied to user: '[EMAIL PROTECTED]' for table 'acc_tmp' Help me, pls. Many thanks Vitalij -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
A problem with privileges
Hi everyone, My environment: - Linux 2.6.7-1.7asp #1 Thu Jul 15 17:36:07 YEKST 2004 i686 i386 GNU/Linux - server version: 4.0.13 I wrote a script-SQL like this: #Begin of script-SQL ... DATA_BEGIN=$1 DATA_END=$2 TIME_BEGIN=$3 TIME_END=$4 USER_NAME=$5 PRICE=$6 CUR_TABLE=acc_cur TMP_TABLE=acc_tmp mysql -h 198.168.68.1 -u info blg <= '$DATA_BEGIN' AND cur_date < '$DATA_END' AND cur_time >= '$TIME_BEGIN' AND cur_time <= '$TIME_END' GROUP BY cur_date,cur_time; SELECT (count(*)*($PRICE)/60) FROM $TMP_TABLE; DROP TABLE $TMP_TABLE; TTT2 #End of script-SQL When I grant privileges for user 'info' like this: +--+ | Grants for [EMAIL PROTECTED]/255.255.255.0 | +--+ | GRANT SHOW DATABASES, CREATE TEMPORARY TABLES, LOCK TABLES ON *.* TO 'info'@'198.168.68.0/255.255.255.0' | | GRANT SELECT, INSERT, DELETE, CREATE, DROP ON `blg`.* TO 'info'@'198.168.68.0/255.255.255.0' | +--+ The script-SQL, printed above, execute Ok. When I grant privileges for user 'info' like this: +--+ | Grants for [EMAIL PROTECTED]/255.255.255.0 | +--+ | GRANT USAGE ON *.* TO 'info'@'198.168.68.0/255.255.255.0'| | GRANT SELECT ON `blg`.* TO 'info'@'198.168.68.0/255.255.255.0' | | GRANT INSERT, DELETE, CREATE, DROP ON `blg`.`acc_tmp` TO 'info'@'198.168.68.0/255.255.255.0' | +--+ When I tried to execute the script-SQL, I get error: ERROR 1142 (0) at line 2: drop command denied to user: '[EMAIL PROTECTED]' for table 'acc_tmp' Help me, pls. Many thanks Vitalij -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
A problem with privileges
Hi everyone, My environment: - Linux 2.6.7-1.7asp #1 Thu Jul 15 17:36:07 YEKST 2004 i686 i386 GNU/Linux - server version: 4.0.13 I wrote a script-SQL like this: #Begin of script-SQL ... DATA_BEGIN=$1 DATA_END=$2 TIME_BEGIN=$3 TIME_END=$4 USER_NAME=$5 PRICE=$6 CUR_TABLE=acc_cur TMP_TABLE=acc_tmp mysql -h 198.168.68.1 -u info blg < CREATE TABLE $TMP_TABLE SELECT cur_date,cur_time,traffic FROM $CUR_TABLE LIMIT 1; DELETE FROM $TMP_TABLE; INSERT INTO $TMP_TABLE SELECT cur_date,cur_time,count(*) FROM $CUR_TABLE WHERE user_name = '$USER_NAME' AND cur_date >= '$DATA_BEGIN' AND cur_date < '$DATA_END' AND cur_time >= '$TIME_BEGIN' AND cur_time <= '$TIME_END' GROUP BY cur_date,cur_time; SELECT (count(*)*($PRICE)/60) FROM $TMP_TABLE; DROP TABLE $TMP_TABLE; TTT2 #End of script-SQL When I grant privileges for user 'info' like this: +--+ | Grants for [EMAIL PROTECTED]/255.255.255.0 | +--+ | GRANT SHOW DATABASES, CREATE TEMPORARY TABLES, LOCK TABLES ON *.* TO 'info'@'198.168.68.0/255.255.255.0' | | GRANT SELECT, INSERT, DELETE, CREATE, DROP ON `blg`.* TO 'info'@'198.168.68.0/255.255.255.0' | +--+ The script-SQL, printed above, execute Ok. When I grant privileges for user 'info' like this: +--+ | Grants for [EMAIL PROTECTED]/255.255.255.0 | +--+ | GRANT USAGE ON *.* TO 'info'@'198.168.68.0/255.255.255.0'| | GRANT SELECT ON `blg`.* TO 'info'@'198.168.68.0/255.255.255.0' | | GRANT INSERT, DELETE, CREATE, DROP ON `blg`.`acc_tmp` TO 'info'@'198.168.68.0/255.255.255.0' | +--+ When I tried to execute the script-SQL, I get error: ERROR 1142 (0) at line 2: drop command denied to user: '[EMAIL PROTECTED]' for table 'acc_tmp' Help me, pls. Many thanks Vitalij -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]