Who's Online
1 registered (SBi), 1 Guest and 2 Spiders online.
Key: Admin, Global Mod, Mod
Recent Posts
Attach documents in the SIT/EIT
by SBi
Today at 09:31 AM
How managers initiates SSHR request of employees
by Saqib Rahat
Today at 04:29 AM
French Localizations
by jmoyano
03/09/10 09:20 AM
FYI: P60s to be available in Self Service
by kp_rapolu
01/09/10 03:42 PM
SSHR Personalization requirement
by kp_rapolu
01/09/10 03:41 PM
Request for responsibility in ESS
by SBi
01/09/10 05:49 AM
Nominate for peers/subordinat for reward
by bcooper
31/08/10 07:46 PM
UK HCM Sig - 29th September
by andy.fisher
31/08/10 10:05 AM
Migration of terminated Employees
by SBi
31/08/10 10:02 AM
Worldwide Bank Details Validation
by SBi
27/08/10 02:33 PM
Top Posters (30 Days)
SBi 29
bcooper 14
CT 12
PeterP 10
Geoff Dixon 8
Saqib Rahat 8
EBS_USER 6
kp_rapolu 5
delboy 5
MarinaH 3
(Views)Popular Topics
Family Pack K issues thread 8784
CREATE_GRADE api returns:PLS-00306: wrong number o 6108
Still trying to locate... 4621
Creating hr jobs ORA-20001: HR_289477_JOB_GROUP_ID 4401
Review of my Release 12 laptop 4221
Log-on problems for existing users 3530
Viewing Output of another user 3238
Family Pack K 3105
October UK-OUG? 3074
uploading bank branches to PAYROLL 2895
Topic Options
Rate This Topic
#3910 - 16/01/09 10:15 AM Searching Fast formula Text
kp_rapolu Offline
claiming squatters rights

Registered: 15/11/07
Posts: 208
Loc: U.K
Hi,

I am looking for qry to find the list of fast formulas having a certain text in the formula code.

Ex:- List of formulas text contains an string "GB_RATES_HISTORY"

Can anyone help me to get the qry for this.

thanks in advance

KP/..
_________________________
Krishna Prasad Rapolu
Oracle HRMS Consultant

Top
#3911 - 16/01/09 10:29 AM Re: Searching Fast formula Text [Re: kp_rapolu]
CT Offline
veteran
***

Registered: 11/03/05
Posts: 816
Loc: Back at Fort Apache, Gosport!
The problem you have of course is that the formula_text is a LONG column, which does not support any functions applied to it such as LIKE...

One suggestion might be to extract the text from all the formulas into, say, a spreadsheet, then do a string search within the spreadsheet.

Alternatively, you could possibly create your own table like FF_FORMULAS_F except the formula_text column should be CLOB. CLOB columns can have things such as LIKE applied to them in WHERE CLAUSES - then just copy the data from FF_FORMULAS_F into your version, and do the query there.

Alternatively, I seem to remember having in my possession a function that converts LONG to VARCHAR, I need to try and resurrect it from wherever I have hidden it.

_________________________
L&K
CT

Top
#3912 - 16/01/09 10:46 AM Re: Searching Fast formula Text [Re: CT]
bcooper Offline
veteran
*****

Registered: 11/03/05
Posts: 944
Loc: Earth, Europe, England, here
Providing your ARRAYSIZE and MAXDATA settings are correct you should be able to simply select the contents of a LONG straight into a CLOB without any issues.

You can then manipulate the CLOB with any of the string functions as if it were a VARCHAR2
_________________________
I'm blogging again - albeit sporadically
Also my random musings courtesy of Twitter

Top
#3917 - 16/01/09 11:48 AM Re: Searching Fast formula Text [Re: bcooper]
kp_rapolu Offline
claiming squatters rights

Registered: 15/11/07
Posts: 208
Loc: U.K
Hi Clive,

thanks for advice, I have got it now.
Here is the steps -

Step1:

create table xx_test_formulas(formula_name varchar2(1000),formula_text CLOB)

Step2:

insert into xx_test_formulas
select formula_name,to_lob(formula_text)
from ff_formulas_f
where sysdate between effective_start_date and effective_end_date;

Step3:

select *
from xx_test_formulas
where formula_text like '%rate_history%'


cheers
KP/..
_________________________
Krishna Prasad Rapolu
Oracle HRMS Consultant

Top
#3919 - 16/01/09 12:33 PM Re: Searching Fast formula Text [Re: kp_rapolu]
SBi Online   crying
claiming squatters rights

Registered: 23/05/08
Posts: 289
Loc: UK
Thanks a lot all of you..
I was looking for a solution but was caught up with something else..


Top
#3920 - 16/01/09 12:33 PM Re: Searching Fast formula Text [Re: kp_rapolu]
CT Offline
veteran
***

Registered: 11/03/05
Posts: 816
Loc: Back at Fort Apache, Gosport!
Cool!

OK I took the bait on my third alternative, which was to rustle up the function - I've done some rudimentary testing (the only kind I know, as anyone who knows me will tell you!) on my R12 instance, and I picked up 2 results:

Formula UK_PRORATION_GRADE_RATE, eff date 01/01/1901 contains the string GB_RATES_HISTORY
Formula UK_PRORATION_SPINAL_POINT, eff date 01/01/1901 contains the string GB_RATES_HISTORY

The scripts that I used are attached - one is the package header/body, the other is the script that makes use of the package function.

Usual disclaimers apply, unless you want to pay me to support it!


Attachments
search_ff_text.zip (43 downloads)



Edited by CT (16/01/09 12:40 PM)
_________________________
L&K
CT

Top
#3923 - 16/01/09 01:22 PM Re: Searching Fast formula Text [Re: CT]
kp_rapolu Offline
claiming squatters rights

Registered: 15/11/07
Posts: 208
Loc: U.K
thanks for Script
_________________________
Krishna Prasad Rapolu
Oracle HRMS Consultant

Top


Moderator:  bcooper, CT 
Oracle R12.1.1 on your existing computer
Get up and running with Oracle on your existing computer in 5 minutes

Get up and running with Oracle on your existing computer in 5 minutes!

Alard Consulting Ltd are pleased to offer Oracle R12.1.1 on your existing computer.

Connect to Oracle R12 from your computer to do client demonstrations, your own development work, or test functional setup on a Vision environment without having to install and maintain Oracle.

Backup your work before making changes in case things go wrong. Just copy the files to a new directory before making the changes. If it doesn't work, copy the files back again, all from Windows. No other skills needed.

As everything is contained on a single external hard drive, you can take it with you to use wherever you need it.

For each sale from HCMAces a portion of the price will go to the running costs of this forum.

For more information see www.alard.net/products.html.

Forum Stats
492 Members
48 Forums
1208 Topics
5712 Posts

Max Online: 51 @ 12/08/10 02:30 AM
Today's Birthdays
whi5tler (34)
Recent vacancies
Top Posters
bcooper 944
CT 816
Geoff Dixon 354
delboy 291
SBi 289
vkumar 223
kp_rapolu 208
cbrookes 197
Gavin Harris 111
jmoyano 96
September
Su M Tu W Th F Sa
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30