You are on page 1of 8

.

In R12 we can access multiple operating units in single responsibility but in 11i we
can access single responsibility fro single operating unit.
2.In R12 to set org id
mo_gloal.set_policy_context(org_identifier,org_id)
in 11i
fnd_client-info.set_org_context(org_id)
.In R12 ,In!entory "a!e two types
process manufacturing and discreate manufacturing
but 11i
only li#e single module li#e in!entoy.
$.In R12,called suppliers
but in 11i, called !endors.
%.In R12, and In 11i
&p_suppliers, 'o_!endors,
&p_supplier_sites, 'o_!endor_sites-all,
&p_supplier_contacts 'o_!endor_contacts_all.
(.In R12, called )edgers
but in 11i, called set_of_boo#s.
*.In +,&(+rade ,ommunity &rc")
In R12,
Relation s"ip between suppliers,customers,ban# details
but in 11I
only relatoin between customers.
-.In R12, .eneral )edger "a!e $c/s(extra sub_ledger)
but in 11i "a!e c/s.
0.In R12
&p_in!oice_lines_all table i t"ere
but 11i
t"ere is no table.
11.In R12 "a!e 23&,(2ulti 3rg &ccess ,ontrol)
In 11i t"ere is no 23&,.
Creating Parameters for Report
IV Creating Parameters for Report
About parameters
& parameter is a !ariable w"ose !alue can be set at runtime (for example, from t"e Runtime
'arameter 4orm or t"e command line). 'arameters are especially useful for modifying 56)6,+
statements and setting ')758) !ariables at runtime.
Reports 9uilder automatically creates a set of system parameters at runtime, but we can
create our own as well. :e can create parameters to replace eit"er single literal !alues or
entire expressions in any part of a ;uery. :e can reference parameters elsew"ere in t"e
report, suc" as in ')758) constructs pro!iding conditional logic for t"e report.
<ote= :"ile you can delete or rename a user parameter, you cannot delete or rename a
system parameter.
'arameter !alues can be specified in t"ese ways=
&ccepting t"e default parameter !alues (default !alues are set in t"e 'arameter properties
and you can control w"et"er t"e !alues are displayed at runtime on t"e Runtime 'arameter
4orm).
+yping t"e parameter !alue(s) as arguments on t"e command line (w"ere applicable).
'arameters specified on t"e command line o!erride t"e e;ui!alent system parameter !alues
set in t"e report definition.
,"oosing from a list or entering t"e parameter !alue(s) in t"e Runtime 'arameter 4orm.
5ystem parameters
3racle Reports pro!iding t"e following system parameters. :e can c"ange t"eir default !alues.
5ystem parameter descriptions
System
Parameter Description
,3'I65 Is t"e number of report copies t"at s"ould be made w"en t"e report is
printed.
>6543R2&+ Is eit"er=
t"e output format for t"e report (for example, '>4, ?+2), ?+2),55,
R+4, @2), 5'R6&>5?66+, >6)I2I+6>, or >6)I2I+6>>&+& for
bitmapped reports).
t"e printer definition to use w"en formatting t"e report w"en
>65+A'6B4I)6 and >65<&26Bfilename. If 23>6B9I+2&', t"is is t"e
name of t"e printer. If 23>6B,?&R&,+6R, t"is is t"e c"aracter mode
printer definition file (.prt file).
>65<&26 Is t"e name of t"e output de!ice (for example, t"e file name, printer/s name,
mail user I>).
>65+A'6 Is t"e type of de!ice t"at will recei!e t"e report output (for example, 5,R66<
(to format t"e report using screen fonts), 4I)6, 'RI<+6R, 2&I), 5A53C+,
,&,?6, or )3,&)4I)6.
23>6 Is w"et"er t"e report s"ould run in ,?&R&,+6R mode or 9I+2&'.
3RI6<+&+I3< Is t"e print direction for t"e report ()&<>5,&'6, '3R+R&I+, >64&C)+).
'RI<+D39 Is w"et"er t"e 'rint Dob dialog box s"ould appear before t"e report is run.

