Last updated: July 16, 2026
How to get a job's detailed results
This page explains how to get detailed results for a single ShArc job from Azure Log Analytics:
- a per-file list — one row per processed file (Success / Skipped / Error), and
- a per-library report — totals per SharePoint library (files, sizes, versions).
Some of this is already in the ShArc interface:
- Job history (all past jobs, with status, duration and totals) — open ShArc and use the History link.
- Per-library report for the most recent job — open the job's progress page and use the report button; it opens Log Analytics with the report pre-filled.
Use the queries on this page when you want the per-file detail, or the per-library report for an older job that is no longer on the progress page.
Find the Job ID
Both queries need the ID of the job you want to inspect. Open the History link in ShArc — it opens Log Analytics with the list of jobs — and copy the value in the JobId column for the job you're interested in.
Open Log Analytics
- Open your Log Analytics workspace (its name is your ShArc server prefix with
la-in front, e.g.la-contoso-sharc) and select Logs. If the editor is in "Simple mode", switch it to KQL mode.
- Paste one of the queries below and set your Job ID once on the first line — edit
let _jobId = toguid("…");and paste the Job ID between the quotes. Each query already includes a time range (the last ~300 days) and a row cap, so you don't need to set the portal's time range or result limit manually.

- Select Run. (Optional: use Save → Save as query to keep it for next time, and reopen it later from your saved queries.)


