Home >Database >Mysql Tutorial >跨服务器查询导入数据的sql语句

跨服务器查询导入数据的sql语句

WBOY
WBOYOriginal
2016-06-07 17:59:151058browse

此语句可用来将另一服务器中的数据插入到本数据库中的某一表内

insert into MICS_WorkPlan_RestDays select *
from OPENROWSET('SQLOLEDB',
'SERVER=192.168.2.97;uid=用户名;pwd=密码;Database=数据库','select * from v_restdays(sql语句,可执行存储过程)') as a

此语句可用来将另一服务器中的数据插入到本数据库中的某一表内

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn