Quick Search Add criteria error

Hello everyone!!! I have a very weird issue with quick search in 10.0.700.

there is already a quick search on project entry module, if I run a test in BAQ maintenance I can tell query is working properly.

the quick search criteria is already generated but if I try to edit criterias or adding a new one i get the following error:

Server Side Exception

The table/field is not valid.

Exception caught in: Epicor.ServiceModel

Error Detail 
============
Description:  The table/field is not valid.
Program:  Ice.Services.BO.QuickSearch.dll
Method:  QuickSearchCriteriaBeforeUpdate
Server Trace Stack:     at Ice.Services.BO.QuickSearchSvc.QuickSearchCriteriaBeforeUpdate()
   at Ice.Services.Trace.TablesetProfilingCollector.DoRowEventTrace(String tableName, String methodName, Int32 rowCount, Action action)
   at Ice.TablesetBound`3.CreateRow(IceDataContext dc, Int32 tableNum, IIceTable tbl, IceRow newTablesetRow, TablesetProfilingCollector parentTraceCollector)
   at Ice.TablesetBound`3.WriteTable(IceDataContext context, Int32 tableIndex, IIceTable table, TablesetProfilingCollector parentTraceCollector)
   at Ice.TablesetBound`3.InnerUpdate(IceDataContext context, TFullTableset tableset)
   at Ice.Services.BO.QuickSearchSvc.Update(QuickSearchTableset& ds)
   at Ice.Services.BO.QuickSearchSvcFacade.Update(QuickSearchTableset& ds)
   at SyncInvokeUpdate(Object , Object[] , Object[] )
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
   at Epicor.Hosting.OperationBoundInvoker.Invoke(Object instance, Func`2 func)
   at Epicor.Hosting.Wcf.EpiOperationInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage11(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)
   at System.ServiceModel.Dispatcher.ChannelHandler.DispatchAndReleasePump(RequestContext request, Boolean cleanThread, OperationContext currentOperationContext)
   at System.ServiceModel.Dispatcher.ChannelHandler.HandleRequest(RequestContext request, OperationContext currentOperationContext)
   at System.ServiceModel.Dispatcher.ChannelHandler.AsyncMessagePump(IAsyncResult result)
   at System.ServiceModel.Dispatcher.ChannelHandler.OnAsyncReceiveComplete(IAsyncResult result)
   at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
   at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
   at System.ServiceModel.Channels.SecurityChannelListener`1.ReceiveItemAndVerifySecurityAsyncResult`2.InnerTryReceiveCompletedCallback(IAsyncResult result)
   at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
   at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
   at System.ServiceModel.Channels.TransportDuplexSessionChannel.TryReceiveAsyncResult.OnReceive(IAsyncResult result)
   at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
   at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
   at System.ServiceModel.Channels.SynchronizedMessageSource.ReceiveAsyncResult.OnReceiveComplete(Object state)
   at System.ServiceModel.Channels.SessionConnectionReader.OnAsyncReadComplete(Object state)
   at System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
   at System.Net.LazyAsyncResult.Complete(IntPtr userToken)
   at System.Net.LazyAsyncResult.ProtectedInvokeCallback(Object result, IntPtr userToken)
   at System.Net.Security.NegotiateStream.ProcessFrameBody(Int32 readBytes, Byte[] buffer, Int32 offset, Int32 count, AsyncProtocolRequest asyncRequest)
   at System.Net.Security.NegotiateStream.ReadCallback(AsyncProtocolRequest asyncRequest)
   at System.Net.AsyncProtocolRequest.CompleteRequest(Int32 result)
   at System.Net.FixedSizeReader.CheckCompletionBeforeNextRead(Int32 bytes)
   at System.Net.FixedSizeReader.ReadCallback(IAsyncResult transportResult)
   at System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
   at System.ServiceModel.Channels.ConnectionStream.IOAsyncResult.OnAsyncIOComplete(Object state)
   at System.Net.Sockets.SocketAsyncEventArgs.OnCompleted(SocketAsyncEventArgs e)
   at System.Net.Sockets.SocketAsyncEventArgs.FinishOperationSuccess(SocketError socketError, Int32 bytesTransferred, SocketFlags flags)
   at System.Net.Sockets.SocketAsyncEventArgs.CompletionPortCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
   at System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)



Client Stack Trace 
==================
   at Epicor.ServiceModel.Channels.ImplBase`1.ShouldRethrowNonRetryableException(Exception ex, DataSet[] dataSets)
   at Ice.Proxy.BO.QuickSearchImpl.Update(QuickSearchDataSet ds)
   at Ice.Adapters.QuickSearchAdapter.OnUpdate()
   at Ice.Lib.Framework.EpiBaseAdapter.Update()
   at Ice.UI.App.QuickSearchEntry.QuickSearchTransaction.adapterUpdate()
   at Ice.Lib.Framework.EpiMultiViewTransaction.Update(IEnumerable`1 dataSets)```

![image|389x180](upload://fqjnSWyfKTppL2l03EOQfH86CY1.png)
![image|690x256](upload://mAhRAX5i5Sg7ohm2KffFKFaK8Fs.png)

i decided to create a brand new BAQ, create a brand new quick search, everything runs great until I decide to include in the criteria fields like: Project.Number01, Project.Character01, Project.ShortChar01, etc, etc, etc....

have you ever seen something like this before?? Do you have any ideas or suggestions??

Best Regards..

Would this perhaps be in a lower\test environment that got copied from a higher environment? If so,make sure after the restore you have regen’d\recycled\restarted client

Also those used to be standard generic UDs - later versions they must be manually added.

Hi Chris, thank you for your response…

Actually what I’m afraid is that this was an E9 BAQ converted to E10, the weird thing is that I have an “old” E10 backup and it is working “fine”… this issue seems to be affecting only our production DB.

I’ve ran the regenerate Data Model twice and still not working. If I run the BAQ alone, I’m getting the desired results…

perhaps my query is built incorrectly?

HEG-ProjectSearch.baq (47.8 KB)

I dont imagine there is anything wrong with your query, but just the quick search. You could look in the QuickSearchCriteria table in sql (targeting the quicksearchID) to see if you notice any obvious datatableid\fieldnames that seem invalid.

I wonder if in E9 those extra fields Number01, Char01, etc were on the base table (as opposed to table_ud), if so that could cause this issue.

Hey Chris… nothing weird found… but it is now solved… IDK if it was the most efficient way to do it but it worked for me and was able to finally deliver the requested change.

I manually added the Missing Criteria to the QuickSearchCriteria table… following the structure of the existing ones. After that I went to Project entry, trigger the quick search maintenance, pulled up my quick search and my criterias were there… set that quick search as base and default and it seems to be working as expected.