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

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

SQL server compact deployment help

Posted By:      Posted Date: August 28, 2010    Points: 0   Category :Sql Server
I have a very simple windows desktop app I am trying to deploy using windows installer. I also have a SQL Server compact database file or (Local Database). When I deploy the app and try installing it on my test computer, I get an error saying the database was not found and then it displays the connection string that was set originally in Visual Studio. The application runs but all the database in not there. I don't understand why there is even a connection string there if the database in embedded in the application. Which is one of the benefits of SQL Server  Compact. What should change the connection string to?? Anyone have experience using SQl Server Compact for Win Forms?

View Complete Post

More Related Resource Links

SQL Server Compact Edition Device Deployment


We're building a custom PC installation package to deploy our .NET Compact Framework 3.5 / SQL Server Compact Edition based application.  The installation package uses the System.Configuration.Install and calls Process.Start(ceAppPath, iniPath). We are targeting ARM and x86 devices.  Specifically, which SQL Server Compact Edition cab files do we need to install/deploy for our application to run on the these device platforms?

Web Deployment with IIS settings of remote server


Im trying to deploy a web application project (VS 2010) via team build (TFS 2010), i got to use IIS settings of development server for deployment. So from the project properties I configured the web projects to use Custom web server, (enabled radio button), once i do this the Option in the tab Package/Publish Web "Include all IIS Settings as configured in IIS manager" gets disabled and as a result the deployed web project does not have this IIS settings.

What am I missing here, Im not using the option "Use local IIS Web Server" because the build happens in a build server and would try to take local IIS settings for packaging which is not present.

If this is not possible, suggest me any workaround. Any help on this is greatly appreciated.

Go Mobile: Create Compact, Robust Mobile Apps with SQL Server CE 2.0 and the .NET Compact Framework


Developers have myriad options when it comes to creating solutions for mobile devices. One of the greatest challenges facing mobile developers is finding a compact yet robust local storage solution. SQL Server CE 2.0 promises to deliver on both fronts. This new release represents a tremendous leap in terms of features and performance over its predecessor. This article will review some of the platform and tools choices developers have today. The authors will compare and contrast the significant new features in SQL Server CE 2.0 with the previous release. Following that, they will build a sample app for illustration.

Mark Brown and David Meunier

MSDN Magazine January 2003

Active Server Pages+: ASP+ Improves Web App Deployment, Scalability, Security, and Reliability


ASP has been rebuilt from the ground up. The result? Active Server Pages+. ASP+, with a host of new features, provides for easier to write, cleaner code that's simple to reuse and share. ASP+ boosts performance and scalability by offering access to complied languages; development is more intuitive thanks to Web Forms; and an object-oriented foundation facilitates reuse. Other important features include page events, Web Controls, and caching. Server Controls and improvements in data binding are also new with ASP+. Libraries for use with ASP+, and the Microsoft .NET Framework which allows custom business functions to be exposed over the Web, provide more new development opportunities.

Dave Sussman

MSDN Magazine September 2000

Getting Started with SQL Server Compact 4.0 and ASP.NET 4

The article Getting Started with SQL Server Compact 4.0 and ASP.NET 4 was added by tmorton on Monday, August 09, 2010.

While professional developers are waiting for the Visual Studio Tools and Designers for SQL Server Compact 4.0, I will show how impatient developers can include SQL Server Compact with ASP.NET applications, and use it from ASP.NET pages. Previously, you

Creating a recordset using VBA in Excel with SQL Server Compact

I have create a SQL Server Compact database from VBA in Excel.  So far so good.  Now I want to access the database via a recordset.  here is my code.        Set recSet = New ADODB.Recordset        recSet.LockType = adLockBatchOptimistic     recSet.CursorType = adOpenKeyset     Call recSet.Open("SELECT * FROM SPAR", dbConn)   When I run this I get and error in Call recSet.Open("SELECT * FROM SPAR", dbConn):Errors Occurred, [,,,,]  I have search many forums about his problem, but I still can't see where the error is from.  I am using Excel 2003, and SQL Server Compact 3.5   Regards, Peter

ODBC Driver for SQL Server Compact Edition

I know that there is no ODBC driver available for SQL Server Compact Edition version 3.5.  Do you plan to add an ODBC driver in future release? If yes, is it high in your priority list?   The scenario why I am looking for an ODBC driver is to connect an MS Access application to a SDF file instead of MDB file.  This will enable me to easily sync the SDF file with SQL server repository using the new Data Sync Services.   Mario Cardinal MVP Solutions Architect

SQL Server Compact 4 replication library bug ?

I get the subscriber connection string from a SqlCeReplication object like so: public string GetFullConnectionString(string connectionString) { using (SqlCeReplication repl = new SqlCeReplication()) { repl.SubscriberConnectionString = connectionString; return repl.SubscriberConnectionString; } } With a connection string of: "Data Source=C:\data\nw(40).sdf" I get this from 3.5.8081: ssce:default lock timeout="5000";data source="C:\Data\nw.sdf";ssce:max database size="256";ssce:max buffer size="4096";ssce:temp file max size="256";ssce:enlist="True";ssce:default lock escalation="100";ssce:autoshrink threshold="60";ssce:flush interval="10"; But I get this from 4.0 CTP 1: "Autoshrink Threshold=\"60\";Case Sensitive=\"False\";Data Source=\"C:\\data\\nw40.sdf\";Default Lock Escalation=\"100\";Default Lock Timeout=\"5000\";Encrypt Database=\"False\";Encryption Mode=\"\";Enlist=\"True\";Mode=\"Read Write\";Flush Interval=\"10\";Locale Identifier=\"-1\";Max Buffer Size=\"4096\";Max Database Size=\"256\";Password=\"\";Persist Security Info=\"False\";Temp File Max Size=\"256\";Temp File Directory=\"

SQL Server Compact loses change tracking anchors when copied to device

I have a device app that use SQL Compact and uses sync framework to synchronize to a SQL Server 2008 instance.  In order to speed up the initial synchronization of my device app, I'm creating the database (.sdf) using the sync framework on the server based on the suggestion in this article: http://msdn.microsoft.com/en-us/library/dd938879.aspx#HandlingInitialSynchronizationandExpiredSubscriptions Then I get it via a WCF service down to the device app.  I'm able to download the db and it has data.  When I sync however, the database doesn't seem to think it is syncronized.  It seems to have lost it's anchors.   The following code returns an anchor for my State table on the server, but not after copying it to the device. Any suggestions are appreciated.  Thanks FPASQLCeClientSyncProvider).GetTableReceivedAnchor("State")

SQL Server Compact 3.5 Encryption Questions

If I create a database (.sdf file) on a server and set it to be encrypted, should it be able to be opened on a device or other PC?  In other words, is there anything in the encryption that is machine specific?  Or is it really that the password is what lets me connect and the encryption prevents it from being read by some other tool like a hex file viewer as one post suggested. I've read through lots of posts and documentation and I'm just trying to understand how encryption works and if there are any limitations or considerations and haven't found a good source. Thanks

Chunking to ntext / image columns in SQL Server Compact 3.5

Hi all! I'm trying to store (potentially) large files in a SDF, via a table with an image column.  Image columns hold up to 2GB. Every SQL CE example I've found which does this reads the whole file into a Byte array, then passes the array in a SqlCeParameter.   This is fine assuming that the file is small, or the code is run on a machine with plenty of memory.  But if, for example, you're trying to store a 1GB file on a PC with 512Mb, the whole file cannot be buffered in one go (without paging). What I want to be able to do is read and store "chunks" of a file into an image col.  E.g. http://support.microsoft.com/kb/317034    I think this approach is both faster and more mem efficient.   It is possible on SQL Server 2008 etc., using either UPDATETEXT or UPDATE ... [column name].write( ..., ..., ...).   However, SQL CE doesn't appear to support either syntax. So, I guess my question boils down to: is it possible to store a 2Gb file in an SQL CE image column on a PC with 1GB of mem. (without spending ages paging) Thanks in advance, Ben.

SQL Server to SQL Server Compact Edition Database Copy

I recently switched from XP to Win 7 and am getting an error when using the SQL Server to SQL Server Compact Edition Database Copy wizard from johnnycantcode.com (link). I suspect that the problem is with the configuration of the path for the DQL CE dll. 1) Does anyone know where the configuration is set? It isn't in the GLT.SqlCopy.exe.config file in the local directory. 2) Has anyone got the program to run under Win 7? Thanks marc  

Will SQL Server Compact feature an updated and more capable OLEDB driver

Hi, Earlier, we found problems with using SQL CE 3.5 via OLEDB. While some limited functionality was available and data can be accessed via commands and recordset via OLEDB/ADO from, say, Excel or Access, we were unable to access SQL CE directly from other data-driven packages that nominally support OLEDB, most importantly SAS and SPSS. So our question is whether SQL Server Compact will feature an updated and more capable OLEDB driver? Thx and regards, Ralph

SSIS Deployment Reads local Environment Variable and not Server

Hi All, I have an SSIS package that uses an Environment variable to hold the connection string for the local SSISConfiguration table.  This works properly on my local machine.  However, when I import the package to Integration Services(through SSMS) it reads the environment variable from the local machine and not the server it is deployed to.  If I log on to the server remotely and do the same process it uses the the correct environment varible... (SQL Server 2005) Is there a way to deploy the package to the server and get it to use the correct Env variable without having to log-in to the server and import it?  Let me know if anyone is looking for additional information.   Thanks!

Solution deployment requires executing execadmsvcjobs command on search server to complete deploymen

We have multiple Sharepoint 2007 farms and deploy custom code weekly to the farms. On one o the farms it is required to run stsadm -o execadmsvcjobs on the Search server in the farm in order for solution deployments to complete deploying. These are solution recycles that we are running. This is the only farm this happens on and all farms are identical. In central admin it shows the solution state as deploying. Farm Config Sharepoint 2007 SP2 w Dec Cumulative updates 1 WFE 1 Search server 1 SQL server

how can I open a sql compact 4.0 DB from VS 2010 server explorer ?

Hi, I've downloaded the latest sql compact 4.0 beta, and I follow the Scott Guthrie sample (http://weblogs.asp.net/scottgu/archive/2010/07/16/code-first-development-with-entity-framework-4.aspx). It is working as expected, the DB is created. However, I cannot open the DB in the server explorer of VS (neither from sql management studio). An error telling me the version of the file is not supported is thrown. Note that I only have the 3.5 version in the provider list in the add connection wizard. What is missing ? thanks in advance for the help. stevePaying back the community for its help by writing articles : Have a Nice Day.Net Blog
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