-
Notifications
You must be signed in to change notification settings - Fork 102
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
Allow changing the iASP from Code for IBM i #941
Comments
Based on this comment: #885 (comment) Try changing your JOBD to set the initial ASP and then restart your connection in Code for IBM i. |
Of course, changing the JOBD does the trick. It's just that sometimes, it's not an option (from my personal experience) and users rely entirely on the product/client configuration. I have to deal with IASPs issues on a...regular basis...so I know where it hurts 😅 It's a very powerful feature but man, supporting it is an ordeal sometimes. Now, since everything in Code for IBM i goes through SSH, you're not left with many options either. But here's an idea: since you already upload and a program (GENCMDXML), you could upload a little command as well that would go like this:
I know it's not ideal, but it might do the trick. My two cents 😉 |
While this is a good idea, I am scared to add this additional dependancy to Code for IBM i (e.g. the additional program which would have to be installed during the connection stage). @chrjorgensen It's likely important you see this idea from @sebjulliand since you're pretty familiar with the ASP stuff going on. I personally would be more interested in changing the user job description automatically when the user changes ASP inside of Code for IBM i, which would then take immediate affect on the commands executed after that. It's the least impactful (in terms of system requirements) Sébastien, please also review these ideas from Christian. It's likely we will need to merge ideas to get this to work correctly. |
Can we get around this if we start to use SQL instead of the CL commands in |
No, sorry - SQL can not get around the iASP issue, it's merely another way for retrieving the same data. It can't see schemas or objects in schemas residing on iASP if the ASP group is not set for the job. One way to overcome the problem is to go with the original idea from @sebjulliand about a program to run the command for the iASP. It should be more refined, of course, with more error detection and forwarding. And by the way, the max length for a CMD *CHAR is 5000 bytes, but a *CMDSTR can be 20000 bytes. 😉 We could also use a SQL stored procedure for this - but the same applies, it must be build on the system. It is however more flexible than a CL program, IMHO. A third solution could be to make use of |
@chrjorgensen you should also know, the program we use to run SQL statements can also accept an ASP name (or number? One of them), so that statements run using that ASP group. |
Based on #2339, we won't allow the user to change the ASP in Code for IBM i, and will inherit it based on the job. Closing this now. |
Describe the bug
Trying to browse a library location on an iASP does not work. After the filter is created, expanding it crashes with CPF3064.
This is due to CL commands (i.e. DSPOBJD) being run in QSHELL where every command runs in a new job...meaning that running SETASPGRP beforehand won't help 😅
Setting the iASP in the connection's settings doesn't help either.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Being able to browse a library on an iASP.
Environment
The text was updated successfully, but these errors were encountered: