1.多行注释: a. 按下Ctrl + v,进入列模式; b. 在行首选择需要注释的行; c. 按下"I",进入插入模式: d. 然后输入注释符("//"."#"等); e. 按下"Esc"键. 2.删除多行注释: a. 按下Ctrl + v, 进入列模式; b. 选定要取消的注释符; c. 按下"x"或者"d".
本文转自:http://blog.chinaunix.net/uid-17079336-id-2832443.html 1.创建表的同时创建主键约束(1)无命名create table student (studentid int primary key not null,studentname varchar(8),age int);(2)有命名create table students (studentid int ,studentname varchar(8),age int,constr
1. 在已存在的表中添加字段约束AUTO_INCREMENT修饰符 mysql> alter table user modify uid int auto_increment primary key; ERROR 1062 (23000): ALTER TABLE causes auto_increment resequencing, resulting in duplicate entry '1' for key 'PRIMARY' 理解:uid有0, 而auto_increment是从1开始
配置python+mod_wsgi+apache 时 在浏览器中访问服务器时报错:Invalid HTTP_HOST header: 'XXXXX'. You may need to add u'XXXXX' to ALLOWED_HOSTS,在setting.py中添加ALLOWED_HOSTS['*"]无效的原因:是apache没有配置ServerName localhost:80 .配置完成后,解决了以上的问题 故障表现的现象是:使用localhost 访问apache是ok的,单无法使
JavaScript向select下拉框中添加和删除元素 1.说明 a 利用append()方法向下拉框中添加元素 b 利用remove()方法移除下拉框中最后一个元素 2.设计源码 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xm
C# 向程序新建的窗体中添加控件,控件需要先实例化,然后用controls.add添加到新的窗体中去 Form settingForm = new Form(); setForm deviceSet = new setForm(); settingForm.Controls.Add(deviceSet); settingForm.Show();
10-9. 在多对多关系中为插入和删除使用存储过程 问题 想要在一个无载荷的多对多关系中使用存储过程(存储过程只影响关系的连接表) 解决方案 假设有一个多对多关系的作者( Author)表和书籍( Book)表. 用连接表AuthorBook来做多对多关系,如 Figure 10-11.所示: Figure 10-11. A payload-free, many-to-many relationship between an Author and a Book 当把表生成模型,那么模型就如Fig