# EmployeeMarital.xsd Sample

This topic inludes the source code for the EmployeeMarital.xsd Sample.

## Sample Location

This sample is located in the following directory in your WebLogic Workshop installation:

BEA_HOME/weblogic81/samples/workshop/SamplesApp/Schemas/

## Sample Source Code

`01 <?xml version="1.0" encoding="UTF-8"?> 02 <xs:schema targetNamespace="http://openuri.org/bea/samples/workshop/xmlBeans/maritalStatus" xmlns:ms="http://openuri.org/bea/samples/workshop/xmlBeans/maritalStatus" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> 03 <xs:element name="employee"> 04 <xs:complexType> 05 <xs:sequence> 06 <xs:element name="first-name" type="xs:string"/> 07 <xs:element name="last-name" type="xs:string"/> 08 <xs:element ref="ms:marital-status"/> 09 <xs:choice> 10 <xs:element name="spouse-name" type="xs:string"/> 11 <xs:element name="partner-name" type="xs:string"/> 12 </xs:choice> 13 </xs:sequence> 14 </xs:complexType> 15 </xs:element> 16 <xs:element name="marital-status"> 17 <xs:simpleType> 18 <xs:restriction base="xs:string"> 19 <xs:enumeration value="Married"/> 20 <xs:enumeration value="Single"/> 21 <xs:enumeration value="Domestic partner"/> 22 </xs:restriction> 23 </xs:simpleType> 24 </xs:element> 25 </xs:schema>`