blob: ea35e944c9cbe880e33c04638ff2cc16f19bf6dc [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta name="abstract" content=""/>
<meta name="description" content=""/>
<link rel="stylesheet" type="text/css" href="../css/documentation.css"/>
<title>Creating an OData Model Using Metadata File</title>
<!--[if lte IE 7]><style>
.codeblock{
overflow:visible;
}</style><![endif]-->
</head>
<body class="" id="loio499be3856baa45b1b2efacf2da6ea863">
<div id="wrapper"><div id="container">
<h1 class="title topictitle1">Creating an OData Model Using Metadata File</h1>
<div class="body taskbody"><p class="shortdesc"/>
<div class="section context" id="loio499be3856baa45b1b2efacf2da6ea863__context_N10015_N10012_N10001"><div class="tasklabel"><h2 class="sectiontitle tasklabel">Context</h2></div>
<p class="p">The File Import function is used to import metadata files types (edmx and xml) to
create an OData model.</p>
<div class="p">During the import of an EDMX file, the graphical information is computed, and the
corresponding shapes are created in the OData Model Editor and arranged as
follows:<ul class="ul" id="loio499be3856baa45b1b2efacf2da6ea863__ul_xsr_tjp_mj"><li class="li">Entities</li>
<li class="li">Complex Types</li>
<li class="li">Function Imports </li>
</ul>
</div>
<p class="p">To create an OData model using a service metadata file proceed as follows:</p>
</div><div class="tasklabel"><h2 class="sectiontitle tasklabel">Procedure</h2></div><ol class="ol steps" id="loio499be3856baa45b1b2efacf2da6ea863__steps_pzz_3kw_sp"><li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N10045_N10042_N10012_N10001"><span class="ph cmd">Create a project as outlined in the <a class="xref" href="028bcef958aa430e84a49cbc943b9709.html" title="Creating a project">Creating a Project</a>
section. </span></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N1004E_N10042_N10012_N10001"><span class="ph cmd">Right click on the project in the Project Tree region, and select <span class="ph menucascade"><img src="../images/navstart.gif" alt="Start of the navigation path" title="Start of the navigation path"/> <span class="ph uicontrol">New</span> <img src="../images/navstep.gif" alt="Next navigation step" title="Next navigation step"/> <span class="ph uicontrol">Other</span> <img src="../images/navend.gif" alt="End of the navigation path" title="End of the navigation path"/></span>.</span><div class="itemgroup stepresult">The <span class="ph emphasis emphasis">Select a Wizard </span>window displays. </div></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N10067_N10042_N10012_N10001"><span class="ph cmd">Locate <span class="ph emphasis emphasis">Ogee</span> folder, expand it and select <span class="ph emphasis emphasis">OData
Model</span>.</span></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N10078_N10042_N10012_N10001"><span class="ph cmd">Click <span class="ph emphasis emphasis">Next</span> to proceed.</span><div class="itemgroup stepresult">
<p class="p">The <span class="ph emphasis emphasis">Create New OData Model</span> window appears. </p>
</div></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N10091_N10042_N10012_N10001"><span class="ph cmd">Choose <span class="ph emphasis emphasis">Browse </span>or enter the folder name in the
<span class="ph emphasis emphasis">Folder</span> field to select a project folder for the new
OData model.</span></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N100A2_N10042_N10012_N10001"><span class="ph cmd">Enter a name for the model in the <span class="ph emphasis emphasis">Model name </span>field.</span></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N100AF_N10042_N10012_N10001"><span class="ph cmd">Select <span class="ph emphasis emphasis">OData Metadata File</span> from the list and click
<span class="ph emphasis emphasis">Next</span>. </span><div class="itemgroup stepresult">The <span class="ph emphasis emphasis">New OData model based on a metadata file</span> system
window appears.</div></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N100C8_N10042_N10012_N10001"><span class="ph cmd">Enter the path to access the edmx or xml file, or click
<span class="ph emphasis emphasis">Browse</span> to choose the file from the system and click
<span class="ph emphasis emphasis">Go</span>.</span><div class="itemgroup stepresult">On selection of a valid file the contents of the file will be populated
in the <span class="ph pname">Service details</span> region of the window.</div></li>
<li class="li step stepexpand" id="loio499be3856baa45b1b2efacf2da6ea863__step_N100D9_N10042_N10012_N10001"><span class="ph cmd">Click <span class="ph emphasis emphasis">Finish</span>.</span><div class="itemgroup stepresult">The selected file is converted to an OData service and displayed in the
OData Model Editor. All the sections in entity element open up in a expanded
state for editing.<div class="note note" id="loio499be3856baa45b1b2efacf2da6ea863__note_N100DF_N100DC_N100D1_N10042_N10012_N10001"><span class="notetitle">Note</span> The
errors in the imported model are indicated by the error icons. The
<span class="ph emphasis emphasis">Problems</span> tab view in the properties view displays
the errors in the model.</div>
<p class="p">The service is now ready to be edited and
will be stored under the folder selected in the Project Explorer.
</p>
</div></li>
</ol>
</div>
</div></div>
</body>
</html>