sgmlguru / xlsx2xml

Excel to XML pipelined conversion
0 stars 1 forks source link

Map input colleges #1

Open sgmlguru opened 4 years ago

sgmlguru commented 4 years ago

Any college using an Excel spreadhseet as input should have its semantics mapped to the exchange format using the XML generated by UTIL_generate-map-skeleton.xsl.

sgmlguru commented 4 years ago

Activate_Learning and Morley_College are reasonably well mapped. Surrey is not - that spreadsheet is a half broken DB dump, I think.

sgmlguru commented 4 years ago

The format looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<providers xmlns="http://www.sgmlguru/ns/xproc/steps">

    <provider id="TEMPLATE">
        <item coord="Excel spreadsheet coordinate, i.e. A1" source="Excel column name" target="Exchange target element"/>
    </provider>

    <!-- Activate Learning -->
    <provider id="Activate_Learning">
        <item coord="A" source="Course Code" target="course-uniqueIdentifier">Course Code</item>
        <item coord="B" source="StartDate" target="duration-start">StartDate</item>
        <item coord="C" source="EndDate" target="duration-end">EndDate</item>
        <item coord="D" source="Site_Desc" target="location-description">Site_Desc</item>
        <item coord="E" source="LocationDesc" target="location-place">LocationDesc</item>
        <item coord="F" source="Faculty" target="provider-field">Faculty</item>
        <item coord="G" source="Sector" target="provider-field">Sector</item>
        <item coord="H" source="MIS Subject category" target="categories-categoryMIS">MIS Subject
            category</item>
        <item coord="I" source="Findcourses category 1" target="categories-category1">Findcourses
            category 1</item>
        <item coord="J" source="Findcourses category 2" target="categories-category2">Findcourses
            category 2</item>
        <item coord="K" source="WebsiteCourseTitle" target="course-name">WebsiteCourseTitle</item>
        <item coord="L" source="Length_Days" target="duration-days">Length_Days</item>
        <item coord="M" source="Length_Weeks" target="duration-weeks">Length_Weeks</item>
        <item coord="N" source="Length_Years" target="duration-years">Length_Years</item>
        <item coord="O" source="Times" target="course-field">Times</item>
        <item coord="P" source="Mode" target="event-pace">Mode</item>
        <item coord="Q" source="16free8" target="event-price">16free8</item>
        <item coord="R" source="Adult" target="event-price">Adult</item>
        <item coord="S" source="Web address to the course" target="course-link">Web address to the
            course</item>
        <item coord="T" source="QualificationType" target="qualification-type"
            >QualificationType</item>
        <item coord="U" source="PageSummary" target="course-field">PageSummary</item>
        <item coord="V" source="pagebody" target="course-description">pagebody</item>
        <item coord="W" source="WhatIllLearn" target="course-field">WhatIllLearn</item>
        <item coord="X" source="HowIllLearn" target="course-field">HowIllLearn</item>
        <item coord="Y" source="HowIllBeAssessed" target="course-field">HowIllBeAssessed</item>
        <item coord="Z" source="EntryRequirements" target="course-field">EntryRequirements</item>
        <item coord="AA" source="HowToApply" target="course-field">HowToApply</item>
    </provider>

    <provider xmlns="http://www.sgmlguru/ns/xproc/steps" id="Morley_College">
        <item coord="A" source="Education Title" target="course-name">Education Title</item>
        <item coord="B" source="Education Type" target="course-field">Education Type</item><!-- FIXME -->
        <item coord="C" source="Link" target="course-link">Link</item>
        <item coord="D" source="Duration" target="duration-time">Duration</item><!-- FIXME -->
        <item coord="E" source="Duration Unit" target="duration-unit">Duration Unit</item><!-- FIXME -->
        <item coord="F" source="School" target="location-description">School</item>
        <item coord="G" source="Programme Area" target="categories-category1">Programme Area</item>
        <item coord="H" source="Subject" target="categories-category2">Subject</item>
        <item coord="I" source="Email Receivers" target="email-receiver">Email Receivers</item><!-- FIXME -->
        <item coord="J" source="Degree" target="course-field">Degree</item><!-- FIXME -->
        <item coord="K" source="Description" target="course-description">Description</item>
        <item coord="L" source="Class Format and Activities" target="course-field">Class Format and Activities</item>
        <item coord="M" source="Qualification" target="qualification-type">Qualification</item><!-- FIXME -->
        <item coord="N" source="Location" target="location-place">Location</item>
        <item coord="O" source="Full Fee" target="event-price">Full Fee</item><!-- FIXME -->
        <item coord="P" source="Conc Fee" target="event-price">Conc Fee</item><!-- FIXME -->
        <item coord="Q" source="Snr Fee" target="event-price">Snr Fee</item><!-- FIXME -->
        <item coord="R" source="Currency" target="event-currency">Currency</item><!-- FIXME -->
        <item coord="S" source="Start Date" target="duration-start">Start Date</item><!-- FIXME -->
    </provider>

    <provider xmlns="http://www.sgmlguru/ns/xproc/steps" id="Surrey_Adult_Learning">
        <item coord="A" source="COURSE_REF*" target="">COURSE_REF*</item>
        <item coord="B" source="YOUR_COURSE_CODE" target="course-uniqueIdentifier">YOUR_COURSE_CODE</item>
        <item coord="C" source="TITLE*" target="course-name">TITLE*</item>
        <item coord="D" source="SUMMARY*" target="course-description">SUMMARY*</item>
        <item coord="E" source="QUALIFICATION_CODE" target="">QUALIFICATION_CODE</item>
        <item coord="F" source="QUALIFICATION_TITLE*" target="">QUALIFICATION_TITLE*</item>
        <item coord="G" source="AWARDING_BODY" target="">AWARDING_BODY</item>
        <item coord="H" source="LAD_ID" target="">LAD_ID</item>
        <item coord="I" source="ENTRY_REQUIREMENTS*" target="">ENTRY_REQUIREMENTS*</item>
        <item coord="J" source="AVAILABLE_TO_INTERNATIONAL_STUDENTS?" target="">AVAILABLE_TO_INTERNATIONAL_STUDENTS?</item>
        <item coord="K" source="INTERNATIONAL_ENTRY_REQUIREMENTS" target="">INTERNATIONAL_ENTRY_REQUIREMENTS</item>
        <item coord="L" source="SPECIFIC_TARGET_GROUPS?" target="">SPECIFIC_TARGET_GROUPS?</item>
        <item coord="M" source="LEVEL" target="">LEVEL</item>
        <item coord="N" source="COURSE_URL" target="course-link">COURSE_URL</item>
        <item coord="O" source="COURSE_REF*" target="">COURSE_REF*</item>
        <item coord="P" source="HC_DELIVERY_ID" target="">HC_DELIVERY_ID</item>
        <item coord="Q" source="VENUE_REF" target="">VENUE_REF</item>
        <item coord="R" source="AREA_OF_COVERAGE" target="">AREA_OF_COVERAGE</item>
        <item coord="S" source="DURATION*" target="">DURATION*</item>
        <item coord="T" source="STUDY_MODE_CODE*" target="">STUDY_MODE_CODE*</item>
        <item coord="U" source="START_DATES/MONTHS" target="duration-start">START_DATES/MONTHS</item>
        <item coord="V" source="START_DATE_DESC" target="">START_DATE_DESC</item>
        <item coord="W" source="VIRTUAL HELP/ DAYS OF WEEK" target="">VIRTUAL HELP/ DAYS OF WEEK</item>
        <item coord="X" source="STANDARD_FEES" target="event-price">STANDARD_FEES</item>
        <item coord="Y" source="PROMOTIONAL_FEE" target="event-price">PROMOTIONAL_FEE</item>
        <item coord="Z" source="CONCESSION_FEE" target="event-price">CONCESSION_FEE</item>
        <item coord="AA" source="FEES_DESCRIPTION" target="">FEES_DESCRIPTION</item>
        <item coord="AB" source="PRICE_URL" target="">PRICE_URL</item>
        <item coord="AC" source="INTERNATIONAL_FEES" target="">INTERNATIONAL_FEES</item>
        <item coord="AD" source="INTERNATIONAL_PRICE_PER_YEAR" target="">INTERNATIONAL_PRICE_PER_YEAR</item>
        <item coord="AE" source="INTERNATIONAL_FEE_DESCRIPTION" target="">INTERNATIONAL_FEE_DESCRIPTION</item>
        <item coord="AF" source="URL_FOR_APPLICATION" target="">URL_FOR_APPLICATION</item>
        <item coord="AG" source="" target=""/>
        <item coord="AH" source="" target=""/>
        <item coord="AI" source="" target=""/>
        <item coord="AJ" source="" target=""/>
    </provider>

</providers>

All of this, except //item/@target, is generated by an XSLT from a normalised XML version of the Excel.