WCF, Entity Framework and N-tier solution RRS feed

  • Question

  • hi

    I've implemented WCF service using Entity Framework in a 3-Tier solution. I got it working, but what is puzzling me is why did I have to copy connection string ( specified in configuration file C1, which is used by Entity Framework to retrieve schema information from a database) into configuration file C2used WCF service? Namelly, if I don't copy the connection string, then I get:

        FaultException: The specified named connection is either not found in the confiuration, 
        not intended to be used with the EntityClient provider, or not valid.

    So it seems that C1's connection string is used by Entity Framework at design time, while during runtime connection string specified in C2 is used instead to connect to the database? Why?

    Thank you

    • Moved by Allen_MSDNModerator Monday, April 2, 2012 2:19 AM (From:ADO.NET Entity Framework and LINQ to Entities)
    Thursday, March 29, 2012 7:57 PM

All replies

  • Hi , Is your problem solved , if yes then please close the thread ,
    Tuesday, May 8, 2012 6:12 AM