mysql_query 执行多条sql_mysql_query中如何同时执行多条sql语句?

这篇博客讨论了如何在Web环境中使用mysql_query函数执行多条SQL语句。提供了创建HyForum_forum表的示例,并展示了多条INSERT语句用于填充表数据。回答者给出了不同观点,包括对并发执行SQL的建议和示例。
摘要由CSDN通过智能技术生成

问:

谢谢

______________________________________________________________________________________________

答1:

想在web中玩多线程?解释型的脚本不可能实现,如果要求精度不够高的话可以考虑同时开多个窗口运行sql

______________________________________________________________________________________________

答2:

这是我得sql语句:

CREATE TABLE HyForum_forum (

id int(10) unsigned NOT NULL auto_increment,

sid varchar(255) DEFAULT '0' NOT NULL,

taxis tinyint(3) unsigned DEFAULT '0' NOT NULL,

parent_id int(10) unsigned DEFAULT '0' NOT NULL,

seniority_id varchar(255) DEFAULT '0' NOT NULL,

master varchar(255),

type enum('0','1') DEFAULT '0' NOT NULL,

name varchar(255) NOT NULL,

intro text,

icon varchar(255),

only_show_icon enum('0','1') DEFAULT '0',

deck_left varchar(255),

deck_right varchar(255),

picture varchar(255),

upload_file enum('0','1','sys') DEFAULT 'sys' NOT NULL,

upload_file_num tinyint(3) unsigned DEFAULT '1',

upload_file_size int(10) unsigned DEFAULT '0',

upload_file_exts varchar(255),

upload_file_picwidth smallint(5) unsigned DEFAULT '0',

upload_file_onlymaster enum('0','1') DEFAULT '0',

only_user_browse enum('0','1') DEFAULT '0' NOT NULL,

hidden enum('0','1') DEFAULT '0' NOT NULL,

attrib enum('0','1','2','3','4','5') DEFAULT '0' NOT NULL,

inte enum('0','1') DEFAULT '0' NOT NULL,

inte_hy enum('0','1') DEFAULT '0',

inte_url varchar(255),

count_real_title int(10) unsigned DEFAULT '0',

count_real_reply int(10) unsigned DEFAULT '0',

count_title int(10) unsigned DEFAULT '0',

count_reply int(10) unsigned DEFAULT '0',

count_recycle_title int(10) unsigned DEFAULT '0',

count_recycle_reply int(10) unsigned DEFAULT '0',

count_elite_title int(10) unsigned DEFAULT '0',

count_noauth_title int(10) unsigned DEFAULT '0',

count_noauth_reply int(10) unsigned DEFAULT '0',

count_close_title int(10) unsigned DEFAULT '0',

show_son enum('0','1') DEFAULT '1',

inherit_master enum('0','1') DEFAULT '1' N

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值