.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Kaviya Balasubramanian
Sgraph Infotech
Imran Ghani
Post New Web Links

How to access an excel s/s on SP via SQL Server

Posted By:      Posted Date: October 11, 2010    Points: 0   Category :SharePoint
 

Is it possible to access data from an Excel SpreadSheet hosted on SharePoint (2007 MOSS 64 bit)  via SQL Server?  We have a requirement to calculate metrics where part of the data is in SP Lists, and part of the data is in Excel spreadsheets in SharePoint.

Any feedback is greatly appreciated!




View Complete Post


More Related Resource Links

Linked Server to access Excel 2007

  

Hi

I'm tried SELECT * INTO XXX FROM OPENROWSET alongwith Microsoft.ACE.OLEDB.12.0.

Apparently the query requires the sql account to have SYSADMIN privileges.

Considering that SYSADMIN should not be provided to a database account on a Production Server, I tried using the Linked Server method.

Following is my code.


Exec sp_addlinkedserver 'AB2','Ace 12.0','Microsoft.ACE.OLEDB.12.0','\\202.46.215.35\sagarr\Test1\cpc\c2\AB2.xlsx',NULL,'Excel 12.0;IMEX=1'
Exec sp_addlinkedsrvlogin 'AB2','false',NULL,NULL,NULL
go
SELECT * INTO [CPCAB2.xlsx] FROM OPENQUERY([AB2] ,'SELECT * FROM [Sheet1$]')
Exec sp_dropserver 'AB2','droplogins'


Now i get the following error

Error.15247-User does not have permission to perform this action

My Excel file, Database and Windows Application run on separate machines.

i have provided the following privileges

GRANT ALTER ANY LOGIN TO sqlaccount
GRANT ALTER ANY LINKED SERVER TO sqlaccount


EXEC sp_configure 'show advanced options', 1
RECONFIGURE
EXEC sp_configure 'ad hoc distributed queries', 1
RECONFIGURE

The DisAllowAdHocProcess in

Linked Server to access Excel 2007

  
Hi I'm tried SELECT * INTO XXX FROM OPENROWSET alongwith Microsoft.ACE.OLEDB.12.0. Apparently the query requires the sql account to have SYSADMIN privileges. Considering that SYSADMIN should not be provided to a database account on a Production Server, I tried using the Linked Server method. Following is my code. Exec sp_addlinkedserver 'AB2','Ace 12.0','Microsoft.ACE.OLEDB.12.0','\\202.46.215.35\sagarr\Test1\cpc\c2\AB2.xlsx',NULL,'Excel 12.0;IMEX=1' Exec sp_addlinkedsrvlogin 'AB2','false',NULL,NULL,NULL go SELECT * INTO [CPCAB2.xlsx] FROM OPENQUERY([AB2] ,'SELECT * FROM [Sheet1$]') Exec sp_dropserver 'AB2','droplogins' Now i get the following error Error.15247-User does not have permission to perform this action If I execute the query from Query Analyzer it works fine, but fails when I execute it using Windows App and encapsulate code in Stored Proc. My Excel file, Database and Windows Application run on separate machines. i have provided the following privileges GRANT ALTER ANY LOGIN TO sqlaccount GRANT ALTER ANY LINKED SERVER TO sqlaccount EXEC sp_configure 'show advanced options', 1 RECONFIGURE EXEC sp_configure 'ad hoc distributed queries', 1 RECONFIGURE The DisAllowAdHocProcess in Registry has value 0 Please let me know what additional permissions should i set to get it working???

Is it possible to access an Analysis Server with Excel via http?

  
Hi, in our scenario we want to give another company access to out analysis server via web, their front end should be Excel. So first of all I made a setup like descriped here http://technet.microsoft.com/de-de/library/cc917711(en-us).aspx (but I have really no idea how to test it in an easy way because using MDX sample application ends up every time in "The connection either timed out or was lost.") But apart of that, is it possible to access an analysis server with Excel via http? I did not found any possibility to use a http-adresse in Excel as server path. Any ideas? Thanks and regards Peter  

How to access an excel s/s on SP via SQL Server

  

Is it possible to access data from an Excel SpreadSheet hosted on SharePoint (2007 MOSS 64 bit)  via SQL Server?  We have a requirement to calculate metrics where part of the data is in SP Lists, and part of the data is in Excel spreadsheets in SharePoint.

Any feedback is greatly appreciated!


Accessing Excel\Access files through Sql Server 2008 R2 Stand 64 BIT

  

Hello,

This has been just such a pain with 64 bit! Data Access!!  I have been unable to use linked servers from SQL server to access files because there is no Jet 64 bit. Now, I have been using bulk insert statements.  These are working ok, but for some uknown reason, for a certain .csv file I am getting unexpected end of line errors.  I have tried many things to no resolution..

How can I get linked servers to work with SQL Server 64 bit for excel and access?  Why would microsoft leave this out??

 

Thanks!


Cannot connect 2010 Access 2010 Excel or PowerPivot to Mobile SQL(SQL Server Compact) - SDF files

  
I've believe I've installed everything to read Mobile SQL .SDF files.  I've insalled Sql Server Management Studio, Sql Server 2008 R2, .NET 4.0 Framework and just about everything else I've read to see the contents of an .SDF file created for what I read directly from these product sources as this DotNet Compact Framework is the greatest new SQL stuff on the planet.  I can connect using the Management Studio and see the TABLE Stucture easy enough and I can query using some simple SQL Commands from the Management Studio but what really bugs me is if this is all so wonderful, how come I cannot connect to what the SQL Server 2008 R2 Server type "SQL Server Compact" Authentication: "SQL Server Compact Authentication in Office 2010 Access, Excel or even "WOW" PowerPivot!  I've run across a couple 3rd party .SDF Readers - one that exports to Excel such as flyhoward.com  I'm growing old with all the work around import export stuff and just want to use PowerPivot to  excersise the data......or should I use something that actually works like Tableau??

Using the Excel Services REST API to Access Excel Data in SharePoint Server 2010 (Visual How To)

  
Learn how to use the REST API to retrieve resources such as ranges, charts, tables, and PivotTables from workbooks stored on SharePoint Server 2010.

Video: Using the Excel Services REST API to Access Excel Data in SharePoint Server 2010 (Visual How

  
Watch a short video that shows how to programatically retrieve data from an Excel workbook.

SharePoint Portal Server 2001: Search and Access Disparate Data Repositories in Your Enterprise

  

The knowledge worker is greatly empowered if she is able to access information across the enterprise from a central access point. With the SharePoint Portal Server 2001 Search Service you can catalogue information stored in Exchange public folders, on the Web, in the file system, and even in Lotus Notes databases. This article discusses the use of ActiveX Data Objects and the Web-based Distributed Authoring and Versioning protocol for creating search solutions based on SharePoint Portal Server 2001.

Kayode Dada

MSDN Magazine April 2002


Upsize Your Database: Convert Your Microsoft Access Application to Take Advantage of SQL Server 7.0

  

What if you need to convert an existing Microsoft Access 97 database application into a true client-server application that is based on a SQL Server back end? If you know a little about Visual Basic and SQL Server, it's easy to make your app take advantage of the power and scalability provided by SQL Server 7.0. Using some concrete code examples, this article takes you step by step through converting the native Jet queries in your Access application into stored procedures and pass-through queries that SQL Server can use. You'll also learn how to pass on parameters when your client-server app calls these SQL Server stored procedures and queries.

Michael McManus

MSDN Magazine June 2000


Using Remote Data Access with SQL Server CE 2.0

  
Microsoft SQL Server CE edition is the database server built by Microsoft to run on mobile devices. Besides being a standalone database for mobile applications, SQL Server CE also allows you to connect to your desktop SQL Server 2000 and perform remote data access and merge replication. In this article, you will learn how to build a .NET Compact Framework mobile application using Visual Studio .NET 2003 and how it can perform remote data access using SQL Server CE 2.0.

For more information on .NET Compact Framework, see my previous article, "Developing Pocket PC Apps with SQL Server CE."
Features of SQL Server CE 2.0

Figure 1 shows the main components in SQL Server CE and its relationship to SQL Server 2000 (on the desktop).

How to get access to content database after server hardware failure

  

Sharepoint server 2007 and remote sql 2000 SP4 database, after ShraPoint server crash only content databases are available and intact. Trying to restore from backup fail, stsadm -o restore says that not valid backup is available on path. How to get access to available content database using a new installation with same server name, ip address and partitions configuration. How to recover site with content databases information.

Regards, thanks for help.


Victor Naranjo MCSE + Security MCSA + Security MCSE + Messaging MCSA + Messaging ITIL Certified Comptia Security+

Consuming External Data Using SharePoint Server 2010 Business Connectivity Services and an Excel 201

  
Learn how to use BCS in SharePoint Server 2010 to access and update external data by using Microsoft Excel 2010 as a client.

Interacting with the Excel Web Services API for SharePoint Server 2007

  
Get a quick start with the Excel Web Services API, which enables interaction with published Excel 2007 workbooks in SharePoint Server 2007 from a remote application. Learn considerations around session state, security, and performance.

Administrator and Developer Guide to Code Access Security in SharePoint Server 2007

  
Explore configuration options, get best practices for managing CAS in SharePoint environments, and walk through a complex CAS scenario.

Publishing Excel 2007 Workbooks to SharePoint Server 2007 (Visual How To)

  
Watch the video and explore code as you learn how to publish Excel 2007 Workbooks to SharePoint Server 2007 programmatically.

Sample: Publishing Excel 2007 Workbooks to SharePoint Server 2007

  
Explore the code in this visual how-to article as you learn how to publish Excel 2007 Workbooks to SharePoint Server 2007 programmatically.
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend