Jump to content

Execute Stored with insert


gabrie1a2001

Recommended Posts

Hi, good morning:



I need your help in the following, I’m using Jasper Soft Studio 6.2.0 and PLSQL and I execute the following store procedure:



{call SISINFO.dbo.SP_EJECUTA_BASE_PORTABILIDAD ($P{FechaInicio}, $P{FechaFin})}



Inside this store procedure I also execute the following instructions:



ALTER PROCEDURE [dbo].[sP_EJECUTA_BASE_PORTABILIDAD]



@FechaInicio AS DATE,@FechaFin AS DATE



AS



BEGIN



    SET NOCOUNT ON;



 insert into VAGUIAR..TABLA_SOL_JOBS (REPORTE)  values ('PRUEBA')



 select MAX(JOB_ID) AS JOB FROM VAGUIAR..TABLA_SOL_JOBS



END



GO



When I do this in my PC all runs perfectly, but when I publish it on the Jasper Server, even though it doesn’t sent me any errors, the server sends me the max JOB_ID(example: 54), but when I access the table It just have until JOB_ID: 53



If I run it again in my PC, now it gives me back a JOB_ID: 55, and If I access the table it shows the records 53 and 55, I mean the JOB_ID that the server showed didn’t got inserted but it got processed. I don’t know why this is happening.



May someone help me please. Thank you very much for your help.


Link to comment
Share on other sites

  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...