The SQL Server Compact 3.5 SP2 Desktop runtime (x86 and x64) is installed with SQL Server 2008 R2 and Visual Studio 2010.

Microsoft SQL Server Compact 3.5 Service Pack 2 for Windows Desktop  
http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=e497988a-c93a-404c-b161-3a0b323dce24

Microsoft SQL Server Compact 3.5 Service Pack 2 for Windows Mobile 
http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=5544c638-c532-48e3-871c-58b49c5d855c

Microsoft SQL Server Compact 3.5 Service Pack 2 Server Tools 
http://www.microsoft.com/downloads/details.aspx?familyid=5DEEC9D5-C216-446E-A003-5D6026AD19B3&displaylang=en

Microsoft SQL Server Compact 3.5 Service Pack 2 Books Online
http://www.microsoft.com/downloads/details.aspx?FamilyID=746c3a6e-ffb1-4c92-93fa-b3ba41fde681&displaylang=en

 SQL Server Compact 3.5 SP2 includes a host of new features including the following:

  • Support for the Transact-SQL Editor in Visual Studio 2010 that can be used to run free-text T-SQL queries and to view query show-plans for optimizing queries.
  • Exposes the Change Tracking feature as an application programming interface (API), namely, System.Data.SqlServerCe.SqlCeChangeTracking. The new Change Tracking API provides the ability to configure, enable, and disable change tracking on a table, and to access the change tracking data for the table.
  • New assembly versioning support and directory structure that enables the SQL Server Compact applications that use private deployment to load SQL Server Compact assemblies from within the application folder if they are of a higher version than that in the global assembly cache (GAC).
  • Support added for deploying the 64-bit version of SQL Server Compact using the ClickOnce deployment.

Additional information about new features and bugs fixed in SP2 here: http://blogs.msdn.com/sqlservercompact/archive/2010/04/14/microsoft-sql-server-compact-3-5-with-service-pack-2-released-with-visual-studio-2010-and-on-the-web.aspx 

and here: http://erikej.blogspot.com/2009/10/whats-new-in-sql-server-compact-35-sp2.html

A list of post SP2 fixes is avilable here: http://erikej.blogspot.com/2010/08/sql-server-compact-35-sp2-downloadable.html

Information about a private deployment issue with the Entity Framework DLL (and a solution) is described here:http://blogs.msdn.com/sqlservercompact/archive/2010/05/12/troubleshooting-problem-with-private-deployment-of-sql-server-compact-3-5sp2-entity-dll.aspx

 

 

 

http://social.msdn.microsoft.com/Forums/en-US/sqlce/thread/9afbc156-bc64-4405-b90c-e07c74ed514c 

Visual Studio 2008 de mobile uygulamanızı deploy ederken uzun süre beklemeniz gerekiyor ve yavaşlık var ise, aşagıdaki ipucu ile hızlandırabilirsiniz.

 

1.  Bu dosyayı açıyoruz Notepad ile 

  %windir%\Microsoft.NET\Framework\v2.0.50727\Microsoft.CompactFramework.Common.Targets 

 

2. Bu satırı buluyoruz 

  Name="PlatformVerificationTask"> 

 

Aşagıdaki tagı ekliyoruz : 

    Condition="'$(SkipPlatformVerification)' != 'true'">

Kaydedin ve VS 2008 i yeniden açın. Bu kadar, şimdi hızın keyfini çıkartın  :)

 

 

 

SQL Server Versiyon unu Ögrenme

11 Haz 2012 In: ipucu

SQL server Versiyonunu ögrenmek için 

set nocount on
go 

select @@version
go 

select 'Edition: ' + convert(char(30), serverproperty('Edition'))
go 

select 'Product Version: ' + convert(char(20), serverproperty('ProductVersion'))
go 

select 'Product Level: ' + convert(char(20),serverproperty('ProductLevel'))
go 

set nocount off
go 

 

Çıktı :

Microsoft SQL Server 2008 (SP2) - 10.0.4000.0 (X64)   Sep 16 2010 19:43:16   Copyright (c) 1988-2008 Microsoft Corporation  Express Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) 

Edition: Express Edition (64-bit)      

Product Version: 10.0.4000.0         

Product Level: SP2                  

Her seferinde MS nin sitesinde aramaktan bıktım, buradan indirilebilir.

 

 Microsoft® SQL Server® 2008 R2 SP2 - Express Edition (with  Management Studio Express)

http://www.microsoft.com/en-us/download/details.aspx?id=30438

 

Microsoft SQL Server 2008 R2 RTM - Express 

http://www.microsoft.com/en-us/download/details.aspx?id=3743 

 

Microsoft SQL Server 2008 R2 RTM - Management Studio Express

http://www.microsoft.com/en-us/download/details.aspx?id=22985

 

RTM nedir diye sorarsanız : Released To Manufacturing. "üretim için yayımlamak" manasındaki. İşletim sistemleri, programlar vs., bütün testleri bittikten sonra CD ve/veya DVD'ye basım için ilgili firmaya yollanır. bu aşamaya RTM adı verilir.

 

 

Not : Direk indirme linkleri 

32 bit için Microsoft SQL Server 2008 R2 Express Edition with Advanced Services

http://download.microsoft.com/download/9/7/6/9761df25-cbd8-4d48-9415-065f6bd4e63d/SQLEXPRADV_x86_ENU.exe

64 bit için Microsoft SQL Server 2008 R2 Express Edition Database with Advanced Services

http://download.microsoft.com/download/9/7/6/9761df25-cbd8-4d48-9415-065f6bd4e63d/SQLEXPRADV_x64_ENU.exe

32 bit için Microsoft SQL Server 2008 R2 Express Edition Database with Management Tools

http://download.microsoft.com/download/5/5/8/558522e0-2150-47e2-8f52-ff4d9c3645df/SQLEXPRWT_x86_ENU.exe

64 bit için Microsoft SQL Server 2008 R2 Express Edition Database with Management Tools

http://download.microsoft.com/download/5/5/8/558522e0-2150-47e2-8f52-ff4d9c3645df/SQLEXPRWT_x64_ENU.exe

32 bit için Microsoft SQL Server 2008 R2 Express Edition Management Tools

http://download.microsoft.com/download/4/2/a/42a5a62f-9290-45cb-84cf-6a4e17888fde/SQLManagementStudio_x86_ENU.exe

64 bit için Microsoft SQL Server 2008 R2 Express Edition Management Tools

http://download.microsoft.com/download/4/2/a/42a5a62f-9290-45cb-84cf-6a4e17888fde/SQLManagementStudio_x86_ENU.exe

32 bit için Microsoft SQL Server 2008 R2 Express Edition Database Only

http://download.microsoft.com/download/5/1/a/51a153f6-6b08-4f94-a7b2-ba1ad482bc75/SQLEXPR_x86_ENU.exe

64 bit için Microsoft SQL Server 2008 R2 Express Edition Database Only

http://download.microsoft.com/download/5/1/a/51a153f6-6b08-4f94-a7b2-ba1ad482bc75/SQLEXPR_x64_ENU.exe

 

Bilgisayar başında ergonomik çalışma

22 Nis 2012 In: ipucu

SQL e dair bir kaç ip ucu

14 Mar 2012 In: ipucu, SQL

CONVERT(varchar(20), CAST(TBLMCEK.TUTAR AS money), 1) AS Tutar  //12,340.00

.Text.Replace(",", "").Replace(".", ",") 

 

 

INSER INTO Tablo() OUTPUT INSERTED.SIP_ID VALUES() 

 

