[Problem Summary]
when GetDataByLocationV200806 SP is executed with the fields source units ,Destination units and units below error comes.
EXEC @return_value = [dbo].[GetDataByLocationV200806]
@module = N'Inventory',
@location = 'EnterpriseFolder.SiteFolder.Pit.Pit',
--@samplePeriod = NULL,
--@startDateLocalTime = NULL,
--@endDateLocalTime = NULL,
@viewName = 'Movement Events',
@fields ='[Source Lot],[Source Lot Group],[Sample Period],[Movement Type],[Destination Units]',
--@modelFields = NULL,
---@filters = NULL,
--@inclusiveDataRange = NULL,
--@session = NULL,
@username = 'Administrator',
@password = 'a',
@serverName = 'http://localhost:8889/'
---@resolveIdentifiers = NULL,
--@pivotResults = NULL,
--@language = NULL
SELECT 'Return Value' = @return_value
GO
Error details:
Msg 6522, Level 16, State 1, Procedure GetDataByLocationV200806, Line 0 [Batch Start Line 18]
A .NET Framework error occurred during execution of user-defined routine or aggregate "GetDataByLocationV200806":
System.Web.Services.Protocols.SoapException: The multi-part identifier "DestinationMaterial.Units" could not be bound.
System.Web.Services.Protocols.SoapException:
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
at Citect.Ampla.Public.MSSQL.Data.V200806.DataWebServiceV200806.DataWebService.GetData(GetDataRequest GetDataRequest)
at Citect.Ampla.Public.MSSQL.Data.V200806.DataStoredProcedure.GetDataByLocationV200806(String module, String location, String samplePeriod, DateTime startDateLocalTime, DateTime endDateLocalTime, String viewName, String fields, String modelFields, String filters, Int32 inclusiveDataRange, String session, String username, String password, String serverName, Boolean resolveIdentifiers, Boolean pivotResults, String language)
[Reproduced in-house (Sydney GSC)] Yes
[Steps to Reproduce]
Please check the provided SP.
[Possible Cause]Bug
[What is the impact to Customer/s]Customer is not able to execute the SP with adding these fields for the fields parameter.
[Workaround] N/A
[Checklist] N/A
Units can be returned by the stored procedure; the material needs to be included in the request as well for this to work.
E.g.
EXEC [dbo].[GetDataByLocationV200806]
@module = N'Inventory',
@location = 'ACME with children',
--@samplePeriod = NULL,
--@startDateLocalTime = NULL,
--@endDateLocalTime = NULL,
@viewName = 'Movement Events',
@fields ='[Source Lot],[Source Lot Group],[Sample Period],[Movement Type],[Destination Material],[Destination Units]',
--@modelFields = NULL,
---@filters = NULL,
--@inclusiveDataRange = NULL,
--@session = NULL,
@serverName = 'http://localhost:8889/'
---@resolveIdentifiers = NULL,
--@pivotResults = NULL,
--@language = NULL
GO