Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6976709
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T17:31:55+00:00 2026-05-27T17:31:55+00:00

I added two new tables to the database: EmailCampaign and EmailTemplate. I updated the

  • 0

I added two new tables to the database: EmailCampaign and EmailTemplate.
I updated the EDMX with Update Model From Database.
The EDMX is in a RIA Services class library.

Now from the client side (a silverlight library) i cannot see the newly created entities only the old ones.
I checked the EF Designer.cs generated code and the new entities are there, i just cannot access them from the client.

I tried deleting and readding the EDMX but it didn’t work.

UPDATE
I figured out that the entities are exposed trough a Domain Service. I recreated the Domain Service and everything worked. But the problem becomes each time I have new tables in the database how do I regenerate the Domain Service without generating a new Domain Service .cs file and copy pasting my old code into the newly generated and solving all the errors that appear (each time the same). So it’s a burden. Are there some tools out there or some frameworks?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T17:31:56+00:00Added an answer on May 27, 2026 at 5:31 pm

    Partial classes are your friend! I broke my domain service class into smaller ones, grouping entities that I often use together – which is parralleled with my client side Model classes. So my main domain service class looks like this…

      [EnableClientAccess()]
      public partial class xxx_DomainService : LinqToEntitiesDomainService<xxxEntities>
      {
      }
    

    then each file contains this:

          public partial class xxx_DomainService : LinqToEntitiesDomainService<xxxEntities>
          {
             public IQueryAble<Address> GetAddresses()
             {
                return this.ObjectContext.Addressess;
             }
            ....more code
    
          }
    

    That way, if I change a table, I only have to re-create the domain service for the tables selected.

    This means that when I create the “new” table, I just use some bogus name, create the files, and subsequently replace the “public partial class ” line. The buddy files requires no changes at all. Just be careful of your namespaces!

    HTH,
    Richard

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Two new keywords added to the C# 5.0 language are async and await ,
I have a database that has two tables, one of which contains a foreign
I have a database driven navigation mainly composed of two tables: menus and a
I have two tables in an MS Access 2010 database: TBLIndividuals and TblIndividualsUpdates. They
I've recently added a couple of fields to some tables in my database (SQL
I have two tables that I'm querying from. In one table, there are fields
i want to insert two values into two tables of a sql database which
I have a machine with VmWare installed which added two extra network interfaces. The
I've a problem with the ScrollViews in Titanium in an iOS-app: I added two
I have a gridview that displays items details, I added two template fields one

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.