Per-file result list
Returns one row per file the job processed, with an EventType of Success, Skipped or Error, the FileId, and the log message (which includes the file path). Works for jobs from before and after the logging update — the FileId column is filled for jobs after the logging update (from ShArcLogs_CL); for older jobs (only in AppServiceConsoleLogs) it is empty and the file path in the message is the identifier.
let _jobId = toguid("00000000-0000-0000-0000-000000000000");
union isfuzzy=true
(ShArcLogs_CL
| where TimeGenerated > ago(300d)
| where JobId == _jobId
| extend Message = LogMessage
| extend FileId = tostring(FileId)),
(AppServiceConsoleLogs
| where TimeGenerated > ago(300d)
| where isnotempty(ResultDescription)
| where ResultDescription contains tostring(_jobId)
| extend Message = ResultDescription
| extend FileId = "")
| where Message has "finished successfully for file"
or Message contains "Skipped file '"
or Message has "finished with error for file"
| extend EventType = case(
Message has "finished successfully for file", "Success",
Message contains "Skipped file '", "Skipped",
"Error")
| project TimeGenerated, EventType, FileId, Message
| order by TimeGenerated asc
| limit 500000
Per-library report
Returns one row per SharePoint library the job processed, with totals: successful files (and the Onload/Offload split), skipped files, transferred size, and retained / removed / restored version counts and sizes.
For the most recent job you can get this with a single click — the report button on the job's progress page. Use the query below for older jobs: copy their Job ID from History (see above) and set it on the first line.
let _jobId = toguid("00000000-0000-0000-0000-000000000000");
let Logs =
union isfuzzy=true
(ShArcLogs_CL
| where TimeGenerated > ago(300d)
| where JobId == _jobId
| extend Msg = LogMessage, LibId = tostring(LibraryId)),
(AppServiceConsoleLogs
| where TimeGenerated > ago(300d)
| where isnotempty(ResultDescription)
| where ResultDescription contains tostring(_jobId)
| extend Msg = ResultDescription, LibId = extract(@"\(\s*LibraryId:\s*([0-9A-Fa-f-]{36})\s*\)", 1, ResultDescription));
(
Logs
| where Msg has "Starting operation processing files in library"
| extend
LibraryTitleRaw = extract(@"(?i)in\s+library\s*'(.+)'\s+with\s+url\s*:", 1, Msg),
LibraryUrl = extract(@"url:\s*'([^']+)'", 1, Msg),
LibrarySiteUrl = extract(@"site:\s*'([^']+)'", 1, Msg),
LibraryId = LibId,
Started = TimeGenerated
| extend LibraryTitle = replace_string(LibraryTitleRaw, "''", "'")
| where isnotempty(LibraryId)
| summarize arg_max(Started, LibraryTitle, LibraryUrl, LibrarySiteUrl) by LibraryId
)
| join kind=leftouter
(
Logs
| where Msg has "Finished Processing library"
| extend LibraryId = LibId
| where isnotempty(LibraryId)
| summarize Ended = max(TimeGenerated) by LibraryId
) on LibraryId
| join kind=leftouter
(
Logs
| where Msg has "Offload finished successfully for file" or Msg has "Onload finished successfully for file"
| extend
IsOnload = Msg has "Onload finished successfully for file",
IsOffload = Msg has "Offload finished successfully for file",
SizeBytes = tolong(extract(@"size\s+'?(\d+)'?", 1, Msg)),
RetainedVersionCount = tolong(extract(@"and\s+'?(\d+)'?\s+retained\s+versions", 1, Msg)),
RetainedVersionSizeBytes = tolong(extract(@"retained\s+versions\s+with\s+size\s+of\s+'?(\d+)'?", 1, Msg)),
RemovedVersionCount = tolong(extract(@"and\s+'?(\d+)'?\s+removed\s+versions", 1, Msg)),
RemovedVersionSizeBytes = tolong(extract(@"removed\s+versions\s+with\s+size\s+of\s+'?(\d+)'?", 1, Msg)),
RestoredVersionCount = tolong(extract(@"and\s+'?(\d+)'?\s+restored\s+versions", 1, Msg)),
RestoredVersionSizeBytes = tolong(extract(@"restored\s+versions\s+with\s+size\s+of\s+'?(\d+)'?", 1, Msg)),
LibraryId = LibId
| where isnotempty(LibraryId) and isnotnull(SizeBytes)
| summarize
SuccessSizeBytes = sum(SizeBytes),
SuccessfulAmount = count(),
SuccessfulOnloadAmount = countif(IsOnload),
SuccessfulOffloadAmount = countif(IsOffload),
OnloadSizeBytes = sumif(SizeBytes, IsOnload),
OffloadSizeBytes = sumif(SizeBytes, IsOffload),
RetainedVersionCount = sum(RetainedVersionCount),
RetainedVersionSizeBytes = sum(RetainedVersionSizeBytes),
RemovedVersionCount = sum(RemovedVersionCount),
RemovedVersionSizeBytes = sum(RemovedVersionSizeBytes),
RestoredVersionCount = sum(RestoredVersionCount),
RestoredVersionSizeBytes = sum(RestoredVersionSizeBytes)
by LibraryId
) on LibraryId
| join kind=leftouter
(
Logs
| where Msg contains "Skipped file '" or Msg has "Onload finished with error for file" or Msg has "Onload simulation finished with error for file"
| extend LibraryId = LibId
| where isnotempty(LibraryId)
| summarize SkippedAmount = count() by LibraryId
) on LibraryId
| extend
Duration = iff(isnull(Started) or isnull(Ended), time(0s), Ended - Started),
SuccessSizeBytes = coalesce(SuccessSizeBytes, 0),
OnloadSizeBytes = coalesce(OnloadSizeBytes, 0),
OffloadSizeBytes = coalesce(OffloadSizeBytes, 0),
SuccessfulAmount = coalesce(SuccessfulAmount, 0),
SuccessfulOnloadAmount = coalesce(SuccessfulOnloadAmount, 0),
SuccessfulOffloadAmount = coalesce(SuccessfulOffloadAmount, 0),
SkippedAmount = coalesce(SkippedAmount, 0),
RetainedVersionCount = coalesce(RetainedVersionCount, 0),
RetainedVersionSizeBytes = coalesce(RetainedVersionSizeBytes, 0),
RemovedVersionCount = coalesce(RemovedVersionCount, 0),
RemovedVersionSizeBytes = coalesce(RemovedVersionSizeBytes, 0),
RestoredVersionCount = coalesce(RestoredVersionCount, 0),
RestoredVersionSizeBytes = coalesce(RestoredVersionSizeBytes, 0),
TotalTransferredBytes = SuccessSizeBytes + RetainedVersionSizeBytes + RestoredVersionSizeBytes + RemovedVersionSizeBytes
| extend
Size = case(
isnull(SuccessSizeBytes) or SuccessSizeBytes == 0, "0 B",
SuccessSizeBytes >= 1099511627776, strcat(tostring(round(SuccessSizeBytes / 1099511627776.0, 2)), " TB"),
SuccessSizeBytes >= 1073741824, strcat(tostring(round(SuccessSizeBytes / 1073741824.0, 2)), " GB"),
SuccessSizeBytes >= 1048576, strcat(tostring(round(SuccessSizeBytes / 1048576.0, 2)), " MB"),
SuccessSizeBytes >= 1024, strcat(tostring(round(SuccessSizeBytes / 1024.0, 2)), " KB"),
strcat(tostring(SuccessSizeBytes), " B")
),
RetainedVersionSize = case(
isnull(RetainedVersionSizeBytes) or RetainedVersionSizeBytes == 0, "0 B",
RetainedVersionSizeBytes >= 1099511627776, strcat(tostring(round(RetainedVersionSizeBytes / 1099511627776.0, 2)), " TB"),
RetainedVersionSizeBytes >= 1073741824, strcat(tostring(round(RetainedVersionSizeBytes / 1073741824.0, 2)), " GB"),
RetainedVersionSizeBytes >= 1048576, strcat(tostring(round(RetainedVersionSizeBytes / 1048576.0, 2)), " MB"),
RetainedVersionSizeBytes >= 1024, strcat(tostring(round(RetainedVersionSizeBytes / 1024.0, 2)), " KB"),
strcat(tostring(RetainedVersionSizeBytes), " B")
),
RestoredVersionSize = case(
isnull(RestoredVersionSizeBytes) or RestoredVersionSizeBytes == 0, "0 B",
RestoredVersionSizeBytes >= 1099511627776, strcat(tostring(round(RestoredVersionSizeBytes / 1099511627776.0, 2)), " TB"),
RestoredVersionSizeBytes >= 1073741824, strcat(tostring(round(RestoredVersionSizeBytes / 1073741824.0, 2)), " GB"),
RestoredVersionSizeBytes >= 1048576, strcat(tostring(round(RestoredVersionSizeBytes / 1048576.0, 2)), " MB"),
RestoredVersionSizeBytes >= 1024, strcat(tostring(round(RestoredVersionSizeBytes / 1024.0, 2)), " KB"),
strcat(tostring(RestoredVersionSizeBytes), " B")
),
RemovedVersionSize = case(
isnull(RemovedVersionSizeBytes) or RemovedVersionSizeBytes == 0, "0 B",
RemovedVersionSizeBytes >= 1099511627776, strcat(tostring(round(RemovedVersionSizeBytes / 1099511627776.0, 2)), " TB"),
RemovedVersionSizeBytes >= 1073741824, strcat(tostring(round(RemovedVersionSizeBytes / 1073741824.0, 2)), " GB"),
RemovedVersionSizeBytes >= 1048576, strcat(tostring(round(RemovedVersionSizeBytes / 1048576.0, 2)), " MB"),
RemovedVersionSizeBytes >= 1024, strcat(tostring(round(RemovedVersionSizeBytes / 1024.0, 2)), " KB"),
strcat(tostring(RemovedVersionSizeBytes), " B")
),
TotalTransferred = case(
isnull(TotalTransferredBytes) or TotalTransferredBytes == 0, "0 B",
TotalTransferredBytes >= 1099511627776, strcat(tostring(round(TotalTransferredBytes / 1099511627776.0, 2)), " TB"),
TotalTransferredBytes >= 1073741824, strcat(tostring(round(TotalTransferredBytes / 1073741824.0, 2)), " GB"),
TotalTransferredBytes >= 1048576, strcat(tostring(round(TotalTransferredBytes / 1048576.0, 2)), " MB"),
TotalTransferredBytes >= 1024, strcat(tostring(round(TotalTransferredBytes / 1024.0, 2)), " KB"),
strcat(tostring(TotalTransferredBytes), " B")
)
| project
Started,
Ended,
Duration,
LibraryTitle,
LibraryUrl,
LibrarySiteUrl,
Size,
TotalTransferred,
SuccessfulAmount,
SuccessfulOnloadAmount,
SuccessfulOffloadAmount,
SkippedAmount,
SuccessSizeBytes,
OnloadSizeBytes,
OffloadSizeBytes,
RetainedVersionCount,
RetainedVersionSize,
RetainedVersionSizeBytes,
RestoredVersionCount,
RestoredVersionSize,
RestoredVersionSizeBytes,
RemovedVersionCount,
RemovedVersionSize,
RemovedVersionSizeBytes
| limit 500000
Tip: this query is long because it computes many totals per library in a single pass — copy the whole block, set your Job ID on the first line, and run.
If the job ran more than about 300 days ago, widen the time range in the query — change
ago(300d)to a longer period (e.g.ago(730d)).
Need the complete logs, not just job results? To pull all log messages (or the verbose blob logs), see the "How to get the logs for support" page.


