I One stored procedure. I tried to get this values in temporary tabe. But i am getting below error message.
ERROR:
Msg 8164, Level 16, State 1, Procedure spLocal_MES_UnitOEE, Line 200
An INSERT EXEC statement cannot be nested.
This is my SQL statement.
Declare @tempJanMonth_OEE table(CurrentStatusIcon int, UnitName Varchar(20), ProductionAmount float, AmountEngineeringUnits varchar(20), ActualSpeed float, IdealProductionAmount float, IdealSpeed float,
SpeedEngineeringUnits varchar(50), PerformanceRate float, WasteAmount int, QualityRate int, PerformanceTime varchar(20), RunTime varchar(20), LoadingTime varchar(20), AvailableRate float, PercentOEE float, HighAlarmCount int,
MediumAlarmCount int, LowAlarmCount int, UnitId varchar(200), CategoryID int, Production_Variable varchar(100), SummaryRow int);
Insert into @tempJanMonth_OEE
Exec spLocal_MES_UnitOEE '14;15;16;3;7;9;4;5;24;25;','2017-05-14 07:00:00 AM','2017-05-15 07:00:00 AM',1,NULL,1,NULL
Select * from @tempJanMonth_OEE
Can you please help to solve this issue.