CASE
WHEN TBLMCEK.SC_YERI = 'P' THEN 'Portföy'
WHEN TBLMCEK.SC_YERI = 'T' THEN 'Tahsil'
WHEN TBLMCEK.SC_YERI = 'E' THEN 'Teminat'
WHEN TBLMCEK.SC_YERI = 'C' THEN 'Ciro'
ELSE '-'
END AS Yeri, 

 

 SQL Serverda parasal tutarlar nasıl 99560,50 şeklinden  “99.560,50 TL” şekline kolayca formatlanabilir :

 

SELECT CARI_KOD, CARI_ISIM

CONVERT(VARCHAR,cast(SUM(BORC) AS MONEY),-1) + ‘ TL’     AS  TopBorc,

FROM CARI_HESAP_DOKUMU

 

–Bir önceki ayın son günü

SELECT  DATEADD(s,-1,DATEADD(mm, DATEDIFF(m,0,GETDATE()),0)) AS ONCEKI_AYIN_SONGUNU

 

–Şu anki ayın son günü

SELECT  DATEADD(s,-1,DATEADD(mm, DATEDIFF(m,0,GETDATE())+1,0)) AS SU_ANKI_AYIN_SONGUNU

 

–Sonraki ayın son günü bul

SELECT  DATEADD(s,-1,DATEADD(mm, DATEDIFF(m,0,GETDATE())+2,0)) AS SONRAKI_AYIN_SONGUNU

 

//ayın son günü bulma

//CONVERT(….,102) ile tarihi sade hale dönüştür (2011.03.25 gibi) yoksa 2011.03.25 23:59:59 olur

DECLARE @TARIH1 DATETIME
SET @TARIH1 = ’8/18/2011′
SELECT  CONVERT(VARCHAR(25),DATEADD(s,-1,DATEADD(mm, DATEDIFF(m,0,@TARIH1)+1,0)),102) AS AYIN_SON_GUNU

//ayın ilk gününü bulma

SELECT CONVERT(VARCHAR(25),DATEADD(dd,-(DAY(@TARIH1)-1),@TARIH1),102) AS AYIN_ILK_GUNU

 

//yılın ilk gününü bulma

SELECT CONVERT(VARCHAR,dateadd(year, datediff(year, ”, @TARIH1),”),102) AS YILIN_ILK_GUNU

 

//yılın son gününü

SELECT CONVERT(VARCHAR,dateadd(dd, 364, DATEADD(year, datediff(year, ”,@TARIH1),”)),102) AS YILIN_SON_GUNU

 

//sadece tarih bilgisi lazım olur :

SELECT CONVERT( VARCHAR, DATEADD(DAY,-0,GETDATE()) ,102) AS TARIH

 

//SQL CASE kullanımı

SELECT hg.*,

CASE
WHEN MDoviz = 'EUR' THEN (Convert(decimal(18,4),(SELECT TOP 1 kr.EURA FROM Kurlar kr WHERE KDate >= HDate)))
WHEN MDoviz = 'USD' THEN (Convert(decimal(18,4),(SELECT TOP 1 kr.USDA FROM Kurlar kr WHERE KDate >= HDate)))
ELSE 1
END AS Kur,

 

CASE
WHEN MDoviz = 'EUR' THEN (Convert(decimal(18,2),(SELECT TOP 1 kr.EURA FROM Kurlar kr WHERE KDate >= HDate)*MFiyat))
WHEN MDoviz = 'USD' THEN (Convert(decimal(18,2),(SELECT TOP 1 kr.USDA FROM Kurlar kr WHERE KDate >= HDate)*MFiyat))
ELSE 1*MFiyat
END AS TutarTL,

(SELECT u.Adi FROM Ulkeler u WHERE u.ULK_ID=hg.VARIS_ID) as Varis  

FROM HizliGirisler hg Where YIYD=1 

  

----- Bir tabloda tüm kullanıcıların tüm girişleri tutuluyor(dt,dv,usern), ama ben bir kullanıcının en son giriş yaptıgı cihaz nosunu almak istiyorum ----

 

