I'm not sure what to say, as I haven't run into this.
Can you tell me how to reproduce the problem?
How to get job details which is there in QSYSOPR
-
- Site Admin
- Posts: 872
- Joined: Sun Jul 04, 2021 5:12 am
Re: How to get job details which is there in QSYSOPR
I mean for the jobs which are no longer active in the system just for example let's say we had a production issue 5 days back at that time all job details were there when we did DSPJOB for that job. But after 5 days if someone want to track that job details so the same details can we capture here using this SQL query if yes, then when I pass all the parameters in that SQL query as I mentioned in my previous posts then I am unable to find the desired results in output of my SQL Query's results.
So, what is wrong with my SQL Query here? Or this detail cannot be captured using SQL query at all here in this case?
Thanks...
So, what is wrong with my SQL Query here? Or this detail cannot be captured using SQL query at all here in this case?
Thanks...
-
- Site Admin
- Posts: 872
- Joined: Sun Jul 04, 2021 5:12 am
Re: How to get job details which is there in QSYSOPR
You are just repeating the original question...
I've already told you that I don't know why this is happening.
I've already told you that I don't know why this is happening.
Re: How to get job details which is there in QSYSOPR
Ok, if we do not know why (why SQL query does not display the desired results here) is it happening then at least can we confirm that this is something which can't be captured through SQL query at all (?) so that i should not try capturing these details through SQL query way?
The reason I am asking is that if it is something we can capture through SQL query then I should know what is the correct way (selecting correct library, file, fields names etc. ) to get these desired details here and if it is something which can't be captured through SQL Query at all then I should not try to get these desired details through SQL Query.
Thanks.
The reason I am asking is that if it is something we can capture through SQL query then I should know what is the correct way (selecting correct library, file, fields names etc. ) to get these desired details here and if it is something which can't be captured through SQL Query at all then I should not try to get these desired details through SQL Query.
Thanks.
-
- Site Admin
- Posts: 872
- Joined: Sun Jul 04, 2021 5:12 am
Re: How to get job details which is there in QSYSOPR
It works without problems for me.
Re: How to get job details which is there in QSYSOPR
Ok, I got it.
SELECT *
FROM TABLE(QSYS2.JOB_INFO(
JOB_STATUS_FILTER => '*ALL',
JOB_TYPE_FILTER => '*ALL',
JOB_SUBSYSTEM_FILTER => '*ALL',
JOB_USER_FILTER => '*ALL',
JOB_SUBMITTER_FILTER => '*ALL'
)) X;
is it something we can trim down to filter our records as this takes too much time to run and show results plus when i do
dspfd qsys2/job_info
File JOB_INFO in library QSYS2 not found.
amazing in SQL query it shows the results whereas on doing DSPFD does not , could someone please explain with respect to my queries here?
Thanks..
SELECT *
FROM TABLE(QSYS2.JOB_INFO(
JOB_STATUS_FILTER => '*ALL',
JOB_TYPE_FILTER => '*ALL',
JOB_SUBSYSTEM_FILTER => '*ALL',
JOB_USER_FILTER => '*ALL',
JOB_SUBMITTER_FILTER => '*ALL'
)) X;
is it something we can trim down to filter our records as this takes too much time to run and show results plus when i do
dspfd qsys2/job_info
File JOB_INFO in library QSYS2 not found.
amazing in SQL query it shows the results whereas on doing DSPFD does not , could someone please explain with respect to my queries here?
Thanks..
Re: How to get job details which is there in QSYSOPR
I hope when we say ''it works without problem' then meaning was something with respect to modification of that SQL query posted in my last post :
"SELECT *
FROM TABLE(QSYS2.JOB_INFO(
JOB_STATUS_FILTER => '*ALL',
JOB_TYPE_FILTER => '*ALL',
JOB_SUBSYSTEM_FILTER => '*ALL',
JOB_USER_FILTER => '*ALL',
JOB_SUBMITTER_FILTER => '*ALL'
)) X;
"
I mean by modifying this SQL query only in some way we can get detail of any job, could someone please correct me if my understanding is wrong here? or someone has different opinions here please?
Thanks much...
"SELECT *
FROM TABLE(QSYS2.JOB_INFO(
JOB_STATUS_FILTER => '*ALL',
JOB_TYPE_FILTER => '*ALL',
JOB_SUBSYSTEM_FILTER => '*ALL',
JOB_USER_FILTER => '*ALL',
JOB_SUBMITTER_FILTER => '*ALL'
)) X;
"
I mean by modifying this SQL query only in some way we can get detail of any job, could someone please correct me if my understanding is wrong here? or someone has different opinions here please?
Thanks much...