OnDemand Users Group

Support Forums => Windows Client => Topic started by: DDP021 on January 20, 2015, 03:59:28 PM

Title: Application Group changes to query restrictions
Post by: DDP021 on January 20, 2015, 03:59:28 PM
Not sure I'm on the right forum for this question...In any event, we are currently running CMOD 8.5.0...On two of our Application Groups we need to make changes on the PERMISSIONS...Currently we have "Query Restrictions" defined on numerous ids (almost 1000)...We need to make changes to these query restrictions on all of these ids...Currently, the only method we know of is via the CMOD ADMIN client and manually going into the Application Group, highlighting each id (one at a time) and then going under the Query Restriction and clicking EDIT and manually making the change...As you can imagine, this is quite tedious and time consuming with so many ids...Does anyone know of a way to make these kind of changes without doing them in the method I described????...Not sure where in the database these query restrictions are found...Basically if they can be located, we need to replace one word with another...Any help would be greatly appreciated!!!!
Title: Re: Application Group changes to query restrictions
Post by: jeffs42885 on January 20, 2015, 07:17:29 PM
I had to do something like this one that I scripted against the CMOD Database which I DO NOT BELIEVE IS SUPPORTED

I would go in to the object, and then query the object, and see which database field changed. For example, with loading/logging in an application group query before/after the system log..I would make the changes, and see which field it would impact, and go from there. It might not be as plain as day but say property X = yes, property Y = YES, property N = NO, might set the value to lets say 5...but making changes might set it to 8,3,7,1, etc..

Catch my drift?
Title: Re: Application Group changes to query restrictions
Post by: Ed_Arnold on January 22, 2015, 03:48:34 PM
This is not my strong area but I think ARSXML UPDATE function will help?

Ed
Title: Re: Application Group changes to query restrictions
Post by: Justin Derrick on January 23, 2015, 11:30:27 AM
Can you give us an example of how the Query Restriction looks today, and what you'd do to alter it? The only snag is going to be that you'll be doing regular expressions on what is essentially a programming language (SQL) so it's going to be tricky.  Which languages can you write the code in?  (Please say "Perl"!   ;D)

-JD.
Title: Re: Application Group changes to query restrictions
Post by: Greg Ira on January 23, 2015, 02:47:07 PM
FYI.  Query restrictions are located in the ARSAGPERMS table.  I would imagine a carefully crafted SPUFI update would do what you need.
Title: Re: Application Group changes to query restrictions
Post by: Justin Derrick on January 23, 2015, 07:55:10 PM
Quote from: Greg Ira on January 23, 2015, 02:47:07 PM
FYI.  Query restrictions are located in the ARSAGPERMS table.  I would imagine a carefully crafted SPUFI update would do what you need.

Uh...  SPUFI?  What's that?

-JD.
Title: Re: Application Group changes to query restrictions
Post by: Greg Ira on January 26, 2015, 01:01:57 PM
Oops, sorry, long time DB2 user .  SPUFI (SQL Processor Using File Input).   Should have said SQL update. Guilty of typing without thinking. :D
Title: Re: Application Group changes to query restrictions
Post by: DDP021 on January 27, 2015, 12:16:26 PM
Here's an example of a query restriction as it stand today:

((REPORT_NAME like 'GSC1CUST%' and Index_1 in ('LEG', 'LGP')))   

In this case the 'GSC1CUST%' and Index_1' would need to be replaced with, 'BDCGMCUS% and CUST' on EVERY user id associated with this Application Group..
Title: Re: Application Group changes to query restrictions
Post by: Alessandro Perucchi on March 19, 2015, 03:07:43 PM
Well my advice is the following.


Or like some people said to update directly the table ARSAGFLDPERMS.... but this is a not supported way to change the Query Restriction (even if it works :-D)!!
The ID of the table is either the group (GID) or the user (UID).
Title: Re: Application Group changes to query restrictions
Post by: DDP021 on March 25, 2015, 02:22:57 PM
Thanks for the info!!!...We will pass this info to our systems group who will be performing the changes!!!

Take care!!