WITH cte AS (SELECT *, CIH_ID as nCIH_ID FROM cihazlar)

SELECT a.CIH_ID, a.dt, a.dv, a.usern 

FROM cte a LEFT JOIN cte b

  ON a.usern=b.usern

 AND (a.nCIH_ID < b.nCIH_ID OR 

     (a.nCIH_ID = b.nCIH_ID AND a.dv<b.dv))

WHERE b.CIH_ID IS NULL and len(a.dv)>5

order by usern,dt,dv 

 

 

Selam, 

detayları sonra eklerim eger bir gridview a ait hücreden runtime'da bilgi almak istediginizde şu şekilde bir görüntü ile karşılaşırsanız:

       dtg_kpersonelim.Rows[2].Cells[2].Text     -->        &#199; eliker &#231; &#252;  

Bunun Çözümü : 

        HttpUtility.HtmlDecode (dtg_kpersonelim.Rows[2].Cells[2].Text); 

Şimdi tükçe karakterler düzgün bir çekilde gelicektir.

 

GridView to Ecxel

18 May 2011 In: .net, ipucu

Master page içinde kullanılacaksa

ilk olarak  EnableEventValidation="false"

Daha Sonra 

    public override void VerifyRenderingInServerForm(Control control)
    {
        if (control.ID != "GridView2")
            base.VerifyRenderingInServerForm(control);
    } 

 

    protected void lbtn_excele_Click(object sender, EventArgs e)
    {
        Response.Clear();
        Response.AddHeader("content-disposition", "attachment;filename=FileName.xls");
        Response.Charset = "windows-1254";;
        Response.Cache.SetCacheability(HttpCacheability.NoCache);
HttpContext.Current.Response.ContentEncoding = System.Text.Encoding.UTF8;
        Response.ContentType = "application/vnd.xls";

        System.IO.StringWriter stringWrite = new System.IO.StringWriter();
        System.Web.UI.HtmlTextWriter htmlWrite = new HtmlTextWriter(stringWrite);
        dtg_liste.RenderControl(htmlWrite);
        Response.Write(stringWrite.ToString());
        Response.End();
    } 

 

 

Türkçe karakter sorunu yaşıyorsanız :

            StringWriter sw = new StringWriter();
            HtmlTextWriter htw = new HtmlTextWriter(sw);
            dtg_DersiAlanlar.RenderControl(htw);

            Response.Clear();
            Response.ClearHeaders();
            Response.ClearContent();

            Response.Cache.SetCacheability(HttpCacheability.NoCache);
            Response.ContentEncoding = System.Text.Encoding.GetEncoding("windows-1254");

            Response.Charset = "windows-1254";
            Response.Buffer = true;

            this.EnableViewState = false;
            Response.ContentType = "application/vnd.xls";

            Response.AddHeader("content-disposition", "attachment;filename=" + lbl_dersadi.ToolTip.Trim() + "_" + ddl_budersialanlarinbolumleri.SelectedValue.Trim() + "_SinavSonuclari.xls");

            string header = "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n<html xmlns=\"http://www.w3.org/1999/xhtml\">\n<head>\n<title></title>\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=windows-1254\" />\n<style>\n</style>\n</head>\n<body>\n";

            Response.Write(header + sw);
            Response.End();

 

 

Ben Kimim ?

Celiker BahceciMerhabalar, ben Çeliker BAHÇECİ. 2004 den beri özel sektörde bilgisayar mühendisligi ve egitmenlik yapıyorum. Yine aynı yılın Ekim ayından beri sitemde .Net ile programlama ve hayat görüşüm ile ilgili makalelerimi yayınlıyorum. Blogum dışında Yazgelistir.com, mobilnedir.com gibi ineta kapsamındaki bir çok siteye Microsoft teknolojileri ile ilgili yazılar yazmaktayım.
Bu site ile sizinde hayatınızı anlamlandırmanızda bir parça katkımın olması dilegiyle...


Arşiv