The model browser

Image

So far we’ve explored the primary designer surface that lets us manipulate the CDSL and the Mapping Details window that lets us manipulate the MSL. You can’t control the SSDL directly in the Entity Model Designer‑you have to do that in the Server Explorer or a tool like SQL Server Management Studio‑but you can view it using the last major component of the designer, the Model Browser. The Model Browser also shows you the structure of your conceptual model. Let’s see how it works.

You display the Model Browser the same way you display the Mapping Details Window: by right-clicking on a blank area of the primary designer surface. (But of course, this time you choose Model Browser from the menu.) It displays the CSDL and SSDL as a TreeView:

Image

Image On Your Own

You can use the Model Browser for more than just inspecting the EDMX, but we’ll look at that more advanced functionality in the next chapter. For right now, why don’t you explore the basic display and see if you can answer these questions?

How many entity sets are in our model?

 

What properties comprise the entity key of the RecipeIngredient entity? How can you tell?

 

How does inspecting entity keys in the Model Browser differ from selecting the properties individually on the primary designer surface?

 

What’s the data type of the RecipeName field as defined in the database? (Hint: check the Properties window.)

 

Is the table we deleted from the database (IngredientWeights) shown in the Model Browser?

 

There are two things that we haven’t yet discussed shown in the Model Browser. One is a node in RecipeModel, the other a node in the EntityContainers: RecipeEntities. What are they? What do you think they do?

 


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset