<?xml version="1.0" ?>
<xs:schema id="LabSamples" targetNamespace="http://IndianaCrop.org/LabLink/TestSample.xsd"
	attributeFormDefault="qualified" elementFormDefault="qualified" xmlns:mstns="http://IndianaCrop.org/LabLink/TestSample.xsd"
	xmlns="http://IndianaCrop.org/LabLink/TestSample.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema"
	xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
	<xs:element name="Samples" msdata:IsDataSet="true">
		<xs:complexType>
			<xs:choice maxOccurs="unbounded">
				<xs:element name="Sample">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="SEQNO" minOccurs="1" msdata:Caption="Sequence Number">
								<xs:annotation>
									<xs:documentation>Used as for primary key - foreign key relationships between sample and tests</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:decimal"></xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="PRDNO" minOccurs="1" msdata:Caption="Producer No">
								<xs:annotation>
									<xs:documentation>
									Although this is all numbers it is stored as
									a string due to lead zeros.
								</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="9"></xs:maxLength>
										<xs:pattern value="\d{9}"></xs:pattern>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LCP2P" minOccurs="0" msdata:Caption="Second Copy-To">
								<xs:annotation>
									<xs:documentation>
									Although this is all numbers it is stored as
									a string due to lead zeros.
		
									This field provides a second company
									identifler to receive a copy of the results
									of testing.
								</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="9"></xs:maxLength>
										<xs:pattern value="\d{9}"></xs:pattern>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LCP3P" minOccurs="0" msdata:Caption="Third Copy-To">
								<xs:annotation>
									<xs:documentation>
									Although this is all numbers it is stored as
									a string due to lead zeros.
		
									This field provides a third company
									identifler to receive a copy of the results
									of testing.
								</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="9"></xs:maxLength>
										<xs:pattern value="\d{9}"></xs:pattern>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="CRPKN" minOccurs="1" msdata:Caption="Crop Kind">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="4"></xs:maxLength>
										<xs:enumeration value="CORN"></xs:enumeration>
										<xs:enumeration value="SOYS"></xs:enumeration>
										<xs:enumeration value="WHET"></xs:enumeration>
										<xs:enumeration value="ALFA"></xs:enumeration>
										<xs:enumeration value="BRLY"></xs:enumeration>
										<xs:enumeration value="CLOV"></xs:enumeration>
										<xs:enumeration value="CYST"></xs:enumeration>
										<xs:enumeration value="OATS"></xs:enumeration>
										<xs:enumeration value="RYE"></xs:enumeration>
										<xs:enumeration value="SORG"></xs:enumeration>
										<xs:enumeration value="SUNF"></xs:enumeration>
										<xs:enumeration value="TRIT"></xs:enumeration>
										<xs:enumeration value="MISC"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="VARNM" minOccurs="1" msdata:Caption="Variety Name">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="40"></xs:maxLength>
										<xs:whiteSpace value="collapse"></xs:whiteSpace>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LFLNO" minOccurs="0" msdata:Caption="Field No">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="20"></xs:maxLength>
										<xs:whiteSpace value="collapse"></xs:whiteSpace>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LGRAD" minOccurs="0" msdata:Caption="Grade Size">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="20"></xs:maxLength>
										<xs:whiteSpace value="collapse"></xs:whiteSpace>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LOTNO" minOccurs="0" msdata:Caption="Lot No">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="30"></xs:maxLength>
										<xs:whiteSpace value="collapse"></xs:whiteSpace>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LSMTP" minOccurs="0" msdata:Caption="Sample Type">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="2"></xs:maxLength>
										<xs:enumeration value="NL"></xs:enumeration>
										<xs:enumeration value="BL"></xs:enumeration>
										<xs:enumeration value="BT"></xs:enumeration>
										<xs:enumeration value="QC"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="CLASS" minOccurs="1" msdata:Caption="Class">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="5"></xs:maxLength>
										<xs:enumeration value="BREED"></xs:enumeration>
										<xs:enumeration value="CERT"></xs:enumeration>
										<xs:enumeration value="FOUND"></xs:enumeration>
										<xs:enumeration value="NCERT"></xs:enumeration>
										<xs:enumeration value="REG"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LSMPU" minOccurs="1" msdata:Caption="Sample Purpose">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="2"></xs:maxLength>
										<xs:enumeration value="FC"></xs:enumeration>
										<xs:enumeration value="IO"></xs:enumeration>
										<xs:enumeration value="QA"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LCOYR" minOccurs="0" msdata:Caption="Carry-over Year">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="4"></xs:maxLength>
										<xs:pattern value="\d{4}"></xs:pattern>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LBSLT" minOccurs="0" msdata:Caption="Bushels in Lot">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="5"></xs:maxLength>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LBCLT" minOccurs="0" msdata:Caption="Bushels Cleaned in Lot">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="5"></xs:maxLength>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LBKCR" minOccurs="0" msdata:Caption="Bulk Transfer Certificate No">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="9"></xs:maxLength>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LHNTR" minOccurs="1" msdata:Caption="Hand Treated">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="Y"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LSMBG" minOccurs="0" msdata:Caption="Sampled By">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="G"></xs:enumeration>
										<xs:enumeration value="I"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LSPCK" minOccurs="1" msdata:Caption="Spot Checked">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="Y"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LTRTC" minOccurs="1" msdata:Caption="Treated Code">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="Y"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LCRTC" minOccurs="1" msdata:Caption="Certification Code">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="C"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LCLNC" minOccurs="1" msdata:Caption="Cleaned Code">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="Y"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LGRPT" minOccurs="1" msdata:Caption="Growout Print Code">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="Y"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="LRRRS" minOccurs="0" msdata:Caption="Roundup Resistance Code">
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="1"></xs:maxLength>
										<xs:enumeration value="Y"></xs:enumeration>
										<xs:enumeration value="N"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
					<xs:key name="SampleKey1" msdata:PrimaryKey="true">
						<xs:selector xpath="." />
						<xs:field xpath="mstns:SEQNO" />
					</xs:key>
				</xs:element>
				<xs:element name="Tests">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="SEQNO" minOccurs="1" msdata:Caption="Sequence Number">
								<xs:simpleType>
									<xs:restriction base="xs:decimal"></xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="TEST" minOccurs="1" msdata:Caption="Test">
								<xs:annotation>
									<xs:documentation>A max of thirteen may appear for each sample due to size limitations of the bar code on the label</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:maxLength value="10"></xs:maxLength>
										<xs:enumeration value="AA"></xs:enumeration>
										<xs:enumeration value="CG"></xs:enumeration>
										<xs:enumeration value="CRW"></xs:enumeration>
										<xs:enumeration value="CRY9C"></xs:enumeration>
										<xs:enumeration value="CXA"></xs:enumeration>
										<xs:enumeration value="CXB"></xs:enumeration>
										<xs:enumeration value="CXC"></xs:enumeration>
										<xs:enumeration value="EBC"></xs:enumeration>
										<xs:enumeration value="F/S"></xs:enumeration>
										<xs:enumeration value="GT"></xs:enumeration>
										<xs:enumeration value="HXI"></xs:enumeration>
										<xs:enumeration value="HXX"></xs:enumeration>
										<xs:enumeration value="IMI"></xs:enumeration>
										<xs:enumeration value="ISOZY"></xs:enumeration>
										<xs:enumeration value="LL"></xs:enumeration>
										<xs:enumeration value="LPX"></xs:enumeration>
										<xs:enumeration value="MC"></xs:enumeration>
										<xs:enumeration value="MP"></xs:enumeration>
										<xs:enumeration value="NONBT"></xs:enumeration>
										<xs:enumeration value="NONRR"></xs:enumeration>
										<xs:enumeration value="PAGE"></xs:enumeration>
										<xs:enumeration value="PCR"></xs:enumeration>
										<xs:enumeration value="RR"></xs:enumeration>
										<xs:enumeration value="Sand"></xs:enumeration>
										<xs:enumeration value="SATCG"></xs:enumeration>
										<xs:enumeration value="SC"></xs:enumeration>
										<xs:enumeration value="SNP"></xs:enumeration>
										<xs:enumeration value="STS"></xs:enumeration>
										<xs:enumeration value="TZ"></xs:enumeration>
										<xs:enumeration value="VP"></xs:enumeration>
										<xs:enumeration value="WAXY"></xs:enumeration>
										<xs:enumeration value="WG"></xs:enumeration>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="SDCT" minOccurs="0" msdata:Caption="Num Seeds">
								<xs:annotation>
									<xs:documentation>The number of seed used in this test.</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:decimal">
										<xs:totalDigits value="4" />
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
				</xs:element>
			</xs:choice>
		</xs:complexType>
		<xs:key name="Sample_Key" msdata:PrimaryKey="true">
			<xs:selector xpath=".//mstns:Sample" />
			<xs:field xpath="mstns:SEQNO" />
		</xs:key>
		<xs:key name="SamplesTests_Key" msdata:PrimaryKey="true">
			<xs:selector xpath=".//mstns:Tests" />
			<xs:field xpath="mstns:SEQNO" />
			<xs:field xpath="mstns:TEST" />
		</xs:key>
		<xs:keyref name="Sample_SampleTests" refer="mstns:Sample_Key" msdata:DeleteRule="Cascade">
			<xs:selector xpath=".//mstns:Tests" />
			<xs:field xpath="mstns:SEQNO" />
		</xs:keyref>
	</xs:element>
</xs:schema>