Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mapepire component backend #2256

Open
4 of 8 tasks
worksofliam opened this issue Sep 13, 2024 · 1 comment
Open
4 of 8 tasks

Mapepire component backend #2256

worksofliam opened this issue Sep 13, 2024 · 1 comment

Comments

@worksofliam
Copy link
Contributor

worksofliam commented Sep 13, 2024

@worksofliam
Copy link
Contributor Author

Bad news about qcmdexc. It works fine if the command executes successfully:

call liama.sql_system('CRTBNDRPG PGM(*CURLIB/OCEAN) SRCFILE(LIAMA/QRPGLESRC) OPTION(*EVENTF) DBGVIEW(*SOURCE) TGTRLS(*CURRENT)', 'SAMPLE');

But, if the command you execute has a return code of more than 0, no spool is written and therefore we can't capture it with SQL like we can with the system command:

call qsys2.qcmdexc('CRTBNDRPG PGM(*CURLIB/OCAN) SRCFILE(LIAMA/QRPGLESRC) OPTION(*EVENTF) DBGVIEW(*SOURCE) TGTRLS(*CURRENT)');

 select char(job_number) || '/' || job_user || '/' || job_name, spooled_file_name, spooled_file_number 
  from table(qsys2.spooled_file_info()) x order by creation_timestamp desc limit 20;

Maybe we still leave the compiles and library list stuff to QSH?

@worksofliam worksofliam linked a pull request Sep 13, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant