Click here to Skip to main content
15,891,431 members
Everything / Database Development / SQL Server / SQL Server CE

SQL Server CE

SQL-CE

Great Reads

by Tamer Oz
PocketPcAgent is an application that can be installed on Windows Mobile devices that are running Windows Mobile 5.0 or higher. The application listens to events such as SMS Received, Call Missed, E-Mail Received, Battery Strength Changed, and much more on the Pocket PC.
by Enrique Albert
Azure WebSite and W8 Store App using SQL-CE, Azure SQL, Mobile Services, SignalR, EF, WebAPI and integration to Bing Maps
by Bryan Sachdeva
This article describes how to create a wrapper class for the native Phone API, and then uses it to retrieve and store the call history.
by Md. Marufuzzaman
This tip shows you an easy way to split Microsoft SQL Server table row data.

Latest Articles

by Ebenezar John Paul
An Ideal Code Review Checklist that applies for most programming languages
by Emanuel Santos
In this article i will show how to create a basic application to detect and recognize faces using EmugCV.
by Neeraj Prasad Sharma
This article deals with performance difference with literal values
by NightWizzard
Handling for hex expressions and the trailing '}'

All Articles

Sort by Updated

SQL Server CE 

12 Jan 2011 by #realJSOP
That's because Click-Once deployment is a web-based deployment strategy.http://msdn.microsoft.com/en-us/library/t71a733d(v=vs.80).aspx[^]
28 Jan 2012 by 2011999
Dear All,my quation is one table relation to how many tables related. how to find out table relation. i need how to find out relation through sql command .
11 Jan 2009 by 6opuc
Fast and easy to use data access class library.
24 Mar 2013 by 786.sufiyan
Hi,i m planning to open a small software company to provide software based solution in India,in others words i wanted to sell my software's in the market to my client.i m a beginner and i wanted to know about the procedure to open a software company as a sole proprietor, i know how to get...
10 Feb 2013 by _Amy
This error usually means that the assembly was not found. Try verifying that the file exists in the directory where your application is running. Try these steps:--> Copy DLL to some other location as on Desktop.--> Delete reference from project and also delete the DLL from BIN.--> Copy...
27 Jun 2013 by _Amy
Do you have SQL Server Compact Edition 4[^] installed in your machine? Try installing that. This problem occurs because the compiler is unable to load required assemblies. You don't need to remove earlier version of SQL Server Compact edition.I am not sure but may be one more checkpoint is...
28 Mar 2011 by _Tushar Patil
you will get some idea from Repeater or ListView Controls where you can group this type of data into one Grid , once you Bind the data in repeater or Listview you can use javasript to print specific page.
25 Oct 2012 by Aadhar Joshi
Currently i'm using "Microsoft SQL Server 2008 R2 (SP1) - 10.50.2500.0 (X64) Jun 17 2011 00:54:03 Copyright (c) Microsoft Corporation Enterprise Edition (64-bit) on Windows NT 6.1 (Build 7601: Service Pack 1) " version for sql server.I have added danish language registry to...
5 Jul 2015 by aashish_9601
Hi..I am trying to learn windows phone development.After going through tutorials on the internet , i am making an DataBound App.so far, i have created an database and an DataContext of the db. and using it to populate the LongListSelector as follows Protected Overrides Sub...
3 Dec 2013 by Abhijeet pratap singh
string dbfile = "|DataDirectory|\\Database1.sdf";string insertStmt = "select * from item";string a = "insert into item(item1,item2) values('3','3')";SqlCeCommand query,query1;SqlCeConnection connection; private void button1_Click(object sender, EventArgs e) { ...
10 Jun 2010 by Abhinav S
Firstly, make sure the key sent in via favid is available in the database.Make sure your database connection is set up correctly.
24 Jun 2011 by Abhinav S
Make sure you have rights to access the appropriate DB and that the path is correct.Based on http://www.connectionstrings.com/sql-server-2005-ce[^], this connection string looks appropriate.
30 Jan 2013 by Abhinav S
This could be possible to do in a number of interesting ways.The simplest would be to handle the the keydown event on the grid (capture Ctrl + V).Here are some articles that might help you...
8 Jan 2014 by Abhinav S
Try http://www.reflectionit.nl/Blog/2004/datediff-function-in-c[^].
27 Sep 2009 by acarpio1975
Given date ranged data, adjust existing ranges on entry of a new ranged data.
24 Jul 2012 by adadero
Hi.In my application I'm using Sql CE as my database. Unfortunately, I can add datasource for my Entity Data Model (I can add physical database but I can't add datasource for EF). I tried to find information about this problem and I found many blogs explaining how to fix it but it isn't...
29 Jul 2013 by Adarsh chauhan
Hi,try thisselect I.WareHouse,I.Code,ISNULL(I.Qty,0) InQty,ISNULL(O.Qty,0) OutQty , (ISNULL(I.Qty,0)-ISNULL(O.Qty,0)) Stockfrom INStock I(nolock)left joinOUTStock O (nolock)on I.warehouse=O.warehouseand I.code=O.Code
11 Aug 2014 by Afzaal Ahmad Zeeshan
This article explains how you can use ASP.NET (C#) and search for related queries in your Database.
18 Nov 2013 by agent_kruger
I Want to know how to customize options of messagebox suxh as (Yes,No,Cancel) or (OK,Cancel).My app is an windows c#. Thanks In advance.
12 Feb 2013 by Ahsanashfaqattari.12
I have two tables Company and CompanyLikeCompanyLikeIdRatingStarCountCompanyidCompany and CompanyLike have 1 to Many relation . One company can have many likesCompany Like Table Will Look Like this+----------------------------+| ID RatingStar Companyid...
13 Feb 2013 by Ahsanashfaqattari.12
select RatingStar as RatingStar,com.id as Companyid ,com.Name as CompanyName , Count(RatingStar) as Count,MIN(c.ID) as Id from CompanyReviewLike as c inner join Company as com on com.id = c.Companyid Group By RatingStar ,com.Name , com.id
7 May 2013 by aijosh
I dragged two Details (Gridview) from the Data Sources window unto my form and want them to display different rows from the same table.I can't seem to be able to achieve this because any change I make to one reflects on the other one.
6 Sep 2011 by akremb22
I got a project to complete some tasks on it, but when I try debug I have this error inDbProviderFactory Dbfactory = bProviderFactories.GetFactory(MasterConnectionProvider);With my MasterConnectionProvider is System.Data.SqlServerCe.EntityUnable to find the requested .Net Framework...
12 Jan 2011 by AlanC12
I'm developing an app with Visual Studio Express and SQL Server Compact - I want to create a simple installation CD containing all pre-requisite components (.NET framework 3.5, SQL Server Compact etc), in case the end user has no internet access. There is no Setup project in VS Express - does...
3 Jul 2011 by Alexander Galkin
Provides a sample code for a simple test bench application and compares the performance of two most common embedded databases for .NET: Microsoft SQL CE 4.0 and SQLite.
20 Sep 2013 by alimohammad2011
Greeting for the day !!Dear friends I am stuck on a solution i need to provide to my clients. Describing the requirement in detail so please don't mind the length of this post.I am supposed to develop an offline model for my asp.net (4.5) web application along with SQL server as db on...
3 Mar 2013 by Am Gayathri
Am using one procedure to retrieve data.The result contains two fields, lets consider Column A and Column Bnow out put looks like,Column A Column BA XB XC XB ...
11 Apr 2016 by Amar Kapadia
Hello:Although I am very new to using embedded Reports (.rdlc) in WinForm applications (in C#), I think I understand the basic concepts. I've been experimenting and practicing to get better at this. Yet, I am having one strange problem. I've Google searched all this morning for a solution...
3 Aug 2013 by Amar Kapadia
Quick Solution: Field Names in tables must not have spaces in them.Hello EveryoneI think I might know what is happening here. Indeed, perhaps all this stemmed from the Northwind40.sdf SQL Server Compact Edition 4.0 database file I was using. Again, I'm not sure how I got it but must be...
18 Sep 2011 by AminMhmdi
hii have c# project with sql CE database(sdf)database have 2 tablei show table1 information in form1 with datagridviewand show table2 information in form2 with bindnavigatori want when i enter data in table 1 then click to "button1" in form 1 in form 2 ,bindnavigator update...
19 Sep 2011 by AminMhmdi
thank you for responsebut where i enter this command's??? in visual studio?i give my project i say is use visual studioi have not management studio
16 Dec 2011 by Amir Mahfoozi
As I understood your question you want to have single quote in your string literals so use it double to distinguish it from the SQL command single quote , for example :insert into names(name) values ('John') will insert John , but :insert into names(name) values ('''John''') will...
28 Jan 2012 by Amir Mahfoozi
To view objects which are depend on a table :EXEC sp_MSdependencies N'TableName', null, 1315327To view objects on which a table depend on :EXEC sp_MSdependencies N'TableName', null, 1053183Extracted from here...
4 Jul 2010 by Amit Kumar Tiwari
This code sends automatic SMS to birthday boys/girls :) from phone
25 Dec 2011 by AmitGajjar
Hi,why don't you check for MySQL,here is the proof why MySQL vs MsSQL?never used SQL-CE so no more idea about that.hope above article will help you,thanks-amit.
3 Jan 2014 by Amol_B
Hi,This should help you.A.Datetime,B.Datetime from (select ROW_NUMBER() OVER (ORDER BY Datetime) AS RowNumber,Datetime1 from table1 ) AS A LEFT JOIN (select ROW_NUMBER() OVER (ORDER BY Datetime) AS RowNumber,Datetime1 from table1) AS B ON B.RowNumber =...
2 Oct 2008 by Andrew J Dixon
Explaining Database deadlocking to non-technical people
9 Jan 2012 by Andrew Rissing
You probably want to look into Multiuser access[^] for a good starting point.As for the second question, I don't believe so, but you may want to check out LocalDB. See the following links about LocalDB:MSDN Magazine (at the bottom)[^]Release annoucement[^]LocalDB Q&A[^]I haven't...
24 Mar 2013 by André Kraak
Quote:Visual Studio Express 2012 ProductsA number of free development tools are also available, including Visual Studio Express 2012 for Windows 8, Visual Studio Express 2012 for Web, Visual Studio Express 2012 for Windows Desktop, and Visual Studio Express 2012 for Windows Phone 8. These...
26 Mar 2013 by André Kraak
If you want to compare two version numbers the most robust way would be to compare each part of the number separately.The version is build up like this:Quote FileVersionInfo.ProductVersion Property[^]:Typically, a version number is displayed as "major number.minor number.build number.private...
3 Dec 2013 by Animesh Datta
Hello,set your database property from Copy to Output directory to Copy Always.Try this linkthanks
16 Mar 2014 by ankitkamdar
I Have Installed Sql Server 2008 Full Edition And Also Full-text Search is installed. but the option is disable how to enable it.I Check Via this query SELECT DATABASEPROPERTY('DivineCampus','IsFulltextEnabled')and it return result 1;
15 Mar 2014 by ankitkamdar
I Have Installed Sql Server 2008 Full Edition And Also Full-text Search is installed. but the option is disable how to enable it.I Check Via this query SELECT DATABASEPROPERTY('DivineCampus','IsFulltextEnabled')and it return result 1;any one have idea about it than please solve it...
14 Jan 2014 by ankush1989
Like giving default value as NULL while inserting column from another table .. ?
19 Jan 2014 by ankush1989
I am getting this error while converting to int datatype I am using query this to convertCAST(CONVERT(VARCHAR(8),GETDATE(),112)AS INT)but getting this error .. ?Error:\'Implicit conversion from data type datetime to int is not allowed. Use the CONVERT function to run this query.'
31 Oct 2013 by Anudeep Jaiswal - MCA
Use This..."Select SiteCodeAndDate from Shifts where Date
21 Sep 2009 by Apriorit Inc, Oleksandr Dodatko
This article describes the process of initial configuration and basic work with Palm Web OS on the lower level than it's described in Palm SDK docs.
24 Feb 2014 by ArunRajendra
My logic would be to do calculation using minutes and then convert the result to hours and minutesex: if y is the result the time could be got as y%60+':'+y/60NOTE: the code is not tested I have just given the logic.
21 May 2014 by Arvind Singh Baghel
Import CSV or txt File Into SQL Server Using Bulk Insert.
15 Apr 2014 by Ashok8033
Hi ,http://technet.microsoft.com/en-us/library/ms403375(v=sql.105).aspx[^]In SQL Server 2008, all user-created databases are always full-text enabled and cannot be disabled. Regards,Ashok Kumar,
7 Jun 2010 by Ashraf ELHakim
i making mobile application for my gradution project and i need to develop DB contain some data to fill comboxs in mobile application ...i hear sql compact edition is the solution but i have some question :1- when i make the database VS ask me if i want data source My comuter or active...
7 Jun 2010 by Ashraf ELHakim
maybe my question answered :) by this artical Smart Device Login Application Using the SQL Server CE Database[^]but i will let mmy question open because i dnt try the content in the article but it is appear good :) thx for code projecty members and all :)
10 Jun 2010 by Ashraf ELHakim
hey all am working on mobile application contain 1 form and 14 user control and sql data base compact edition this size of database is 200 kb . when i made the cab file to install the project in my mob the size of cab is 1.2 mega .. but when i try to run the project from the mobile menu it's...
6 May 2010 by AspDotNetDev
Since you are running your own server when you connect to SQL Server CE, you need to have read/write permission to the database file. In your remote call, it looks like you are trying to connect to a SQL Server database rather than a SQL Server CE database. When you connect to a SQL Server...
29 Sep 2013 by Azee
Is there a chance that there are multiple Id values against one TagNumber?You might wanna try Top 1 in your BETWEEN SubQueries.SELECT TagNumber,ParkingType,DistanceToNextTagFROM MyCarWHERE Id BETWEEN (SELECT top 1 Id FROM MyCar WHERE TagNumber=6554) AND (SELECT top 1 Id FROM MyCar...
13 May 2012 by azeeth
Hi All,http://jasonirwin.ca/2009/04/05/crystal-reports-and-sql-server-ce/Hi, I know it is a real pain to integrate Crystal reports with SQL Server Compact 4.0. I tried the above approach(link) to create a crystal report using SQL Compact 4.0 as back end. It works like a charm on my...
16 Dec 2011 by Balu199
Hi all,I want to insert a string with single quotations like this 'StringName' in SqlCE.any one have idea? please share with me.Thanks,Balu.
9 Nov 2012 by Bart-Jan Verhoeff
Access data in any SQL server compact edition datatable using only one line of code in C#
23 Jan 2014 by Bart-Jan Verhoeff
An easy way to access your SQL compact edition database in C#
26 Mar 2013 by bbirajdar
Join the Microsoft BizSpark program here[^]Advantages:Get the following benefits FREE of charge for up to three years:Software, cloud computing, and support to help you grow your business.Access to network partners, including investors, mentors and startups in your area and around...
9 Jul 2013 by Behno0o0oD
Hi every one,I'm running a project on an embedded PC whose operating system is Windows CE 6.0,I need to have a database with some tables,how can I run sql CE on this device?Do I have to first install the sql on it or at the time of deploying, inside the framework 2, there is already a...
10 Jul 2013 by Behno0o0oD
There is a compact sql server called SQL SERVER CE, which is like a dll for VS 2008, and can be added to the project like dlls.Using System.Data.Sqlserverce !!!very interesting
10 Jul 2013 by Behno0o0oD
HiI want to start working with SQLServer CE in VisualStudio 2008.Can you please recommend me some useful guides about that.some instructions about starting to create a database, and making tables and querying on them.after that I want to copy all data to a dataset, and work with...
12 Jul 2013 by Behno0o0oD
Hi every oneI'm working on Northwind database, I could get access to the tables by code using ADO.net, but when I try to load the tables in server explorer, after adding the database, I can't see the tables and I get the Error:Could not load file or assembly...
12 Jul 2013 by Behno0o0oD
HiIS it possible to make a new database in VisualStudio without installing SQlServer???what about by code???
12 Jul 2013 by Behno0o0oD
By using SqlCeEngine class and one of the methods, it is possible to create database in your hard drive! :)using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Data.SqlServerCe;using System.Data.SqlClient;using System.Data.Sql;namespace...
13 Jul 2013 by Behno0o0oD
HiI want to update one of the columns of my table.I have to use subquery to reach to the desired record, but it seems that we aren't allowed to use subquery in front of UPDATE.what is the best way to update the column with subquery ?UPDATE (SELECT TOP(1)* FROM (SELECT...
22 Jul 2013 by Behno0o0oD
Hi every oneI am working on a project which is running on an embedded pc and I am developing by C# language in visual studio 2008 and I have a database using sql server ce.I want my code and my exe file not to be decompiled.what is the best solution?TnX
29 Sep 2013 by Behno0o0oD
Hi every oneI want to use subquery in between clause but I'm getting error in SELECT. SELECT TagNumber,ParkingType,DistanceToNextTagFROM MyCarWHERE Id BETWEEN (SELECT Id FROM MyCar WHERE TagNumber=6554) AND (SELECT Id FROM MyCar WHERE TagNumber=65635)
28 Aug 2015 by Bert O Neill
AngularJS and Web API Active Directory Security (Authorisation)
12 Dec 2015 by BillWoodruff
I suggest you create a data structure to hold the instances of TextBoxes you use:List ParameterTextBoxes = new List;Somewhere in your code add the TextBox instances to this list.Then, when you want to only add SQL Parameters when the TextBoxes have active content...
17 Aug 2011 by bmckuhen
18 Oct 2013 by Brian C Hart
To save you from hunting through the docs and locating downloads, we gather both databases here and walk you through installing them using SQL Server Management Studio Express -- updated for SQL Server 2008 Express Edition!
18 Jun 2007 by Bruce Chapman DNN
Using data driven unit tests with SQL Server CE for DotNetNuke private module development.
29 Oct 2013 by brucey_D
Here is my relevant code:public DateTime today = DateTime.Now;public void filllist() { myCommand = "Select SiteCodeAndDate from Shifts where Date
16 Jun 2013 by Bruno C Soares
What is the command to delete one row in sql compact?
19 Dec 2007 by Bryan Sachdeva
This article describes how to create a wrapper class for the native Phone API, and then uses it to retrieve and store the call history.
3 Feb 2009 by C.L. Moffatt
This article describes SQL Joins in a visual manner, and also the most efficient way to write the visualized Joins.
1 Oct 2008 by Casper Leon Nielsen
T-SQL Coding Standard - for programming the Microsoft SQL Server 2005 (DRAFT)
25 Oct 2004 by Chad Z. Hower aka Kudzu
Any user who works with database updates uses transactions. Transactions in ADO.NET are done using a transaction object, and a try..catch, but there is an easier, one might even say a more C# way to handle database transactions.
19 Apr 2017 by CHill60
You need to use LEFT OUTER JOIN and cater for scenarios where nothing is being returned by the join. Like thisselect * from #Accounts A left outer join #stock S on A.id=S.acId where A.id = 1 AND ((addDate between '2001-11-01' and '2001-11-11') OR addDate IS NULL)
27 Jun 2013 by Chirag B
I am Developing Windows Forms Application using .NET Framework 3.5, VS2012 on Windows 8 (64-bit machine) although I am developing for AnyCPU. The database I use is SQL Server Compact Edition v4.0 and I am getting following error while trying to open a Form in Design mode and VS2012...
8 Mar 2014 by Chirag B
Yes, this was resolved with the same techniques. I had included both folders x86 and amd64 in my project root folder with all related dlls inside it. Sorry for not updating this earlier.
25 Aug 2011 by choudhary.sumit
when i deploy a windows application i attach a .bak file with application files... then i install app in other computer which has no server installed but as a prerequisites i install sql compact edition on that computer......so the problem is that the code written for database restore fails...
13 Aug 2012 by Christian Graus
First of all, it's not urgent at all to the people doing your job for free, that you have this issue. Please don't say that, it is rude. Second, this[^] is what I see when I type your question in to google. If it's so urgent, why didn't you do that ?This[^] seems to me to be the best...
12 Jan 2014 by Christian Graus
In this third installment, we look at how Common Table Expressions can simplify your SQL and help you perform complex tasks
2 Jan 2014 by Christian Graus
If your numbers are multi part in the DB, you can join them, as in select 'S' + id as NewSRNO, or, select id + letter as NewSRNO.Beyond that, your question is nonsensical. For it to make sense, you need to tell us the data in your DB, and the result you want, including the table structure...
6 Jan 2014 by Christian Graus
Just a quick explanation of why it's not always a good idea to use DISTINCT
13 Jan 2014 by Christian Graus
A discussion of windowing functions, from sum to row_number(), to the new functions in SS2012
15 Jan 2014 by Christian Graus
Use IsNull or Coalesce to set defaults for when a value is null. Use Case.. when... else... end where you want to set defaults based on existing non null values.Ask a question with sample code in order to be given back working code.
16 Jan 2014 by Christian Graus
Discussion on pivot and other ways to turn columns of data in to rows in SQL Server
21 Jan 2014 by Christian Graus
A description of the best way to create tally tables, and how to use them
19 Jan 2014 by Christian Graus
You are converting a date to a string, then trying to cast to int. That makes zero sense.convert(int, getdate())will do it, if it's possible.What do you expect to get ? How do you expect the int to relate back to the date ? Are you sure you don't want the day, month or year...
23 Jan 2014 by Christian Graus
A discussion of ways to create random number sequences in SQL Server
22 Dec 2012 by ChrisTopherus
Hi,i am searching for a solution for a few hours now. I created a table in sql_ce with the follwoing query:CREATE TABLE [Customer]([_id] int NOT NULL IDENTITY (1,1),[firstName] nvarchar(4000) NULL,[lastName] nvarchar(4000) NULL,[sex] nvarchar(4000) NULL,[orderAddress_fk] int...
24 Dec 2012 by ChrisTopherus
I found the solution:if you want to delete a foreignkey via query, make sure that you have named your constraint and delete it by this name. so i changed my create foreign key query to:ALTER TABLE [Customer]ADD CONSTRAINT FK_deliveryAddress FOREIGN KEY (deliveryAddress_fk)REFERENCES...