User Parameters
:e can create a user parameter in t"e following ways=
,reate a parameter in t"e 3bEect <a!igator.
Cse a bind parameter reference in a ;uery, w"ic" causes Reports 9uilder to automatically
create t"e parameter t"e first time it is referenced
Creating a user parameter
<ote= Reports 9uilder automatically creates a user parameter w"en you use a bind parameter
Reference in a ;uery
+o create a user parameter=
1. In t"e 3bEect <a!igator, expand t"e Data Model node, t"en clic# t"e User Parameters
node.
2. ,lic# t"e ,reate button in t"e toolbar.
. >ouble-clic# t"e properties icon for t"e new parameter to display t"e 'roperty Inspector.
$. Cnder t"e General Information node, replace t"e <ame property wit" t"e desired
parameter name.
%. Cnder t"e Parameter node, set t"e Initial Falue and )ist of Falues properties, if re;uired.
(. +o !alidate t"e parameter/s !alue at runtime, set t"e Falidation +rigger property by clic#ing
property field to display t"e ')758) 6ditor and define t"e ')758) to be triggered at runtime.
LV for User Parameters
Creating a list of !alues "LV# for a parameter
+o create a )3F for a parameter=
1. In t"e 3bEect <a!igator, expand t"e Data Model node, t"en t"e User Parameters node.
2. >ouble-clic# t"e properties icon for t"e parameter for w"ic" you want to create a )3F to
display t"e 'roperty Inspector.
. Cnder t"e Parameter node, double-clic# t"e )ist of Falues property field to display t"e
'arameter )ist of Falues dialog box.
$. 5elect t"e type of list t"at you want to create=
4or Static Values, type a !alue in t"e Value text box and clic# Add. Repeat for eac" !alue
you want to add. (,lic# Remo!e to delete items from t"e list)
4or S$L$C% Statement, type a ;uery to populate t"e list of !alues. Aou can select more t"an
one column to display in t"e )3F, w"ere t"e first column contains t"e !alue to be assigned to
t"e parameter. +"e )3F displays columns in t"e order specified in t"e ;uery.
%. If you want t"e parameter !alue to be restricted to only t"ose in t"e )3F, select t"e Restrict
List to Predetermined Values c"ec# box. +o display a combo box t"at allows users to edit
!alues or type a different !alue in t"e Runtime 'arameter 4orm, clear t"e c"ec# box.
(. If you do not want t"e first column (w"ic" contains t"e parameter !alue) of your ;uery
displayed in t"e )3F, select t"e &ide 'irst Column c"ec# box. If t"ere is no need to preser!e
t"e confidentiality of t"e first column, clear t"e c"ec# box.
,aution= If you send t"e report output to an ?+2) file, eit"er from Reports 9uilder or running
it in your :eb browser, t"e !alue of t"e first column will be !isible in t"e ?+2) source, e!en if
?ide 4irst ,olumn is selected. If you run t"e report from a :eb browser and t"e list of !alues
is unrestricted, t"e ?+2) 'arameter 4orm will display a text field instead of a combo box, and
a list of static !alues t"at you can copy and paste into t"e text field. In t"is case, t"e first
column will always be s"own in t"e 'arameter 4orm, e!en if ?ide 4irst ,olumn is selected.
*. ,lic# (.
)ind Variables
9ind references (or bind !ariables) are used to replace a single !alue in 58) or ')758), suc"
as a c"aracter string, number, or date. 5pecifically, bind references may be used to replace
expressions in 56)6,+, :?6R6, .R3C' 9A, 3R>6R 9A, ?&FI<., ,3<<6,+ 9A, and 5+&R+
:I+? clauses of ;ueries. 9ind references may not be referenced in 4R32 clauses or in place of
reser!ed words or clauses.
:e can create a bind reference by typing a colon (=) followed immediately by t"e column or
parameter name. If you do not create a column or parameter before ma#ing a bind reference
to it in a 56)6,+ statement, Reports 9uilder will create a parameter for you by default.
Restrictions= 9ind references must not be t"e same name as any reser!ed 58) #eywords.
6xample 1= 56)6,+ clause
In t"e following example, t"e !alue of >4)+,322 replaces null !alues of ,322')&< in t"e
rows selected.
S$L$C% CUS%ID* +VL"CMMPLA+* ,D'L%CMM# CMMPLA+
'RM RD-
6xample 2= :?6R6 clause
+"e !alue of ,C5+ is used to select a single customer.
56)6,+ 3R>I>, +3+&)
4R32 3R>
:?6R6 ,C5+I> B =,C5+G
6xample = .R3C' 9A clause
&ll non-aggregate expressions suc" as <F)(,322')&<, =>4)+,322) in t"e 56)6,+ clause
must be replicated in t"e .R3C' 9A clause.
56)6,+ <F)(,322')&<, =>4)+,322) ,322')&<, 5C2(+3+&)) +3+&)
4R32 3R>
.R3C' 9A <F)(,322')&<, =>4)+,322)G
6xample $= ?&FI<. clause
+"e !alue of 2I<+3+&) is used to select customers wit" a minimum total of orders.
56)6,+ ,C5+I>, 5C2(+3+&)) +3+&)
4R32 3R>
.R3C' 9A ,C5+I> ?&FI<. 5C2(+3+&)) H =2I<+3+&)G
6xample %= 3R>6R 9A clause
+"e !alue of 53R+ is used to select eit"er 5?I'>&+6 or 3R>6R>&+6 as t"e sort criterion. <ote
t"at t"is is not t"e same as 3R>6R 9A 1 because =53R+ is used as a !alue rat"er t"an to
identify t"e position of an expression in t"e 56)6,+ list.
<ote t"at >6,3>6 is re;uired in t"is example. Aou cannot use a bind !ariable in an 3R>6R 9A
clause unless it is wit" >6,3>6.
56)6,+ 3R>I>, 5?I'>&+6, 3R>6R>&+6, +3+&)
4R32 3R>
3R>6R 9A >6,3>6(=53R+, 1, 5?I'>&+6, 2, 3R>6R>&+6)G
6xample (= ,3<<6,+ 9A and 5+&R+ :I+? clauses
References in ,3<<6,+ 9A and 5+&R+ :I+? clauses are used in t"e same way as t"ey are in
t"e :?6R6 and ?&FI<. clauses.
6xample *= ')758)
'rocedure double is
9eginG
=my_param =B =my_paramI2G
6ndG

+"e !alue of myparam is multiplied by two and assigned to myparam.
About le.ical references
)exical references are place"olders for columns or parameters t"at you embed in a 56)6,+
statement. Aou can use lexical references to replace t"e clauses appearing after 56)6,+,
4R32, :?6R6, .R3C' 9A, 3R>6R 9A, ?&FI<., ,3<<6,+ 9A, and 5+&R+ :I+?. Cse a lexical
reference w"en you want t"e parameter to substitute multiple !alues at runtime.
:e cannot ma#e lexical references in a ')758) statement. Aou can, "owe!er, use a bind
reference in ')758) to set t"e !alue of a parameter t"at is t"en referenced lexically in 58), as
s"own in t"e example below.
:e can create a lexical reference by typing an ampersand (/) followed immediately by t"e
column or parameter name. & default definition is not pro!ided for lexical references.
+"erefore, you must do t"e following=
9efore you create your ;uery, define a column or parameter in t"e data model for eac" lexical
reference in t"e ;uery. 4or columns, you must set t"e Falue if <ull property, and, for
parameters, you must set t"e Initial Falue property. Reports 9uilder uses t"ese !alues to
!alidate a ;uery wit" a lexical reference.
,reate your ;uery containing lexical references.
Restrictions
Aou cannot ma#e lexical references in a ')758) statement.
If a column or parameter is used as a lexical reference in a ;uery, its >atatype must be
,"aracter.
If you want to use lexical references in your 56)6,+ clause, you s"ould create a separate
lexical reference for eac" column you will substitute. In addition, you s"ould assign an alias to
eac" lexical reference. +"is enables you to use t"e same layout field and boilerplate label for
w"ate!er !alue you enter for t"e lexical reference on t"e Runtime 'arameter 4orm.
If you use lexical references in your 56)6,+ clause, you must specify t"e same number of
items at runtime as were specified in t"e report/s data model. 6ac" !alue you specify for your
lexical references at runtime must "a!e t"e same datatype as its Initial Falue.
If you use lexical references in your 56)6,+ clause, t"e widt" of t"e column is deri!ed from
t"e Initial Falue property of t"e parameter. ,onse;uently, you s"ould ensure t"at t"e Initial
Falue of t"e parameter corresponds to t"e widest column t"at you intend to use.
& Reports 9uilder lin# s"ould not depend upon a lexical reference. +"at is, neit"er t"e c"ild
column of a lin# or its table name s"ould be determined by a lexical reference. +o ac"ie!e t"is
functionality, you need to create a lin# wit" no columns specified and t"en enter t"e 58)
clause (for example, :?6R6) for t"e lin# directly in t"e ;uery. 4or example, your parent and
c"ild ;ueries mig"t be written as follows=
'arent 8uery=
56)6,+ >6'+<3 4R32 62'

,"ild 8uery=
56)6,+ J'&R2_1 ,3)_1, J'&R22 ,3)_2
4R32 62'
:?6R6 J'&R2_1 B =>6'+<3

<ote "ow t"e :?6R6 clause ma#es a bind reference to >6'+<3, w"ic" was selected in t"e
parent ;uery. &lso, t"is example assumes t"at you "a!e created a lin# between t"e ;ueries in
t"e >ata 2odel !iew wit" no columns specified.
& lexical reference cannot be used to create additional bind !ariables after t"e &fter 4orm
trigger fires. 4or example, suppose you "a!e a ;uery li#e t"e following (note t"at t"e :?6R6
clause is replaced by a lexical reference)=
56)6,+ 6<&26, 5&) 4R32 62' Jw"ere_clause
If t"e !alue of t"e w"ere_clause parameter contains a reference to a bind !ariable,
you must specify t"e !alue in t"e &fter 4orm trigger or earlier. Aou would get an error
if you supplied t"e following !alue for t"e parameter in t"e 9efore Report trigger=
:?6R6 5&) B =new_bind

If you supplied t"is same !alue in t"e &fter 4orm trigger, t"e report would run.
6xample 1= 56)6,+ clause
56)6,+ J'_6<&26 <&26, J'_62'<3 6<3, J'_D39 R3)6
4R32 62'G

