码迷,mamicode.com
首页 >  
搜索关键字:bulk insert    ( 13894个结果
sql脚本读取txt文本文件插入新表
今天老大让我录入一大批数据,我的第一个想法就是用inser来一条条插入,或者用C#代码读取Excel然后再插入到数据库,经过老大的介绍。我才知道,还有用sql脚本导入数据的方法。呵呵,真的是长知识了。其实代码很简单BULK INSERT cartemp FROM 'd:\1.txt'WITH(FIE...
分类:数据库   时间:2014-07-16 19:27:57    阅读次数:478
判断字符串中是否有SQL攻击代码
判断一个输入框中是否有SQL攻击代码public const string SQLSTR2 = @"exec|cast|convert|set|insert|select|delete|update|alter|drop|count|chr|varchar|nvarchar|nchar|char[ ...
分类:数据库   时间:2014-07-16 19:22:06    阅读次数:236
txt文件导入mysql
http://blog.csdn.net/piaolankeke/article/details/6272214MySQL写入数据通常用insert语句,如[c-sharp]view plaincopyinsertintopersonvalues(张三,20),(李四,21),(王五,70)…;但有...
分类:数据库   时间:2014-07-16 18:25:05    阅读次数:253
MySqli 执行多条SQL语句
使用multi_query(); 去执行SQL语句,执行多条语句多个SQL语句用“;”分开一:没有结果集的语句:$sql="insert into products (cid,name,price,num) values('2','PHP','2.22','10');update products ...
分类:数据库   时间:2014-07-15 23:12:08    阅读次数:325
二叉树的非递归遍历
先写下这个问题的模式 def preorderTraversal(self, root): if root == None: return [] re = [] insert root to stack s while s not empty: cur_root = top of stack s s.pop() how to handle cur_root how to ...
分类:其他好文   时间:2014-07-15 10:17:43    阅读次数:274
Insert Buffering
14.5.13.4Insert Buffering Database applications often insert new rows in the ascending order of the primary key. In this case, due to the layoutof th....
分类:其他好文   时间:2014-07-14 22:02:27    阅读次数:373
线段树(build,insert,dfs操作)
模板原型:解决零散数点在已知线段上的出现次数。思想是将线段用长线覆盖,将长线转化成线段树。用权值记录各个数点出现的次数,最后进行查询。代码解释见注释。 1 #include 2 using namespace std; 3 4 const int MAXN = 3e4 + 10; 5 int n.....
分类:其他好文   时间:2014-07-14 21:47:46    阅读次数:173
MySQL:ONDUPLICATEKEYUPDATE用法
如果在INSERT语句末尾指定了ON DUPLICATE KEY UPDATE,并且插入行后会导致在一个UNIQUE索引或PRIMARY KEY中出现重复值,则执行旧行UPDATE;如果不会导致唯一值列重复的问题,则插入新行。例如,如果列a被定义为UNIQUE,并且包含值1,则以下 两个语句具有相同...
分类:数据库   时间:2014-07-14 21:20:17    阅读次数:351
How to insert a character into a NSString
How do I insert a space to a NSString.I need to add a space at index 5 into:NString * dir = @"abcdefghijklmno";To get this result:abcde fghijklmnowith...
分类:其他好文   时间:2014-07-14 21:12:21    阅读次数:175
ecshop 浏览历史样式的修改
ecshop的浏览历史的样式,例如我修改的是只让浏览历史显示浏览历史的商品名称 而不显示浏览历史的商品的价格和图片首先找到要修改 的文件includes\lib_insert.php找到函数function insert_history()函数里面的$str.=''.$goods['short_n....
分类:其他好文   时间:2014-07-14 19:42:09    阅读次数:200
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!