<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XML Spy v4.4 U (http://www.xmlspy.com) by Mike Overholt (Ashley Furniture Ind. / MIS Web Development) -->
<!--
Ver.   Date               By                     Action 
1.2     16-Sep-02     Mike Overholt    * Change "buyer" element name to "potentialBuyer" to reinforce that there is no actual sale involved.
								     * Change "shipTo" element name to "potentialShipTo" to reinforce that there is no actual sale involved.
								     * Change "seller" element name to "potentialSeller" to reinforce that there is no actual sale involved.
								     * Add "originalDocument" element to contain a reference to the original "inquiry" (if one exists).
								     * Extended the "document" element to include a required "purpose" attribute with 2 possible values: "advice" or "inquiry".
								     * Removed child elements from "availLocation" element and replaced them with attributes: "locationID" and "locationQualifier"
								               (The latter is based on the "location" type defined in our base schema.)
								     * Added "allInquiry" element to choice within "items" construct.
								               This element can be used to request inventory information for ALL items that can be purchased by potentialBuyer.
1.1     03-May-02     Mike Overholt    * Added the ability to specify a location (such as a warehouse) where inventory is located.
                                                          * Added a systemReference element within itemAvailability.
1.0     26-Apr-02     Mike Overholt    Original Creation
-->
<schema targetNamespace="http://xml.AshleyFurniture.com/xml/schemas/fnInvInqAdv_v1.2" xmlns:fniia="http://xml.AshleyFurniture.com/xml/schemas/fnInvInqAdv_v1.2" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:fnBase="http://support.furnishnet.com/xml/schemas/fnBase_v1.4" xmlns:fnItem="http://support.furnishnet.com/xml/schemas/fnItem_v1.4" xmlns:fnParty="http://support.furnishnet.com/xml/schemas/fnParty_v1.4" elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.1">
	<import namespace="http://support.furnishnet.com/xml/schemas/fnBase_v1.4" schemaLocation="http://support.furnishnet.com/xml/schemas/fn_base_v1.4.xsd"/>
	<import namespace="http://support.furnishnet.com/xml/schemas/fnItem_v1.4" schemaLocation="http://support.furnishnet.com/xml/schemas/fn_item_v1.4.xsd"/>
	<import namespace="http://support.furnishnet.com/xml/schemas/fnParty_v1.4" schemaLocation="http://support.furnishnet.com/xml/schemas/fn_party_v1.4.xsd"/>
	<!--
	<import namespace="http://support.furnishnet.com/xml/schemas/fnBase_v1.4" schemaLocation="fn_base_v1.4.xsd"/>
	<import namespace="http://support.furnishnet.com/xml/schemas/fnItem_v1.4" schemaLocation="fn_item_v1.4.xsd"/>
	<import namespace="http://support.furnishnet.com/xml/schemas/fnParty_v1.4" schemaLocation="fn_party_v1.4.xsd"/>
-->
	<element name="inventoryInqAdv" type="fniia:inventoryInqAdvType">
		<annotation>
			<documentation>Root element of the Furniture Industry "Inventory Inquiry and Advice" schema.</documentation>
		</annotation>
	</element>
	<complexType name="inventoryInqAdvType">
		<sequence>
			<element name="inquiry" type="fniia:inventoryInqAdvInquiryType">
				<annotation>
					<documentation>Transaction header</documentation>
				</annotation>
			</element>
			<element name="items" type="fniia:inventoryInqAdvIemsType">
				<annotation>
					<documentation>Transaction detail</documentation>
				</annotation>
			</element>
		</sequence>
	</complexType>
	<complexType name="inventoryItemInquiryType">
		<sequence>
			<element name="itemId" type="fnItem:itemIdentifierType">
				<annotation>
					<documentation>Identifies the item that availability is being requested for.</documentation>
				</annotation>
			</element>
			<element name="itemQty" type="fnBase:quantityType" minOccurs="0">
				<annotation>
					<documentation>Quantity of the item that the potential customer may be interested in purchasing.</documentation>
				</annotation>
			</element>
			<element name="itemInqSystemReference" type="fnBase:systemReferenceType" minOccurs="0" maxOccurs="unbounded">
				<annotation>
					<documentation>A system reference facilitates automated processing of the document by including data elements that are not necessarily part of a standard transaction but are required or desired by the computer systems of the trading partners.  Effective use of system references requires pre-arrangement between trading partners.  NOTE: this structure should not be used for data that is otherwise accommodated within a transaction schema.</documentation>
				</annotation>
			</element>
		</sequence>
		<attribute name="lineItemNumber" type="positiveInteger" use="optional"/>
		<attribute name="comment" type="string" use="optional"/>
		<attribute name="shipToID" type="string" use="optional"/>
	</complexType>
	<complexType name="inventoryItemAdviceType">
		<sequence>
			<element name="itemId" type="fnItem:itemIdentifierType">
				<annotation>
					<documentation>Identifies the item for which availability is being provided.</documentation>
				</annotation>
			</element>
			<element name="itemAvailability" type="fniia:inventoryItemAvailabilityType" maxOccurs="unbounded">
				<annotation>
					<documentation>Indicate either quantity currently available or future quantity and availabiity date. set up to accommodate both a current quantity and a future quantity.</documentation>
				</annotation>
			</element>
			<element name="itemAdvSystemReference" type="fnBase:systemReferenceType" minOccurs="0" maxOccurs="unbounded">
				<annotation>
					<documentation>A system reference facilitates automated processing of the document by including data elements that are not necessarily part of a standard transaction but are required or desired by the computer systems of the trading partners.  Effective use of system references requires pre-arrangement between trading partners.  NOTE: this structure should not be used for data that is otherwise accommodated within a transaction schema.</documentation>
				</annotation>
			</element>
		</sequence>
		<attribute name="lineItemNumber" type="positiveInteger" use="optional"/>
		<attribute name="comment" type="string" use="optional"/>
		<attribute name="shipToID" type="string" use="optional"/>
	</complexType>
	<complexType name="inventoryItemAvailabilityType">
		<sequence>
			<element name="availQty" type="fnBase:quantityType">
				<annotation>
					<documentation>Quantity available either currently or on the Availability Date provided.</documentation>
				</annotation>
			</element>
			<element name="availDate" type="date" minOccurs="0">
				<annotation>
					<documentation>Date on which the quantity provided will become available.</documentation>
				</annotation>
			</element>
			<element name="availLocation" type="fniia:inventoryInqAdvItemLocationType" minOccurs="0">
				<annotation>
					<documentation>Location at which the item is or will be available.</documentation>
				</annotation>
			</element>
			<element name="availSystemReference" type="fnBase:systemReferenceType" minOccurs="0" maxOccurs="unbounded">
				<annotation>
					<documentation>A system reference facilitates automated processing of the document by including data elements that are not necessarily part of a standard transaction but are required or desired by the computer systems of the trading partners.  Effective use of system references requires pre-arrangement between trading partners.  NOTE: this structure should not be used for data that is otherwise accommodated within a transaction schema.</documentation>
				</annotation>
			</element>
		</sequence>
		<attribute name="availability" use="required">
			<simpleType>
				<restriction base="string">
					<enumeration value="current"/>
					<enumeration value="future"/>
				</restriction>
			</simpleType>
		</attribute>
	</complexType>
	<complexType name="inventoryInqAdvIemsType">
		<choice>
			<element name="allInquiry">
				<annotation>
					<documentation>Use this element to inquire into the availability of all items.</documentation>
				</annotation>
				<complexType>
					<simpleContent>
						<extension base="boolean">
							<attribute name="comment" type="string" use="optional"/>
						</extension>
					</simpleContent>
				</complexType>
			</element>
			<element name="itemInquiry" type="fniia:inventoryItemInquiryType" maxOccurs="unbounded">
				<annotation>
					<documentation>Use this structure to inquire into the availability of one or  more specific items.</documentation>
				</annotation>
			</element>
			<element name="itemAdvice" type="fniia:inventoryItemAdviceType" maxOccurs="unbounded">
				<annotation>
					<documentation>Use this structure to provide information regarding availability of one or more items.</documentation>
				</annotation>
			</element>
		</choice>
	</complexType>
	<complexType name="inventoryInqAdvInquiryType">
		<sequence>
			<element name="document">
				<annotation>
					<documentation>Identification information for this document.</documentation>
				</annotation>
				<complexType>
					<complexContent>
						<extension base="fnBase:documentType">
							<attribute name="purpose" use="required">
								<simpleType>
									<restriction base="string">
										<enumeration value="advice"/>
										<enumeration value="inquiry"/>
									</restriction>
								</simpleType>
							</attribute>
						</extension>
					</complexContent>
				</complexType>
			</element>
			<element name="originalDocument" type="fnBase:documentType" minOccurs="0">
				<annotation>
					<documentation>Identification information for the original document to which this is a response. Use only when appropriate.</documentation>
				</annotation>
			</element>
			<element name="potentialBuyer" type="fnParty:partyIdentificationType" minOccurs="0">
				<annotation>
					<documentation>Identification of party that is / may be interested in purchasing item(s) listed in document.</documentation>
				</annotation>
			</element>
			<element name="potentialShipTo" type="fnParty:shipToPartyType" minOccurs="0" maxOccurs="unbounded">
				<annotation>
					<documentation>Identification of specific locations that the customer is interested in purchasing the item(s) for. Seller might use this to check availability in the most appropriate warehouse(s).</documentation>
				</annotation>
			</element>
			<element name="potentialSeller" type="fnParty:partyIdentificationType" minOccurs="0">
				<annotation>
					<documentation>Identification of the party that inventory information is being requested from / reported by.</documentation>
				</annotation>
			</element>
			<element name="inquirySystemReference" type="fnBase:systemReferenceType" minOccurs="0" maxOccurs="unbounded">
				<annotation>
					<documentation>A system reference facilitates automated processing of the document by including data elements that are not necessarily part of a standard transaction but are required or desired by the computer systems of the trading partners.  Effective use of system references requires pre-arrangement between trading partners.  NOTE: this structure should not be used for data that is otherwise accommodated within a transaction schema.</documentation>
				</annotation>
			</element>
		</sequence>
		<attribute name="comment" type="string" use="optional"/>
	</complexType>
	<complexType name="inventoryInqAdvItemLocationType">
		<attribute name="locationQualifier" type="fnBase:locationType" use="required"/>
		<attribute name="locationID" type="string" use="required"/>
	</complexType>
</schema>