'_6<&26, '_62'<3, and '_D39 can be used to c"ange t"e columns selected at runtime. 4or
example, you could enter >6'+<3 as t"e !alue for '_62'<3 on t"e Runtime 'arameter 4orm.
<ote t"at in t"is case, you s"ould use aliases for your columns. 3t"erwise, if you c"ange t"e
columns selected at runtime, t"e column names in t"e 56)6,+ list will not matc" t"e Reports
9uilder columns and t"e report will not run.
6xample 2= 4R32 clause
56)6,+ 3R>I>, +3+&)
4R32 J&+&9)6G

& +&9)6 can be used to c"ange t"e table from w"ic" columns are selected at runtime. 4or
example, you could enter 3R> for &+&9)6 at runtime. If you dynamically c"ange t"e table
name in t"is way, you may also want to use lexical references for t"e 56)6,+ clause (loo# at
t"e pre!ious example) in case t"e column names differ between tables.
6xample = :?6R6 clause
56)6,+ 3R>I>, +3+&)
4R32 3R>
:?6R6 J,C5+G

,C5+ can be used to restrict records retrie!ed from 3R>. &ny form of t"e :?6R6 clause can
be specified at runtime.
6xample $= .R3C' 9A clause
56)6,+ <F)(,322')&<, >4)+,322) ,')&<, 5C2(+3+&)) +3+&)
4R32 3R>
.R3C' 9A J<6:,322G

+"e !alue of <6:,322 can be used to define t"e .R3C' 9A clause.
6xample %= ?&FI<. clause
56)6,+ ,C5+I>, 5C2(+3+&)) +3+&)
4R32 3R>
.R3C' 9A ,C5+I> ?&FI<. J2I<+3+&)G

