Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Linked Server to Compact Edition possible in 2005 Express?

Posted on 2009-05-08
3
Medium Priority
?
797 Views
Last Modified: 2012-05-06
Hello

I am running SQL Server 2005 Express.  There is a third party app on the system that uses Microsoft SQL Server Compact Edition (using a file with an .SDF extension)

Is it possible for me to point to this as a linked server within SQL Server Management Studio? If so, how? I see no "Compact Edition" in the list of datasource types when trying to setup the linked server.

Additionally, if not, is it possible to set it up as an ODBC source?

Thanks
0
Comment
Question by:PMH4514
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 51

Expert Comment

by:Mark Wills
ID: 24342931
Nope, not a linked server, but you can "connect" to it by simply bringing up the connection manager and browse for that SDF file.  Compact is not a server based solution, so is handled a bit differently...

What you have to do is write a bit of code and link to it that way...

What exactly are you trying to do ?
0
 

Author Comment

by:PMH4514
ID: 24343700
I am trying to insert into it from within a SQL Server stored procedure. The vendor of this third party component that plays a role in my system previously used an MS Access database, and my stored procedures insert directly into it as a linked server. Now they have changed and I guess I have to as well. It all needs to be programmatic, during runtime, can't be opening dialogs and manually browsing for anything. I don't see an ODBC driver for it either so I can't even write a C++  module to do it programmaticly it seems.
0
 
LVL 51

Accepted Solution

by:
Mark Wills earned 500 total points
ID: 24343788
ADO.net using the SQLCE components. You will need to add the SQLCE OLEDB stuff to your project...

You can also use entity framework : http://technet.microsoft.com/en-us/library/cc835494.aspx

There is a nice little project with source code converting / migrating data from SQL Server to Compact - it has all the connections and code samples... http://www.codeproject.com/KB/database/SqlCompactCoptUtility.aspx   (points to the same johnnycantcode link in the other thread below)

You can also explore SQLCE_OLEDB : http://msdn.microsoft.com/en-us/library/ms171763.aspx

And here is a previous / related posting : http://www.experts-exchange.com/Programming/Editors_IDEs/.NET/Q_24214228.html
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

by Mark Wills Attending one of Rob Farley's seminars the other day, I heard the phrase "The Accidental DBA" and fell in love with it. It got me thinking about the plight of the newcomer to SQL Server...  So if you are the accidental DBA, or, simp…
In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question