473,388 Members | 1,375 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

What kind of a code is this?

151 100+
Hi

could someone explain me what kind of a code is this.

Expand|Select|Wrap|Line Numbers
  1. CREATE OR REPLACE PACKAGE BODY APPS.FFP3613_01011951 AS
  2. /*
  3. Code generated by Oracle FastFormula - do not edit. Formula Name:
  4. BG_ABSENCE_DURATION
  5. */
  6. PROCEDURE DD(V IN OUT NOCOPY DATE,I IN NUMBER,D IN DATE) IS
  7. BEGIN IF I=-2 OR I=0 THEN V:=D; END IF; END DD;
  8. PROCEDURE DN(V IN OUT NOCOPY NUMBER,I IN NUMBER,D IN NUMBER) IS
  9. BEGIN IF I=-2 OR I=0 THEN V:=D; END IF; END DN;
  10. PROCEDURE DT(V IN OUT NOCOPY VARCHAR2,I IN NUMBER,D IN VARCHAR2) IS
  11. BEGIN IF I=-2 OR I=0 THEN V:=D; END IF; END DT;
  12. PROCEDURE FORMULA IS
  13.  
  14. L_D FF_WRAPPER_PKG.T_DATE:=FF_WRAPPER_PKG.G_D;
  15. L_T FF_WRAPPER_PKG.T_TEXT:=FF_WRAPPER_PKG.G_T;
  16. L_N FF_WRAPPER_PKG.T_NUMBER:=FF_WRAPPER_PKG.G_N;
  17. L_I FF_WRAPPER_PKG.T_NUMBER:=FF_WRAPPER_PKG.G_I;
  18. L_ERCD NUMBER;
  19. L_ERLN NUMBER;
  20. L_ERMT VARCHAR2(255);
  21. BEGIN
  22. FORMULA(L_D,L_N,L_T,L_I,L_ERLN,L_ERCD,L_ERMT);
  23. FF_WRAPPER_PKG.G_D:=L_D;
  24. FF_WRAPPER_PKG.G_I:=L_I;
  25. FF_WRAPPER_PKG.G_N:=L_N;
  26. FF_WRAPPER_PKG.G_T:=L_T;
  27. FF_WRAPPER_PKG.G_FFERLN:=L_ERLN;
  28. FF_WRAPPER_PKG.G_FFERCD:=L_ERCD;
  29. FF_WRAPPER_PKG.G_FFERMT:=L_ERMT;
  30. END FORMULA;
  31. PROCEDURE FORMULA(D IN OUT NOCOPY FF_WRAPPER_PKG.T_DATE,
  32. N IN OUT NOCOPY FF_WRAPPER_PKG.T_NUMBER,
  33. T IN OUT NOCOPY FF_WRAPPER_PKG.T_TEXT,
  34. I IN OUT NOCOPY FF_WRAPPER_PKG.T_NUMBER,
  35. FFERLN OUT NOCOPY NUMBER,FFERCD IN OUT NOCOPY NUMBER,FFERMT OUT NOCOPY VARCHAR2) IS
  36. BEGIN
  37. FORMULA
  38. (
  39. D(1),
  40. I(3),
  41. D(3),
  42. T(4),
  43. I(6),
  44. T(3),
  45. I(4),
  46. T(1),
  47. I(1),
  48. D(2),
  49. I(5),
  50. T(2),
  51. I(2),
  52. T(5),
  53. I(7),
  54. N(1),
  55. D(4),
  56. I(8),
  57. FFERLN,
  58. FFERCD,
  59. FFERMT
  60. );
  61. END FORMULA;
  62. PROCEDURE FORMULA (
  63. D1 IN OUT NOCOPY DATE,
  64. I3 IN OUT NOCOPY NUMBER,
  65. D3 IN OUT NOCOPY DATE,
  66. T4 IN OUT NOCOPY VARCHAR2,
  67. I6 IN OUT NOCOPY NUMBER,
  68. T3 IN OUT NOCOPY VARCHAR2,
  69. I4 IN OUT NOCOPY NUMBER,
  70. T1 IN OUT NOCOPY VARCHAR2,
  71. I1 IN OUT NOCOPY NUMBER,
  72. D2 IN OUT NOCOPY DATE,
  73. I5 IN OUT NOCOPY NUMBER,
  74. T2 IN OUT NOCOPY VARCHAR2,
  75. I2 IN OUT NOCOPY NUMBER,
  76. T5 IN OUT NOCOPY VARCHAR2,
  77. I7 IN OUT NOCOPY NUMBER,
  78. N1 IN OUT NOCOPY NUMBER,
  79. D4 IN OUT NOCOPY DATE,
  80. I8 IN OUT NOCOPY NUMBER,
  81. FFERLN OUT NOCOPY NUMBER,
  82. FFERCD IN OUT NOCOPY NUMBER,
  83. FFERMT OUT NOCOPY VARCHAR2) IS
  84. /* BG_ABSENCE_DURATION*/
  85. LEMT VARCHAR2(255);
  86. L_ERCD NUMBER(15,0);
  87. L_ PLS_INTEGER;
  88. R_ VARCHAR2(255);
  89. BEGIN
  90. DECLARE
  91. EX1  EXCEPTION;
  92. NULL_FOUND  EXCEPTION;
  93. V0 NUMBER;
  94. V1 NUMBER;
  95. V2 NUMBER;
  96. V3 NUMBER;
  97. V4 NUMBER;
  98. V5 NUMBER;
  99. V6 VARCHAR2(255);
  100. V7 NUMBER;
  101. V8 NUMBER;
  102. V9 NUMBER;
  103. V10 NUMBER;
  104. V11 VARCHAR2(255);
  105. V12 NUMBER;
  106. V13 NUMBER;
  107. V14 NUMBER;
  108. V15 NUMBER;
  109. V16 VARCHAR2(255);
  110. V17 NUMBER;
  111. V18 NUMBER;
  112. V19 NUMBER;
  113. V20 VARCHAR2(255);
  114. V21 VARCHAR2(255);
  115. V22 DATE;
  116. V23 DATE;
  117. V24 VARCHAR2(255);
  118. tv0 VARCHAR2(255);
  119. CURSOR C1 IS
  120. SELECT
  121. hr_general.decode_lookup('SEX',PEOPLE.sex),
  122. 'FF ROUTE:SEH_PER_PERSON_DETAILS_PERF'
  123. FROM 
  124.  per_all_people_f PEOPLE
  125.  , per_person_types PTYPE
  126.  , per_phones PHONE
  127.  , fnd_sessions SES
  128.  , hr_lookups a
  129.  , hr_lookups b
  130.  , hr_lookups c
  131.  , hr_lookups d
  132.  , per_all_assignments_f ASSIGN
  133.  where D3 BETWEEN ASSIGN.effective_start_date
  134.  AND ASSIGN.effective_end_date
  135.  and ASSIGN.assignment_id = N1
  136.  and PEOPLE.person_id = ASSIGN.person_id
  137.  and D3 BETWEEN PEOPLE.effective_start_date
  138.  AND PEOPLE.effective_end_date
  139.  and PTYPE.person_type_id = PEOPLE.person_type_id
  140.  and PHONE.parent_id (+) = PEOPLE.person_id
  141.  AND PHONE.parent_table (+)= 'PER_PEOPLE_F'
  142.  and PHONE.phone_type (+)= 'W1'
  143.  AND D3 BETWEEN NVL(PHONE.date_from(+),D3)
  144.  AND NVL(PHONE.date_to(+),D3)
  145.  and a.lookup_type = 'YES_NO'
  146.  and a.lookup_code = nvl(PEOPLE.current_applicant_flag,'N')
  147.  and a.application_id = 800
  148.  and b.lookup_type = 'YES_NO'
  149.  and b.lookup_code = nvl(PEOPLE.current_npw_flag,'N')
  150.  and b.application_id = 800
  151.  and c.lookup_type = 'YES_NO'
  152.  and c.lookup_code = nvl(PEOPLE.current_employee_flag,'N')
  153.  and c.application_id = 800
  154.  and d.lookup_type = 'REGISTERED_DISABLED'
  155.  and d.lookup_code = nvl(PEOPLE.registered_disabled_flag,'N')
  156.  and d.application_id = 800
  157.  and SES.session_id = USERENV('SESSIONID');
  158. V25 DATE;
  159. V26 DATE;
  160. V27 DATE;
  161. V28 DATE;
  162. V29 NUMBER;
  163. CURSOR C2 IS
  164. SELECT
  165. PGROUP.SEGMENT1,
  166. 'FF ROUTE:KEY_FLEXFIELD_ROUTE'
  167. FROM 
  168.  per_all_assignments_f ASSIGN,
  169.  hr_all_positions_f POS,
  170.  hr_all_positions_f_tl POSTL,
  171.  per_position_definitions POSDEF, 
  172.  per_grades GRA,
  173.  per_grades_tl GRATL,
  174.  per_grade_definitions GRADEF, 
  175.  per_jobs JOB,
  176.  per_jobs_tl JOBTL,
  177.  per_job_definitions JOBDEF, 
  178.  pay_people_groups PGROUP 
  179.  WHERE D3 BETWEEN ASSIGN.effective_start_date
  180.  AND ASSIGN.effective_end_date
  181.  AND D3 BETWEEN POS.effective_start_date(+)
  182.  AND POS.effective_end_date(+)
  183.  AND ASSIGN.assignment_id = N1
  184.  AND POS.position_id (+)= ASSIGN.position_id
  185.  AND POSTL.position_id (+)= ASSIGN.position_id
  186.  AND POSTL.language (+)= userenv('LANG')
  187.  AND POSDEF.position_definition_id (+)= POS.position_definition_id
  188.  AND GRA.grade_id (+)= ASSIGN.grade_id
  189.  AND GRATL.grade_id (+)= ASSIGN.grade_id
  190.  AND GRATL.language (+)= userenv('LANG')
  191.  AND GRADEF.grade_definition_id (+)= GRA.grade_definition_id
  192.  AND JOB.job_id (+)= ASSIGN.job_id
  193.  AND JOBTL.job_id (+)= ASSIGN.job_id
  194.  AND JOBTL.language (+)= userenv('LANG')
  195.  AND JOBDEF.job_definition_id (+)= JOB.job_definition_id
  196.  AND PGROUP.people_group_id (+)= ASSIGN.people_group_id;
  197. dv0 DATE;
  198. CURSOR C0 IS
  199. SELECT
  200. SERVICE.date_start,
  201. 'FF ROUTE:SEH_EMP_PERSON_SERVICE_1'
  202. FROM 
  203.  per_all_assignments_f ASSIGN
  204. , per_periods_of_service SERVICE
  205. where D3 BETWEEN ASSIGN.effective_start_date
  206.  AND ASSIGN.effective_end_date
  207. and ASSIGN.assignment_id = N1
  208. and SERVICE.period_of_Service_id (+)= ASSIGN.period_of_service_id;
  209. V30 DATE;
  210. V31 DATE;
  211. BEGIN
  212. L_ERCD:=0;
  213. LEMT:='OB';
  214. L_:=50;
  215. V0:=5;
  216.  
  217. L_:=51;
  218. V1:=3;
  219.  
  220. L_:=52;
  221. V2:=15;
  222.  
  223. L_:=53;
  224. V3:=5;
  225.  
  226. L_:=82;
  227. LEMT:='TO_DATE';
  228. LEMT:='SUBSTR';
  229. LEMT:='TO_CHAR';
  230. IF I3=0 THEN
  231. D1:=TO_DATE('0001/01/01 00:00:00','FXYYYY/MM/DD HH24:MI:SS');
  232. I3:=-2;
  233. END IF;
  234. V22:=fffunc.td(('01-JAN-' || SUBSTR(fffunc.dc(D1),1,4)));
  235.  
  236. L_:=83;
  237. LEMT:='TO_DATE';
  238. LEMT:='SUBSTR';
  239. LEMT:='TO_CHAR';
  240. V23:=fffunc.td(('31-DEC-' || SUBSTR(fffunc.dc(D1),1,4)));
  241.  
  242. L_:=85;
  243. LEMT:='CBTT_GET_ABSENCE_TYPE';
  244. IF I4=0 THEN
  245. T3:=T3;
  246. LEMT:='ABSENCE_ATTENDANCE_TYPE_ID';
  247. RAISE EX1;
  248. END IF;
  249. V24:=CBTT_UDFS_PKG.CBTT_GET_ABSENCE_TYPE(T3);
  250.  
  251. L_:=103;
  252. IF I5=0 THEN
  253. D2:=TO_DATE('4712/12/31 00:00:00','FXYYYY/MM/DD HH24:MI:SS');
  254. I5:=-2;
  255. END IF;
  256. IF (((I3=-2 ) 
  257. OR (I5=-2 ))) THEN
  258. L_:=89;
  259. T2:='0';
  260.  
  261.  ELSE
  262. L_:=93;
  263. LEMT:='CBTT_GET_GRADE';
  264. V11:=CBTT_UDFS_PKG.CBTT_GET_GRADE(N1,D1);
  265.  
  266. L_:=102;
  267. IF ((V11 = 'Security Staff')) THEN
  268. L_:=97;
  269. LEMT:='TO_CHAR';
  270. LEMT:='DAYS_BETWEEN';
  271.  
  272.  

