Thursday, May 26, 2011
Tuesday, May 17, 2011
mysql show stored procedure
mysql> show create procedure truncate_all_data;
| Procedure | sql_mode | Create Procedure | character_set_client | collation_connection | Database Collation |
+-------------------+----------+------------------------------------------------------+----------------------+----------------------+--------------------+
| truncate_all_data | | CREATE DEFINER=`amp_db_user`@`localhost` PROCEDURE `truncate_all_data`()
BEGIN
truncate table file_capture_events;
truncate table capture_files;
call sp_audit('truncate_all_data','Call truncate_all_data store procedure');
END | latin1 | latin1_swedish_ci | latin1_swedish_ci |
+-------------------+----------+------------------------------------------------------+----------------------+----------------------+--------------------+
1 row in set (0.00 sec)
| Procedure | sql_mode | Create Procedure | character_set_client | collation_connection | Database Collation |
+-------------------+----------+------------------------------------------------------+----------------------+----------------------+--------------------+
| truncate_all_data | | CREATE DEFINER=`amp_db_user`@`localhost` PROCEDURE `truncate_all_data`()
BEGIN
truncate table file_capture_events;
truncate table capture_files;
call sp_audit('truncate_all_data','Call truncate_all_data store procedure');
END | latin1 | latin1_swedish_ci | latin1_swedish_ci |
+-------------------+----------+------------------------------------------------------+----------------------+----------------------+--------------------+
1 row in set (0.00 sec)
Friday, May 13, 2011
cronjob every hr
* * * * * command to be executed
- - - - -
| | | | |
| | | | |
| | | | +----- day of week (0 - 7) (Sunday=0 or 7)
| | | +---------- month (1 - 12)
| | +--------------- day of month (1 - 31)
| +-------------------- hour (0 - 23)
+------------------------- min (0 - 59)
- - - - -
| | | | |
| | | | |
| | | | +----- day of week (0 - 7) (Sunday=0 or 7)
| | | +---------- month (1 - 12)
| | +--------------- day of month (1 - 31)
| +-------------------- hour (0 - 23)
+------------------------- min (0 - 59)
ruby date format yyyymmdd
[root@nt cronjobs]# irb
irb(main):001:0> today = Time.now.strftime("%Y%m%d").to_i
=> 20110513
irb(main):001:0> today = Time.now.strftime("%Y%m%d").to_i
=> 20110513
Tuesday, May 3, 2011
mysql ERROR No. 1030: Got error 28 from storage engine
Disk is out of space
[root@reyotest stat]# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda3 231825440 219859768 0 100% /
/dev/sda1 101086 22394 73473 24% /boot
tmpfs 1037048 0 1037048 0% /dev/shm
[root@reyotest stat]# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda3 231825440 219859768 0 100% /
/dev/sda1 101086 22394 73473 24% /boot
tmpfs 1037048 0 1037048 0% /dev/shm
perl error: Can't locate LWP/UserAgent.pm in @INC
need to install libwww-perl
1, download package from cpan:
wget http://www.cpan.org/modules/by-module/LWP/libwww-perl-5.837.tar.gz
2, unzip it
tar xvzf libwww-perl-5.837.tar.gz
3, install pkg
cd libwww-perl-5.837
perl Makefile.PL
make
make install
1, download package from cpan:
wget http://www.cpan.org/modules/by-module/LWP/libwww-perl-5.837.tar.gz
2, unzip it
tar xvzf libwww-perl-5.837.tar.gz
3, install pkg
cd libwww-perl-5.837
perl Makefile.PL
make
make install
Subscribe to:
Posts (Atom)
-
Step 1, New a project rails new demo Step 2, Update Gemfile add paperclip, mysql2 gem, enable JavaScript runtime gem 'mysql2' ...
-
I used 7z to zip this file under Windows, try to unzip it under linux [ang@walker temp]$ gunzip 2011.sdf.zip gunzip: 2011.sdf.zip: unkno...
-
When trying to access transmission from web-browswer i got the message : 403: Forbidden Unauthorized IP Address. Either disable the IP ad...