Cleaning an XER Before Import
Last reviewed 9 September 20261,653 words8 min read
Duration fractions, orphan records, unused data
๐ฉ In one line: Every received XER carries global baggage โ calendars, resources, codes, UDFs, cost data โ that lands permanently in your database on import. Open it in a sandbox, strip what isn't the project, fix fractional durations and orphan records, then import the clean copy. Twenty minutes now saves a corrupted enterprise database later.
๐ค Who this is for: Mid-level planners who receive files from subcontractors, consultants or other packages; juniors who have been told "clean it first" without being told how; seniors administering a shared database. You should know the XER tables (what-is-an-xer-file).
First, let's be honest about why this page exists
Nobody cleans an XER until they've inherited a database with 41 calendars named "Standard", six copies of every resource, and a UDF called "Comments" that means three different things. By then it's a week's work to untangle.
The habit is simple and the payoff is large: your database stays yours, and the schedule you import behaves the way the sender's did.
๐จ The standard โ what "good" looks like
| Source | What it supports |
|---|---|
| Oracle P6 Professional User Guide โ Import Configuration | Per-data-type control: Keep Existing / Update Existing / Insert New / Do Not Import |
| DCMA 14-Point Assessment | Fractional and unusual durations show up in High Duration (Metric 8) and logic checks; a dirty import creates false failures |
| Client schedule specifications (typical Gulf) | Often require project-scoped calendars and codes; global data in a submission may be non-compliant |
| AACE RP 29R-03 โ source validation | The file analysed must be shown to be the file received; keep the original unedited alongside the cleaned copy |
๐ข Rule to remember: import into a sandbox first, look at what arrived, then decide what enters production. Never clean in the live database.
How it actually works
The three-stage routine.
| Stage | Where | What you do |
|---|---|---|
| 1 โ Inspect | Text editor on a copy | Header version, %E, POBS size, hours/day in CALENDAR, presence of PROJCOST / RSRCRATE / TASKMEMO, number of RSRC and CALENDAR rows |
| 2 โ Sandbox import | Separate standalone database | Create New Project; import everything; run F9; check Schedule Log, layouts below; fix in P6 |
| 3 โ Clean export | From the sandbox | Export to XER; import into production with a restrictive import configuration |
What to strip or convert, and how.
| Item | Problem | Fix in P6 (sandbox) | Fix in text editor (if preferred) |
|---|---|---|---|
| Global calendars | Multiply in production; names collide | Enterprise > Calendars: convert used ones to Project calendars (Copy to Project), reassign activities, delete unused | Change clndr_type from CA_Base to CA_Project and set proj_id โ fiddly; prefer P6 |
| Unused calendars | Bloat | Enterprise > Calendars > filter "Not used" > delete | Delete rows not referenced by any TASK clndr_id |
| Resources | Global; hundreds of duplicates | Import config: Resources = Do Not Import (if you only need dates) or Keep Existing; or delete assignments in sandbox | Delete RSRC, TASKRSRC, RSRCRATE tables |
| Cost data | Commercial disclosure; currency clashes | Delete PROJCOST rows; zero rates in RSRCRATE | Delete PROJCOST, RSRCRATE, ACCOUNT |
| Activity codes | Global-scope codes pollute the enterprise | Convert to Project scope (Enterprise > Activity Codes > Modify > Project) | Set actv_code_type_scope to AS_Project |
| UDFs | Duplicate names, wrong types | Import config: UDFs = Do Not Import unless needed; rename before import | Delete UDFTYPE / UDFVALUE tables |
| Notebook | Private comments | Review TASKMEMO; delete or edit topics | Delete TASKMEMO rows |
| Financial periods | Conflicts with your periods | Import config: Financial Period Data = Do Not Import | Delete FINDATES, TRSRCFIN, TASKFIN |
| POBS | Size | โ | Delete the block |
| Baselines | Not in an XER | Ask for baseline XERs separately and assign after import | โ |
Fractional durations. They come from hours/day mismatches, not from anyone typing 3.75. A 30-hour activity on an 8 h calendar displays 3.75 d.
| Cause | Fix |
|---|---|
| Sender's calendar hours/day differ from your Admin Preferences | Tick Admin Preferences > Time Periods > Use assigned calendar to specify the number of work hours โ display follows each calendar |
| Activity calendar hours/day differ from durations entered (e.g. 8 h calendar, durations imported as 10 h days) | Global Change in sandbox: Remaining Duration = round up to whole days on the correct calendar; record it in the narrative |
| Genuine hour-level shutdown/turnaround planning | Leave them; fractions are legitimate โ set display to hours |
Orphan records. Rows that point at IDs that don't exist. P6 usually drops them silently on import, occasionally fails.
| Orphan | Symptom | Fix |
|---|---|---|
TASKPRED referencing a task_id not in TASK | Missing relationships; open ends after import | Parser check before import; ask sender to re-export |
TASK with wbs_id not in PROJWBS | Activities appear under project root | Reassign WBS in sandbox |
TASK clndr_id not in CALENDAR | Activity takes project default calendar; durations shift | Check Schedule Log; reassign calendar |
| TASKRSRC referencing a missing RSRC | Assignments vanish | Usually harmless if you're not importing resources |
Sandbox checks after import (five minutes). Tools > Schedule > F9 > view log; Enterprise > Calendars (count); Enterprise > Resources (count); Activities layout grouped by calendar; filter Total Float < 0 and Original Duration with a decimal; Check Schedule report if your version has it.
Production import configuration (File > Import > Modify Import Configuration): Calendars = Keep Existing; Resources = Do Not Import or Keep Existing; Activity Codes = Keep Existing; UDFs = Keep Existing; Financial Periods = Do Not Import; Delete = unticked throughout.
๐ฅ Where people go wrong
- Cleaning in production because "it's quicker". One wrong Delete tick and other projects lose calendars. The sandbox is a standalone database on your own machine; it costs nothing.
- Deleting calendars before reassigning activities. P6 moves the activities to the project default calendar. A 5-day 8 h calendar silently becomes 6-day 10 h and the whole path shortens.
- Rounding durations without recording it. You've changed the contractor's programme. Note every Global Change in the review record and keep the original file.
- Stripping resources from a file you'll later need for manhour review. Decide the purpose first. For an EOT review you need dates and logic; for a manpower audit you need TASKRSRC.
- Forgetting Notebook goes both ways. You cleaned the client's file; did you clean your own before it left? Review TASKMEMO on export as well as import.
- Assuming a clean import means a correct schedule. Cleaning removes noise. It doesn't make the logic right โ that's how-to-review-a-schedule.
โ๏ธ When you're challenged
"Why do we need a sandbox? Just import it." "Because everything except the activities is global. If the file carries 30 calendars and 400 resources they're in our database for good. Sandbox first, then only the project comes across."
"You changed our durations." "I didn't change any hours. Your calendar is 9 hours a day and our display was set to 8. Once the display follows the assigned calendar, your 10 days read as 10 days. The record shows the setting change, nothing else."
"Did you remove anything from our submission?" "Cost and rate tables, per our transmittal, and a Notebook topic on internal comments. The original file is archived unedited. Dates, durations, logic, calendars and codes are exactly as received."
"Their file has 3.75-day durations. Reject it?" "Not on that alone. It's an hours-per-day display issue on our side. If the fractions survive with the display set to the assigned calendar, then it's a comment."
๐ Related pages
- What Is an XER File โ the tables named here
- XER File Won't Import โ when the file fails before you can clean it
- Importing and Exporting XER โ import configuration options in detail
- Hours per day and duration display โ the fractional-duration mechanics
- P6 Global vs Project Data โ why calendars, resources and codes leak
- Subcontractor and Interface Integration โ what to do with the file once it's clean
- P6 database corruption signs โ what an uncleaned habit eventually causes
โ๏ธ Worked example
An MEP subcontractor's programme for a hospital in Doha, received for integration into the main contractor's schedule.
| Inspection finding | Count / value | Action taken |
|---|---|---|
| Header version | 20.12 (we run 21.12) | None |
| CALENDAR rows | 23 global, 3 actually used | Copied 3 to project scope; reassigned; deleted 20 |
| Used calendar hours/day | 9 | Ticked Use assigned calendar; 3.75 d fractions disappeared |
| RSRC rows | 312 | Resources = Do Not Import (dates and logic review only) |
| PROJCOST / RSRCRATE | Present, QAR rates | Deleted from sandbox before export |
| TASKMEMO | 41 notes; 2 internal | Deleted 2 topics; recorded in review file |
| TASKPRED orphans | 6 rows pointing at missing tasks | Reported to subcontractor; re-export requested |
| Activity codes | 4 global-scope types | Converted to Project scope |
| Result after F9 | 1,860 activities, 0 fractional durations, 2 open ends (both reported) | Imported to production under EPS node "Subcontractors" |
Clean import: 25 minutes. Time saved untangling later: not measurable, which is the point.
๐ References
- Oracle, P6 Professional User Guide โ Import Configuration; Calendars; Admin Preferences, Time Periods
- Oracle, P6 XER Import/Export Data Map Guide
- DCMA 14-Point Assessment, Metric 8 (High Duration)
- AACE RP 29R-03, Forensic Schedule Analysis โ source validation
From the field
Experience from working planners. Unreviewed โ read it as experience, not guidance.
Add what you know about cleaning an xer before import. What worked, what the consultant pushed back on, what you would do differently next time. A paragraph is plenty.
Contributors get their name and one link on the site โ your own templates, course or consultancy. We take nothing and hold nothing.
Add your experience