在印度都有主要位置的excel工作表 [英] excel sheet which have all major location in India
本文介绍了在印度都有主要位置的excel工作表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想要一张Excel工作表,该工作表在印度的所有主要地点都与所有主要城市都相结合,
因为我想在项目中使用所有位置",所以我将Sql数据库中的Excel文件导入,
因此,如果您在数据库(或Excel工作表)中具有所有位置的列表,则请Plz给我基于数据库的脚本
I want a excel sheet which have all major location in India, combined with all Major city,
because i want use All Location In my Project, so i import Excel file in my Sql Data base,
So if you Have List Of All Location In database(or excel sheet) Then Plz Give Me SCrip Of data base
推荐答案
我为您做了辛苦的工作.我在这里找到了列表 [
I did the hardwork for you. I found the list here[^]
Now its your turn to do the easy work of putting it in the excel or database.
使用分布式查询
如果您不想将与Excel工作簿的持久连接配置为链接服务器,则可以使用OPENDATASOURCE或OPENROWSET函数为特定目的导入数据.下面的代码示例还将数据从Excel客户工作表导入到新的SQL Server表中:
从OPENDATASOURCE(``Microsoft.Jet.OLEDB.4.0'',
''数据源= C:\ test \ xltest.xls;扩展属性= Excel 8.0'')... [城市
Use Distributed Queries
If you do not want to configure a persistent connection to the Excel workbook as a linked server, you can import data for a specific purpose by using the OPENDATASOURCE or the OPENROWSET function. The following code samples also import the data from the Excel Customers worksheet into new SQL Server tables:
SELECT * INTO XLImport3 FROM OPENDATASOURCE(''Microsoft.Jet.OLEDB.4.0'',
''Data Source=C:\test\xltest.xls;Extended Properties=Excel 8.0'')...[City
选择*从OPENROWSET(''Microsoft.Jet.OLEDB.4.0'',进入XLImport4,
" Excel 8.0; Database = C:\ test \ xltest.xls",[城市
SELECT * INTO XLImport4 FROM OPENROWSET(''Microsoft.Jet.OLEDB.4.0'',
''Excel 8.0;Database=C:\test\xltest.xls'', [City
这篇关于在印度都有主要位置的excel工作表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文