Customize srchfor to get invoked in desired mode



IBM's Command List programming language & Restructured Extended Executor

Customize srchfor to get invoked in desired mode

Postby shivanshu26shiv » Sun May 01, 2016 11:31 pm

Hi All,

Usually whenever we do srchfor, it will search for all the lisitings (pds members/ds-list in 3.4) provided,
which spikes cpu if the count is in 10,000s (or even more). Hence I was thinking to customize srchfor such that a srchfor-job is
submitted in case user does srchfor and number of lines to be searched are > 5000 (or any desired count).

Any suggestions, on how we can customize srchfor to get invoked in batch mode rather in foreground, if line count exceed 5k.?

As an alternative, a rexx can be created to achieve the purpose stated, but it will not show results as srchfor does in a user friendly way, rather it would write in SRCHDSL.LIST,
that's why I went for customization.

Regards,
shivanshu26shiv
 
Posts: 33
Joined: Mon Jun 01, 2015 8:45 pm
Has thanked: 4 times
Been thanked: 0 time

Re: Customize srchfor to get invoked in desired mode

Postby Akatsukami » Mon May 02, 2016 12:45 am

You understand that customizing SRCHFOR means customizing it for everyone, that you are unlikely to be able to do this unless you are a sysprog, and trying and failing (or worse, succeeding) without authorization is likely to lead to a unpleasant interaction with site security?
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: Customize srchfor to get invoked in desired mode

Postby shivanshu26shiv » Mon May 02, 2016 1:34 am

Ohk, got it...
Then I will go for the user friendly rexx alternative for srchfor, since that can lead me to solution of the problem stated...thanks for reply.
shivanshu26shiv
 
Posts: 33
Joined: Mon Jun 01, 2015 8:45 pm
Has thanked: 4 times
Been thanked: 0 time

Re: Customize srchfor to get invoked in desired mode

Postby enrico-sorichetti » Mon May 02, 2016 2:58 am

good luck :mrgreen:
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: Customize srchfor to get invoked in desired mode

Postby Pedro » Mon May 02, 2016 9:31 pm

which spikes cpu if the count is in 10,000s (or even more).

I am not sure what you mean... searching through many objects will still spike the CPU. I do not see that being lessened because it is running in batch. That is, it should do the same amount of work regardless of online or in batch. Perhaps you mean that you can shift the burden to off-shift hours, where it is of less concern.
Pedro Vera
User avatar
Pedro
 
Posts: 684
Joined: Thu Jul 31, 2008 9:59 pm
Location: Silicon Valley
Has thanked: 0 time
Been thanked: 53 times

Re: Customize srchfor to get invoked in desired mode

Postby shivanshu26shiv » Mon May 02, 2016 9:42 pm

Hi Pedro, it seems as per our installation...params like CLASS etc for foreground mode are superior to that in the batch mode, thats why,
shivanshu26shiv
 
Posts: 33
Joined: Mon Jun 01, 2015 8:45 pm
Has thanked: 4 times
Been thanked: 0 time


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post