MySQL在删除一张表时出现ERROR 1217 (23000): Cannot delete or update a parent row: a foreign key constraint fails可能是MySQL在InnoDB中设置了foreign key关联,造成无法更新或删除数据。可以通...
分类:
数据库 时间:
2014-09-29 20:44:02
阅读次数:
250
add方法:1 s = {1,2,3}2 s.add(4)3 print(s)# {1, 2, 3, 4}同list的append方法,若调用s.add(3),则不会有任何影响。这点与C#中的HashSet有区别。update方法:1 s = {1,2,3,4,5}2 s.update({3,5,7...
分类:
编程语言 时间:
2014-09-29 19:43:21
阅读次数:
201
my work environment:
aliyun Ubuntu 14.04 64位
first phase:apt-get update (it is very important,otherwise will cause 404 error)
second phase:installation referenced by other website informatio...
分类:
其他好文 时间:
2014-09-29 19:36:41
阅读次数:
287
今天在提交代码时遇到到了一个很蛋疼的问题,remote: hooks/update:10 undefined method 'require_relative' for main:Object(NomethodError)...
分类:
其他好文 时间:
2014-09-29 18:58:11
阅读次数:
278
1.准备: copy 安装文件nginx-1.7.5.tar.gz到 /usr/local/ //需准备好Perl 5 兼容正则表达式库(PCRE)与SSL 支持库 sudo apt-get update sudo apt-get install libpcre3 libpcre3-dev sudo apt-get install open...
分类:
其他好文 时间:
2014-09-29 18:37:51
阅读次数:
205
RemoteView会用在两个地方:一个是在AppWidget,另外一个是在Notification.
RemoteView是用来描述一个垮进程显示的view
1,AppWidget---RemoteView
AppWidgetProvider是一个BrocaseReceiver,只是接受到Enable, Update,disale,delete这些message,而真正显示...
分类:
其他好文 时间:
2014-09-29 17:22:11
阅读次数:
168
一、触发器定义和创建: 触发器(trigger)是个特殊的存储过程,它的执行不是由程序调用,也不是手工启动,而是由个事件来触发,比如当对一个表进行操作(insert,delete,update)时就会激活它执行。 触发器可以在查询分析器里创建,也可以在表名上点右键->“所有任务”->“管理触发...
分类:
数据库 时间:
2014-09-29 15:19:01
阅读次数:
254
前几天用oracle写存储过程,发现在存储过程中写update、insert或者delete语句都会编译错误,后来在不经意间找到了解决方案,加入emp表示scott用户的,如果用scott用户创建存储过程,表名=emp,这样创建的存储过程是可以写任意DML语句的但是用其余用户登录,如果采用norma...
分类:
数据库 时间:
2014-09-29 04:28:56
阅读次数:
307
timestamp的两个属性:CURRENT_TIMESTAMP 和ON UPDATE CURRENT_TIMESTAMP http://blog.163.com/qiongling007@126/blog/static/2142429620122611356554/http://www.cnblo...
分类:
数据库 时间:
2014-09-28 23:18:17
阅读次数:
275
思路是写一个函数,先按条件查询数据,如果查询到数据则更新,如果没有查询到数据则插入:
create or replace function fn_merge_index(statdate in date,
cpid in varchar2,
...
分类:
数据库 时间:
2014-09-28 21:33:25
阅读次数:
942