vamsi
Aug 25 '09 #1
3 3029
OraMaster
135 100+
Please post the complete code, so that expert can comment on it. It's not even compiling. I guess there are some functions which are redundent.
Aug 26 '09 #2
vamsioracle
151 100+
Hi

This is the object code of the fast formulas in oracle apps. I suppose we cannot compile this at the sql prompt.

vamsi
Aug 26 '09 #3
amitpatel66
2,367 Expert 2GB
Basically the code is calculating the number of absence leaves fora a particular employee.

You should be able to easily find out what the code exactly does since you have got the code from the front end HRMS module.
Aug 31 '09 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Joh | last post by:
Hello, (sorry long) i think i have missed something in the code below, i would like to design some kind of detector with python, but i feel totally in a no way now and need some advices to...
125
by: Sarah Tanembaum | last post by:
Beside its an opensource and supported by community, what's the fundamental differences between PostgreSQL and those high-price commercial database (and some are bloated such as Oracle) from...
33
by: Jacob Oost | last post by:
Should I get some more general books, like "advanced self-teaching," or can I start on specialized books like "Linux game programming?" Any book recommendations? -- ----- BEGIN GEEK CODE...
58
by: Larry David | last post by:
Ok, first of all, let's get the obvious stuff out of the way. I'm an idiot. So please indulge me for a moment. Consider it an act of "community service".... What does "64bit" mean to your friendly...
669
by: Xah Lee | last post by:
in March, i posted a essay “What is Expressiveness in a Computer Language”, archived at: http://xahlee.org/perl-python/what_is_expresiveness.html I was informed then that there is a academic...
14
by: teslar91 | last post by:
As a fairly new .NET coder, I would greatly appreciate some comments on any .NET classes that are known to be notoriously slow by comparison to direct API calls. I've already had a bad...
28
by: gnuist006 | last post by:
I have some code like this: (if (test) (exit) (do something)) or (if (test)
11
by: plenty900 | last post by:
I was looking over someone's C++ code today and despite having written perfectly readable C++ code myself, the stuff I was looking at was worse than legalese. The people who are guiding the...
4
by: Gestorm | last post by:
Hi all, I found a macro "USE_VAR" in the code of bash-3.2 as follows: /*file: bash-3.2/shell.c*/ 344 USE_VAR(argc); 345 USE_VAR(argv); 346 USE_VAR(env); 347 USE_VAR(code); 348 ...
66
by: John | last post by:
Hi What are the advantages actually achieved of managed code? I am not talking of theory but in reality. Thanks Regards
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.