然后我在网上找了一下启动的
 启用Ad Hoc Distributed Queries:
exec sp_configure 'show advanced options',1
reconfigure
exec sp_configure 'Ad Hoc Distributed Queries',1
reconfigure
执行后还是一样,我的SQL语句如下:INSERT INTO OPENROWSET('Microsoft.Jet.OLEDB.4.0', 'c:\A.mdb'; 'admin'; '', A表)
SELECT  *
FROM     agentmenu

解决方案 »

  1.   


    sp_configure 'show advanced options', 1;
    GO
    RECONFIGURE;
    GO
    sp_configure 'Ad Hoc Distributed Queries', 1;
    GO
    RECONFIGURE;
    GO
      

  2.   


    1.是不是你弄错了,要导出的文件一定要在数据库所在的服务器2.字段要绑定好INSERT INTO OPENROWSET('Microsoft.Jet.OLEDB.4.0', 'c:\A.mdb'; 'admin'; '', A表)(col1,col2..)
    SELECT  col1,col2..
    FROM     agentmenu
      

  3.   

    RE:现在提示:
    ----------------------------
    无法初始化链接服务器"(null)"的OLE DB 访问接口 "Microsoft Jet.OLEDB 4.0" 的数据源对像
      

  4.   

    sp_configure 'show advanced options', 1
    GO 
    RECONFIGURE
    GO 
    sp_configure 'Ad Hoc Distributed Queries', 1
    GO 
    RECONFIGURE
    GO
      

  5.   

    --打开Ad Hoc Distributed Queries
    exec sp_configure ''show advanced options'',1
    reconfigure
    exec sp_configure ''Ad Hoc Distributed Queries'',1
    reconfigure
    我测试了一下,没有问题的
    insert  INTO
     OPENROWSET('Microsoft.Jet.OLEDB.4.0', 'c:\A.mdb'; 'admin'; '', 表A)
    select '1'确保你的access文件在sql所在的服务器上
      

  6.   

    --打开Ad Hoc Distributed Queries
    exec sp_configure 'show advanced options',1
    reconfigure
    exec sp_configure 'Ad Hoc Distributed Queries',1
    reconfigure