+"e !alue of 2I<+3+&) could, for example, be used to select customers wit" a minimum total
of orders.
6xample (= 3R>6R 9A clause
56)6,+ 3R>I>, 5?I'>&+6, 3R>6R>&+6, +3+&)
4R32 3R>
3R>6R 9A J53R+G

+"e !alue of 53R+ can be used to select 5?I'>&+6, 3R>6R>&+6, 3R>I>, or any combination
as t"e sort criterion. It could also be used to add on to t"e ;uery, for example to add a
,3<<6,+ 9A and 5+&R+ :I+? clause.
6xample *= ,3<<6,+ 9A and 5+&R+ :I+? clauses
'arameters in ,3<<6,+ 9A and 5+&R+ :I+? clauses are used in t"e same way as t"ey are in
t"e :?6R6 and ?&FI<. clauses.
6xample -= 2ultiple clauses
56)6,+ J,3)5+&9)6G

,3)5+&9)6 could be used to c"ange bot" t"e 56)6,+ and 4R32 clauses at runtime. 4or
example, you could enter ><&26 6<&26, )3, 5&) 4R32 >6'+ for ,3)5+&9)6 at runtime.
56)6,+ I 4R32 62' J:?6R63R>G

:?6R63R> could be used to c"ange bot" t"e :?6R6 and 3R>6R 9A clauses at runtime. 4or
example, you could enter :?6R6 5&) H 1111 3R>6R 9A >6'+<3 for J:?6R63R> at
runtime.
6xample 0= ')758) and 58)
56)6,+ J9R6&K_,3) ,1, 2&@(5&))
4R32 62'
.R3C' 9A J9R6&K_,3)G

9R6&K_,3) is used to c"ange bot" t"e 56)6,+ list and t"e .R3C' 9A clause at runtime. +"e
Initial Falue of t"e parameter J9R6&K_,3) is D39. &t runtime, t"e user of t"e report can
pro!ide a !alue for a parameter called .R3C'_9A_,3)C2< (of data type ,"aracter).
In t"e Falidation +rigger for .R3C'_9A_,3)C2<, you call t"e following ')758) procedure and
pass it t"e !alue of .R3C'_9A_,3)C2<=
procedure con!_param (in_!ar I< c"ar) is
begin
if upper(in_!ar) in (/>6'+<3/,/62'<3/,/?IR6>&+6/) t"en
=brea#_col =B /to_c"ar(/LLin_!arLL/)/ G
else
=brea#_col =B in_!arG
end ifG
endG

+"is ')758) ensures t"at, if necessary, a +3_,?&R is placed around t"e brea# column t"e
user c"ooses. <otice "ow in 58), you ma#e a lexical reference to 9R6&K_,3). In ')758), you
must ma#e a bind reference to 9R6&K_,3) because lexical references are not allowed in
')758).
Differences bet0een bind and le.ical references
9ind references are used to replace a single !alue in 58) or ')758). 5pecifically, bind
references may be used to replace expressions in 56)6,+, :?6R6, .R3C' 9A, 3R>6R 9A,
?&FI<., ,3<<6,+ 9A, and 5+&R+ :I+? clauses of ;ueries. 9ind references may not be
referenced in t"e 4R32 clause.
&n example is=
56)6,+ 3R>I>,+3+&)
4R32 3R>
:?6R6 ,C5+I> B =,C5+

)exical references are place"olders for text t"at you embed in a 56)6,+ statement, w"en you
want t"e parameter to substitute multiple !alues at runtime. Aou can use lexical references to
replace t"e clauses appearing after 56)6,+, 4R32, :?6R6, .R3C' 9A, 3R>6R 9A, ?&FI<.,
,3<<6,+ 9A, and 5+&R+ :I+?. Aou cannot ma#e lexical references in ')758). 9efore you
reference a lexical parameter for a column or table, you must "a!e predefined t"e parameter
and gi!en it an initial !alue.
&n example is=
56)6,+ 3R>I>, +3+&)
4R32 J&+&9)6

You might also like