# Container exited unexpectedly with code 0x40010004.  power query in excel



## bbrimberry (Sep 26, 2018)

Hello I am new to power query



I have a dataset of about about 500 rows of fedex tracking data. Sometimes the query works fine. sometimes I have the error below.

To be clear I am using power query in excel not power BI. When it does error it loads around 400 records and then throws this error.

any help is appreciated 


Feedback Type:Frown (Error)


Error Message:
Container exited unexpectedly with code 0x40010004.
Used features: (none).


Stack Trace:


Server stack trace: 
   at Microsoft.Mashup.Evaluator.ErrorTranslatingMessenger.MessageChannel.Read()
   at Microsoft.Mashup.Evaluator.ChannelMessenger.Read(MessageChannel channel)
   at Microsoft.Mashup.Evaluator.ChannelMessenger.MessageChannel.Read()
   at Microsoft.Mashup.Evaluator.Interface.IMessageChannelExtensions.WaitFor[T](IMessageChannel channel)
   at Microsoft.Mashup.Evaluator.MessageBasedInputStream.ReadNextChunkAndCheckIfClosed()
   at Microsoft.Mashup.Evaluator.MessageBasedInputStream.ReadNextChunk()
   at Microsoft.Mashup.Common.ChunkedInputStream.Read(Byte[] buffer, Int32 offset, Int32 count)
   at Microsoft.OleDb.Serialization.PageReader.Read(Byte[] buffer, Int32 offset, Int32 count)
   at Microsoft.OleDb.Serialization.PageReader.ReadChars(Int32 count)
   at Microsoft.OleDb.Serialization.PageReader.ReadArray(String[] values, Int32 offset, Int32 count)
   at Microsoft.OleDb.StringColumn.Deserialize(PageReader reader)
   at Microsoft.OleDb.NullableColumn.Deserialize(PageReader reader)
   at Microsoft.OleDb.Serialization.ColumnsPage.Deserialize(PageReader reader)
   at Microsoft.OleDb.Serialization.OleDbPageReader.Read(ColumnsPage page)
   at Microsoft.OleDb.Serialization.OleDbPageReader.Read(IPage page)
   at Microsoft.Mashup.Common.DelegatingPageReader.Read(IPage page)
   at Microsoft.Mashup.Engine.Interface.Tracing.TracingPageReader.Read(IPage page)
   at Microsoft.Mashup.OleDbProvider.DataHost.BufferingMashupEvaluator.BufferingMashupEvaluation.SerializeResult(IDataReaderSource dataReaderSource, Stream stream)
   at Microsoft.Mashup.OleDbProvider.DataHost.BufferingMashupEvaluator.BufferingMashupEvaluation.GetBufferedReaderSource(AsyncResult`1 result)
   at Microsoft.Mashup.OleDbProvider.DataHost.BufferingMashupEvaluator.BufferingMashupEvaluation.OnEvaluationComplete(AsyncResult`1 result)


Exception rethrown at [0]: 
   at Microsoft.OleDb.AsyncResult`1.get_Value()
   at Microsoft.Mashup.OleDbProvider.MashupRowset.get__Rowset()
   at Microsoft.Mashup.OleDbProvider.MashupRowset.get_ColumnsInfo()
   at Microsoft.OleDb.Rowset.Microsoft.OleDb.IColumnsInfo.GetColumnInfo(DBORDINAL& countColumnInfos, DBCOLUMNINFO*& nativeColumnInfos, Char*& nativeStrings)
   at Microsoft.Mashup.OleDbProvider.TracingRowset.Microsoft.OleDb.IColumnsInfo.GetColumnInfo(DBORDINAL& countColumnInfos, DBCOLUMNINFO*& nativeColumnInfos, Char*& nativeStrings)


Stack Trace Message:
Container exited unexpectedly with code 0x40010004.
Used features: (none).


Invocation Stack Trace:
   at Microsoft.Mashup.Host.Document.ExceptionExtensions.GetCurrentInvocationStackTrace()
   at Microsoft.Mashup.Client.UI.Shared.StackTraceInfo..ctor(String exceptionStackTrace, String invocationStackTrace, String exceptionMessage)
   at Microsoft.Mashup.Client.UI.Shared.FeedbackErrorInfo..ctor(String message, Exception exception, Nullable`1 stackTraceInfo)
   at Microsoft.Mashup.Client.Excel.Native.NativeUserFeedbackServices.ReportException(IWindowHandle activeWindow, IUIHost uiHost, FeedbackPackageInfo feedbackPackageInfo, Exception e, Boolean useGDICapture)
   at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.<>c__DisplayClass1.<HandleException>b__0()
   at Microsoft.Mashup.Host.Document.SynchronizationContextExtensions.SendAndMarshalExceptions(SynchronizationContext context, Action callback)
   at Microsoft.Mashup.Client.UI.Shared.UnexpectedExceptionHandler.HandleException(Exception e)
   at Microsoft.Mashup.Client.Excel.OleDbProvider.ExcelMashupClassFactory.TraceAndReportException(String method, Exception exception)
   at Microsoft.Mashup.OleDbProvider.TracingRowset.Microsoft.OleDb.IColumnsInfo.GetColumnInfo(DBORDINAL& countColumnInfos, DBCOLUMNINFO*& nativeColumnInfos, Char*& nativeStrings)




Supports Premium Content:
True


Formulas:




section Section1;


shared fxtrack = (MyURL)=>


let
    Source = Web.Page(Web.Contents(MyURL)),
    Data0 = Source{0}[Data],
    #"Changed Type" = Table.TransformColumnTypes(Data0,{{"Date/Time", type datetime}, {"Activity", type text}, {"Location", type text}, {"Details", type text}}),
    #"Kept First Rows" = Table.FirstN(#"Changed Type",1)
in
    #"Kept First Rows";


shared trackme = let
    Source = Excel.CurrentWorkbook(){[Name="trackme"]}[Content],
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Group Name", type text}, {"Channel/CC", type text}, {"Employee Name", type text}, {"Email", type text}, {"RCM", type text}, {"Supervisor", type text}, {"Second Supervisor", type text}, {"Outbound Tracking Number", type text}, {"URL", type text}}),
    #"Added Custom" = Table.AddColumn(#"Changed Type", "Fedex", each fxtrack()),
    #"Removed Errors" = Table.R...e", type datetime}})
in
    #"Changed Type1";


----------

