<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.dotnetzone.gr:443/cs/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>ADO.NET</title><link>https://www.dotnetzone.gr:443/cs/forums/78/ShowForum.aspx</link><description>Θέματα σχετικά με την προσπέλαση δεδομένων μέσω του ADO.NET και του System.Data namespace</description><dc:language>el</dc:language><generator>CommunityServer 2.1 SP3 (Build: 20423.1)</generator><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61410.aspx</link><pubDate>Thu, 09 Dec 2010 23:15:28 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61410</guid><dc:creator>nikolaosk</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61410.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61410</wfw:commentRss><description>και αυτό &lt;a href="http://codeclimber.net.nz/archive/2010/12/08/Logging-all-SQL-statements-done-by-Entity-Framework.aspx?utm_source=feedburner&amp;amp;utm_medium=feed&amp;amp;utm_campaign=Feed%3A+Codeclimber+%28CodeClimber%29"&gt;εδώ&lt;/a&gt; το post, συνεισφέρει στην κουβέντα που έχουμε για "logging sql statements produced by EF4"&lt;br&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61349.aspx</link><pubDate>Tue, 07 Dec 2010 18:58:01 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61349</guid><dc:creator>George J. Capnias</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61349.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61349</wfw:commentRss><description>&lt;BLOCKQUOTE&gt;&lt;div&gt;&lt;img src="http://www.dotnetzone.gr/cs/Themes/default/images/icon-quote.gif"&gt; &lt;strong&gt;Antonios Chatzipavlis:&lt;/strong&gt;&lt;/div&gt;&lt;div&gt;&lt;P&gt;Ωραία άσκηση μου έδωσες Γιώργη ;)&lt;/P&gt;&lt;P&gt;Για να δούμε τι ψάρια πιάνει το EF θα χρησιμοποιήσω τα εργαλεία αυτά σε συνάρτηση με τον φίλο μου τον SQL Server Profiler&lt;/P&gt;&lt;P&gt;&lt;/div&gt;&lt;/BLOCKQUOTE&gt;&lt;/P&gt;&lt;P&gt;Αν βάλεις το &lt;A href="http://efprof.com/"&gt;EFProf&lt;/A&gt; του Ayende δεν θες κάτι άλλο - πάρε&amp;nbsp;την trial για τις δοκιμές σου. &lt;/P&gt;&lt;P&gt;Μόνο μια γραμμή κώδικα θα πρέπει να&amp;nbsp;προσθέσεις για να παίξει - καμιά άλλη αλλαγή στον υπάρχοντα κώδικά σου.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;George J.&lt;BR&gt;&lt;/P&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61345.aspx</link><pubDate>Tue, 07 Dec 2010 09:13:26 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61345</guid><dc:creator>pmatsinopoulos</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61345.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61345</wfw:commentRss><description>&lt;P&gt;Για αυτούς που θέλουν να το δοκιμάσουν:&lt;/P&gt;
&lt;P&gt;1) IntelliTrace. Εντάξει, αυτό είναι απλό και παίζει με το Visual Studio Ultimate. Έχει το πρόβλημα ότι δεν δείχνει τις τιμές των παραμέτρων όπως αναφέρει και η Lerman στο άρθρο της.&lt;/P&gt;
&lt;P&gt;2) EFTracingProvider. Κατέβασα την έκδοση που είναι επικαιροποιημένη για το Entity Framework 4. Από &lt;A href="http://code.msdn.microsoft.com/EFProviderWrappers/Release/ProjectReleases.aspx?ReleaseId=4747"&gt;εδώ&lt;/A&gt;.&amp;nbsp;Στο παράδειγμα που έκανα χρησιμοποίησα την AdventureWorks2008. Αυτά που χρειάστηκαν να κάνω ήταν τα εξής:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; 2.1.) Έκανα extend την AdvenctureWorks2008Entities ως εξής (το σχετικό κώδικα τον βρήκα &lt;A href="http://blogs.msdn.com/b/jkowalski/archive/2009/06/11/tracing-and-caching-in-entity-framework-available-on-msdn-code-gallery.aspx"&gt;εδώ&lt;/A&gt; (όπως μου υποδείξατε) αλλά έκοψα το caching):&lt;/P&gt;
&lt;P&gt;
&lt;TABLE style="BORDER-BOTTOM:#e5e5e5 1px solid;BORDER-LEFT:#e5e5e5 1px solid;BACKGROUND-COLOR:#f2f2f2;BORDER-TOP:#e5e5e5 1px solid;BORDER-RIGHT:#e5e5e5 1px solid;" border=0 cellSpacing=0 cellPadding=0 width="100%"&gt;

&lt;TR style="LINE-HEIGHT:normal;VERTICAL-ALIGN:top;"&gt;
&lt;TD style="TEXT-ALIGN:right;WIDTH:40px;"&gt;&lt;PRE style="PADDING-BOTTOM:2px;MARGIN:0px;PADDING-LEFT:2px;PADDING-RIGHT:2px;FONT-FAMILY:courier new;COLOR:gray;FONT-SIZE:11px;BORDER-RIGHT:#e7e7e7 1px solid;PADDING-TOP:2px;"&gt;1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
 &lt;/PRE&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;PRE style="PADDING-BOTTOM:2px;MARGIN:0px;PADDING-LEFT:8px;PADDING-RIGHT:2px;PADDING-TOP:2px;"&gt;&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:black;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;    &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; partial &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;class&lt;/SPAN&gt; ExtendedAdventureWorks2008Entities : AdventureWorks2008Entities
    {
        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;private&lt;/SPAN&gt; TextWriter logOutput;

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; ExtendedAdventureWorks2008Entities()
            : &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;(&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"name=AdventureWorks2008Entities"&lt;/SPAN&gt;)
        {
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; ExtendedAdventureWorks2008Entities(&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;string&lt;/SPAN&gt; connectionString)
            : &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;base&lt;/SPAN&gt;(EntityConnectionWrapperUtils.CreateEntityConnectionWithWrappers(
                    connectionString,
                    &lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFTracingProvider"&lt;/SPAN&gt;
            ))
        {
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;#region&lt;/SPAN&gt; Tracing Extensions

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;private&lt;/SPAN&gt; EFTracingConnection TracingConnection
        {
            get { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;return&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.UnwrapConnection&amp;lt;EFTracingConnection&amp;gt;(); }
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;event&lt;/SPAN&gt; EventHandler&amp;lt;CommandExecutionEventArgs&amp;gt; CommandExecuting
        {
            add { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.TracingConnection.CommandExecuting += value; }
            remove { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.TracingConnection.CommandExecuting -= value; }
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;event&lt;/SPAN&gt; EventHandler&amp;lt;CommandExecutionEventArgs&amp;gt; CommandFinished
        {
            add { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.TracingConnection.CommandFinished += value; }
            remove { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.TracingConnection.CommandFinished -= value; }
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;event&lt;/SPAN&gt; EventHandler&amp;lt;CommandExecutionEventArgs&amp;gt; CommandFailed
        {
            add { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.TracingConnection.CommandFailed += value; }
            remove { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.TracingConnection.CommandFailed -= value; }
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;private&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;void&lt;/SPAN&gt; AppendToLog(&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;object&lt;/SPAN&gt; sender, CommandExecutionEventArgs e)
        {
            &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;if&lt;/SPAN&gt; (&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.logOutput !&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:red;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;null&lt;/SPAN&gt;)
            {
                &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.logOutput.WriteLine(e.ToTraceString().TrimEnd());
                &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.logOutput.WriteLine();
            }
        }

        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;public&lt;/SPAN&gt; TextWriter Log
        {
            get { &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;return&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.logOutput; }
            set
            {
                &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;if&lt;/SPAN&gt; ((&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.logOutput !&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:red;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;null&lt;/SPAN&gt;) !&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:red;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;=&lt;/SPAN&gt; (value !&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:red;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;null&lt;/SPAN&gt;))
                {
                    &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;if&lt;/SPAN&gt; (value == &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;null&lt;/SPAN&gt;)
                    {
                        CommandExecuting -= AppendToLog;
                    }
                    &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;else&lt;/SPAN&gt;
                    {
                        CommandExecuting += AppendToLog;
                    }
                }

                &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;this&lt;/SPAN&gt;.logOutput &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:red;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;=&lt;/SPAN&gt; value;
            }
        }


        &lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:blue;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;#endregion&lt;/SPAN&gt;
    }&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TABLE&gt;&lt;/P&gt;
&lt;P&gt;2.2) Στο app.config file της εφαρμογής πρόσθεσα τα παρακάτω:&lt;/P&gt;
&lt;P&gt;
&lt;TABLE style="BORDER-BOTTOM:#e5e5e5 1px solid;BORDER-LEFT:#e5e5e5 1px solid;BACKGROUND-COLOR:#f2f2f2;BORDER-TOP:#e5e5e5 1px solid;BORDER-RIGHT:#e5e5e5 1px solid;" border=0 cellSpacing=0 cellPadding=0 width="100%"&gt;

&lt;TR style="LINE-HEIGHT:normal;VERTICAL-ALIGN:top;"&gt;
&lt;TD style="TEXT-ALIGN:right;WIDTH:40px;"&gt;&lt;PRE style="PADDING-BOTTOM:2px;MARGIN:0px;PADDING-LEFT:2px;PADDING-RIGHT:2px;FONT-FAMILY:courier new;COLOR:gray;FONT-SIZE:11px;BORDER-RIGHT:#e7e7e7 1px solid;PADDING-TOP:2px;"&gt;1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
 &lt;/PRE&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;PRE style="PADDING-BOTTOM:2px;MARGIN:0px;PADDING-LEFT:8px;PADDING-RIGHT:2px;PADDING-TOP:2px;"&gt;&lt;SPAN style="BACKGROUND-COLOR:transparent;FONT-FAMILY:Courier New;COLOR:black;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;&amp;lt;system.data&amp;gt;
		&amp;lt;DbProviderFactories&amp;gt;
			&amp;lt;add name=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EF Tracing Data Provider"&lt;/SPAN&gt;
				 invariant=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFTracingProvider"&lt;/SPAN&gt;
				 description=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"Tracing Provider Wrapper"&lt;/SPAN&gt;
				 type=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFTracingProvider.EFTracingProviderFactory, EFTracingProvider, Version=1.0.0.0, Culture=neutral, PublicKeyToken=def642f226e0e59b"&lt;/SPAN&gt; /&amp;gt;
			&amp;lt;add name=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EF Generic Provider Wrapper"&lt;/SPAN&gt;
				 invariant=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFProviderWrapper"&lt;/SPAN&gt;
				 description=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"Generic Provider Wrapper"&lt;/SPAN&gt;
				 type=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFProviderWrapperToolkit.EFProviderWrapperFactory, EFProviderWrapperToolkit, Version=1.0.0.0, Culture=neutral, PublicKeyToken=def642f226e0e59b"&lt;/SPAN&gt; /&amp;gt;
		&amp;lt;/DbProviderFactories&amp;gt;
	&amp;lt;/system.data&amp;gt;
	&amp;lt;appSettings&amp;gt;
		&amp;lt;!-- write log messages to the console. --&amp;gt;
		&amp;lt;add key=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFTracingProvider.logToConsole"&lt;/SPAN&gt; value=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"false"&lt;/SPAN&gt; /&amp;gt;

		&amp;lt;!-- append log messages to the specified file --&amp;gt;
		&amp;lt;add key=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"EFTracingProvider.logToFile"&lt;/SPAN&gt; value=&lt;SPAN style="BACKGROUND-COLOR:#e4e4e4;FONT-FAMILY:Courier New;COLOR:#666666;FONT-SIZE:11px;FONT-WEIGHT:normal;"&gt;"sqllog.txt"&lt;/SPAN&gt; /&amp;gt;
	&amp;lt;/appSettings&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TABLE&gt;&lt;/P&gt;
&lt;P&gt;Και αυτό ήταν!!!! &lt;/P&gt;
&lt;P&gt;Όλα τα SQL commands μου γράφτηκαν στο sqllog.txt.&lt;/P&gt;
&lt;P&gt;Αρκετά καλά και απλά!&lt;/P&gt;
&lt;P&gt;Και θα πει κάποιος: "Μα καλά, θα πάω τώρα παντού, όπου έχω γράψει 'new AdventureWorks2008Entitie()' και θα το αλλάξω σε 'new ExtendedAdventureWorks2008Entities()'?"&lt;/P&gt;
&lt;P&gt;Την απάντηση μάλλον θα τη δώσει το Factory pattern. Κακώς εξαρχής γράφουμε new ΧΧ(). Γιατί καρφώνουμε τον τρόπο που κάνουμε construct τα αντικείμενά μας. Πρέπει να χρησιμοποιούμε Factory methods. (π.χ. using (var context = ContextFactory.create()) { ... })&lt;/P&gt;
&lt;P&gt;Θα κοιτάξω τώρα και τα εργαλεία που αναφέρατε σχετικά με το logging.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61344.aspx</link><pubDate>Tue, 07 Dec 2010 09:09:01 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61344</guid><dc:creator>Antonios Chatzipavlis</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61344.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61344</wfw:commentRss><description>&lt;P&gt;Ωραία άσκηση μου έδωσες Γιώργη ;)&lt;/P&gt;&lt;P&gt;Για να δούμε τι ψάρια πιάνει το EF θα χρησιμοποιήσω τα εργαλεία αυτά σε συνάρτηση με τον φίλο μου τον SQL Server Profiler&lt;/P&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61343.aspx</link><pubDate>Tue, 07 Dec 2010 08:42:34 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61343</guid><dc:creator>pmatsinopoulos</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61343.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61343</wfw:commentRss><description>&lt;P&gt;Ευχαριστώ πολύ και τους δυό.&lt;/P&gt;
&lt;P&gt;Ήδη δοκίμασα το IntelliTrace. Και τώρα προχωρώ στο EFTracingProvider. Θα κοιτάξω μετά και τα εμπορικά εργαλεία. &lt;/P&gt;
&lt;P&gt;Ευχαριστώ και πάλι.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61342.aspx</link><pubDate>Tue, 07 Dec 2010 08:33:56 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61342</guid><dc:creator>nikolaosk</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61342.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61342</wfw:commentRss><description>Γιώργο πρέπει να συγχρονιστούμε.... &amp;nbsp;&amp;nbsp; :)&lt;br&gt;&lt;br&gt;Φίλε μου, ο Γιώργος έχει δίκιο, ότι θες είναι στο άρθρο της Julie που ούτε και εγώ το είχα υπόψιν μου.&lt;br&gt;&lt;br&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61341.aspx</link><pubDate>Tue, 07 Dec 2010 08:31:46 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61341</guid><dc:creator>nikolaosk</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61341.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61341</wfw:commentRss><description>Νομίζω έχεις πιάσει ακριβώς το μεγάλο θέμα-ανησυχία που υπάρχει σε όσους συναδέλφους χρησιμοποιούν το EF σαν την data access τεχνολογία τους.&lt;br&gt;&lt;br&gt;Αν έχεις budget, σου προτείνω ανεπιφύλακτα (το προτείνει και η Julie Lermann ) το καταπληκτικό αυτό &lt;a href="http://efprof.com/home"&gt;εργαλείο&lt;/a&gt;.&lt;br&gt;&lt;br&gt;Αλλιώς , δες αυτό εδώ το &lt;a href="http://blogs.msdn.com/b/jkowalski/archive/2009/06/11/tracing-and-caching-in-entity-framework-available-on-msdn-code-gallery.aspx"&gt;post&lt;/a&gt; . Αν δεις την προηγούμενη δημοσίευση θα καταλάβεις ότι πρόκειται για wrappers που κάνουν extend το EF. Μπορείς να τους κατεβάσεις από &lt;a href="http://code.msdn.microsoft.com/EFProviderWrappers"&gt;εδώ&lt;/a&gt;.&lt;br&gt;&lt;br&gt;Επίσης ένα καλό εργαλείο είναι το &lt;a href="http://www.huagati.com/L2SProfiler/"&gt;Huagati Query Profiler&lt;/a&gt; .&lt;br&gt;</description></item><item><title>Απ: Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61340.aspx</link><pubDate>Tue, 07 Dec 2010 07:59:46 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61340</guid><dc:creator>George J. Capnias</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61340.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61340</wfw:commentRss><description>&lt;P&gt;Δες το άρθρο&amp;nbsp;&lt;A href="http://msdn.microsoft.com/magazine/gg490349"&gt;Profiling Database Activity in the Entity Framework&lt;/A&gt;&amp;nbsp;της Julie Lerman στο MSDN Magazine αυτού του μήνα... Δεν έχει ξεχάσει να παραλείψει τίποτα!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;George J.&lt;BR&gt;&lt;/P&gt;</description></item><item><title>Entity Framework 4, Log SQL</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/61339.aspx</link><pubDate>Tue, 07 Dec 2010 07:45:30 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:61339</guid><dc:creator>pmatsinopoulos</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/61339.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=78&amp;PostID=61339</wfw:commentRss><description>&lt;P&gt;Καλησπέρα,&lt;/P&gt;
&lt;P&gt;Υπάρχει τρόπος, στο Entity Framework 4, να κάνω log τα SQL statements που στέλνει στη βάση; Εκτός του SQL Profiler.&lt;/P&gt;
&lt;P&gt;Ευχαριστώ πολύ&lt;/P&gt;</description></item></channel></rss>