茶园资源网 Design By www.iooam.com
select *
from openrowset('Microsoft.Jet.OLEDB.4.0'
,'Excel 8.0;HDR=YES;IMEX=1;DATABASE=d:\folder\excel.xls',Sheet1$)
-------NOTE------
Setting IMEX=1 tells the driver to use Import mode. In this state, the registry setting ImportMixedTypes=Text will be noticed. This forces mixed data to be converted to text. For this to work reliably, you may also have to modify the registry setting, TypeGuessRows=8. The ISAM driver by default looks at the first eight rows and from that sampling determines the datatype. If this eight row sampling is all numeric, then setting IMEX=1 will not convert the default datatype to Text; it will remain numeric.
You must be careful that IMEX=1 not be used indiscriminately. This is IMPORT mode, so the results may be unpredictable if you try to do appends or updates of data in this mode.
The possible settings of IMEX are:
0 is Export mode
1 is Import mode
2 is Linked mode (full update capabilities)
from openrowset('Microsoft.Jet.OLEDB.4.0'
,'Excel 8.0;HDR=YES;IMEX=1;DATABASE=d:\folder\excel.xls',Sheet1$)
-------NOTE------
Setting IMEX=1 tells the driver to use Import mode. In this state, the registry setting ImportMixedTypes=Text will be noticed. This forces mixed data to be converted to text. For this to work reliably, you may also have to modify the registry setting, TypeGuessRows=8. The ISAM driver by default looks at the first eight rows and from that sampling determines the datatype. If this eight row sampling is all numeric, then setting IMEX=1 will not convert the default datatype to Text; it will remain numeric.
You must be careful that IMEX=1 not be used indiscriminately. This is IMPORT mode, so the results may be unpredictable if you try to do appends or updates of data in this mode.
The possible settings of IMEX are:
0 is Export mode
1 is Import mode
2 is Linked mode (full update capabilities)
茶园资源网 Design By www.iooam.com
广告合作:本站广告合作请联系QQ:858582 申请时备注:广告合作(否则不回)
免责声明:本站资源来自互联网收集,仅供用于学习和交流,请遵循相关法律法规,本站一切资源不代表本站立场,如有侵权、后门、不妥请联系本站删除!
免责声明:本站资源来自互联网收集,仅供用于学习和交流,请遵循相关法律法规,本站一切资源不代表本站立场,如有侵权、后门、不妥请联系本站删除!
茶园资源网 Design By www.iooam.com
暂无评论...
更新日志
2024年05月20日
2024年05月20日
- 中唱唱片群星《好歌珍藏-士兵旋律》2CDWAV
- 出发吧麦芬各职业特点解析 玩什么职业好
- 崩坏星穹铁道梦中之梦12平民满星攻略 梦中之梦12阵容搭配分享
- 《哈迪斯2》EA阶段至少持续到年底!此前将有重大更新
- 钟志刚《淡淡君情》24K金限量头版[低速原抓WAV+CUE]
- 金山游戏封神再临视频首曝 预计年内上线
- IGN分享PC《对马岛之魂》28分钟实机:极致的画面表现
- 蜀门手游五月大服龙城飞将开启 全新大逃杀玩法上线
- 崩坏星穹铁道平民神主日怎么打 神主日萌新通关攻略
- 钟明秋《是时候HQ》头版限量编号[低速原抓WAV分轨]
- 赵传《我是一只小小鸟》日本东芝1A1版 [WAV+CUE][435M]
- 庄达菲《东张西望》[320K/MP3][40.28MB]
- 庄达菲《东张西望》[24bit 48kHz][FLAC/分轨][288.46MB]
- 金海心.-.[心感觉].专辑[原抓WAV+CUE]
- KOKIA心は?かり(2012K2HD2016Mora)[24bit96kHzFLAC]