Wednesday, May 6, 2009

Configure a Join.

Configure a Join.
7 may 2009
It is my effort to provide an explanation on joins and step by step procedure on how to configure them in Siebel.
First of all I will try to explain what the join is.
There are two type of commonly used joins
Implicit Join
Explicit Join
Implicit Join: - Implicit Join are those which are already define in Siebel and which are internally use by the Siebel to pull the values from the other than base table.
example: - join between base table and extension table like S_OPTY and S_OPTY_X and join between S_PARTY and S_ORG_EXT
Explicit Joints: - Explicit Joints are those which are define by the developer to create the relationship between two tables.
Let’s take a real life example to understand the concept of Joins better.
We have one table of the Employee where Name, Employee Id and other information about the employee is stored.Another table stores a list of Cities.
Requirement is to know which user stays in which city. There are two ways to do it
Store city in the Employee table which will result in data redundancy.
Store Primary key of city table in the employee table and pull the values at the run time, which is more efficient and makes more sense.
To implement second approach we use joins in Siebel.
You have to follow the following five steps to have joined field on UI in Siebel
1. Identify the column to be used as Foreign key.2. Configure field which will store the primary key of join table.3. Configure a join.4. Configure join specification.5. Add a field which will be used at Applet.
An example will make things more clear.
Suppose we want to have Opportunity Name on the Quote Applet. Here is a step by step procedure with screen shots explaining how to do that.
1. Identification of Column to act as foreign key.
To configure a Join, first of all we have to find out a column in the base table where we can store primary key say (ROW_ID) of opportunity in quote which will become the basis of join.
If there is no column vacant in the base table we can use extension table for that base table e.g S_DOC_QUOTE_X for the S_DOC_QUOTE.
Note: Make sure that the column you choose is not being used by any other BC or any other field of same BC.
2. Configure Field in Business Component
Go to Business Component > Field
Create a new record
Enter the name of the field.
Enter extension table name in Join field if the column you identified belongs to extension table otherwise go to step 5
Select the Column identified in column Field.
Note: The column which you have selected must have physical Type varchar.Our Foreign key is now ready for use. Now we have to configure a joined Field which will use this foreign key
3. Configure/Create a Join
Go to Business Component > Join
Create new record.
Give name of the table with which you want create join ( S_OPTY in our case)
Give Name in Alias (New in our case).
Check the Outer join Flag (Very Important).

Go to Object List Explorer (OBLE) on the left hand side and click + sign beside join there will be two options Join Specification and Join Constraints
4. Configure Join Specification
Create New Record.
Give Name in the Name field.
Destination Column is given by default when insert a new record. You can change it if you want to.
In the Source field give the name of the source field (OptyID) which you have configured earlier to be used as Foreign Key.

5. Configure the field (Opportunity Name) which you want to display on the User Interface.
Go to Business Component > Field
Insert New Record
Give Name in the Name Field
Enter the Join Alias which you have given for the join you created.
Select the Name (for Opportunity Name) in the column field. Column name here represent the data that you want to pull from opportunity.
6. Configure the Control in the Applet (UI).
Go to Applet > Control (if Form Applet)
Go to Applet > List > List Column (if List Applet)
Create New Record.
Enter the Name
Enter the name you want to display on UI in Caption Override Field
Enter the Name of the field you created in Field column

Don’t forget to map this field in Applet. Right Click on the corresponding Applet and map it.

Now compile the entire project which you have made the changes and you will be able to see this joined field in the Quote Applet as shown in the picture below.

When you see this field in User Interface it will be read only because when the data is pull from the join table it is only read only, to make it editable you have configure Pick Applet on this field

Thursday, February 12, 2009

veryy soon Shuttle Applet..an interesting topic to learn

Shuttle Applet B/W Contact and Opportunity( For M:M relation Ship b/w 2 Table)
1 Create a Link or use existing Link B/W Contact and Opportunity. Link must have Property i.e Inter Table , Inter Parent Column and Inter Child Column
2 Create a New Multivalue Link having properties like..i.e
Name--Test Con Opp MVL
Destination Business Component—Opportunity
Destination Link--Contact/Opportunity
Primary Id Field—
Note : Here Primary Id Field is a field that specifies the name of the field in the master business component that holds the Row ID values pointing to the primary record in the detail business component.
3 Create New MVF Under same BC with following Properties .i.e
Name--Test Con Opp
MVL--Test Con Opp MVL (use which you have created)
Field--Key Contact Id(Field exist on child BC )
4 Create New MVG Applet with the help of Wizard having diff properties like...i.e
Name--Test Con Opp MVG
Project—Contact
B.C—Opportunity(Child B.C )
Associate Applet--Test Con Opp Asso
Type—MVG
Child Object—Applet Web Template
5 Create Associate Applet by the help of wizard choosing MVG Applet and having diff properties like...i.e
Name-- Test Con Opp Asso
Project—Contact
B.C—Opportunity(Child B.C
Type— Association List
And for Applet Web template
6 In Contact--Contact form Applet ---Create new control to display Shuttle Applet
In Controls
Name-- Test Shuttle
Field-- Test Con Opp(MVF you have created)
MVG Applet--- Test Con Opp MVG(MVG applet that already created)
Now go to Edit web layout---->and place that Control that you have created
7. Compile All Changes

Tuesday, February 3, 2009

Difference between Contraint PickList and Hierearchial Pickl ist

Constraint Picklist:While configuring Constraint PickList, we use two different picklist for parent and child field and both picklist should based on PickLIst Genericbusiness component

Hierarchial Picklist:while for hierarchical, both fields(parent and child) uses the same picklist and picklist is based on PickList Hierarchical Business component.E-x Country--State-District.
To Create Hierarchial picklist refer to:http://blogs.oracle.com/siebelessentials/2008/11/hierarchical_picklists_unveile.html

Thursday, January 29, 2009

How to create MVG

To create a MVG in Opportunity Form Applet – Child by creating new control. So that for each opportunity it display the Revenue associated with it.

Ans.So the PBC- Opportunity
CBC/Destination: Revenue
Go to Link: Opportunity/Revenue
Destination Field: Opportunity Id
Go to BC Opportunity:

Go to MVL for the same BC opportunity:
Create New

Name .Auto Primary .Destination .BC Dest Link .Primary Id Field Use .Primary Join
Manish Link .Default .Revenue .Opportunity/Revenue .Primary Revenue Id .Yes

Note: Primary Id Field..This property specifies the name of the field in the master business component that holds the row ID values pointing to primary records in the detail business component

Go to MVF for the same BC I,e opportunity
Create new record

Name .MVL .Field .Use Default Sensitivity
Manish MVF Manish Link Opportunity Id .True
(MVL--That we created above)

Note: Name –Manish MVF will be created automatically in the Field as well.
Field—Here it is Field in child BC-i,e a foreign key column field to the parent bc field.
I,e under Link Opportunity/Revenue the value of destination field will be here.

So Move on to Field . And fill the remaining properties

Name . Destination Field .Multivalve Link Multivalve Type

Manish MVF .Opportunity Id .Manish Link .True .DTYPE_TEXT


Create an MVG Applet.

With the help of the wizard.
Go to File—New Object – Applet Tab---Double Click on MVG Applet Icon..
Name – Manish MVG Applet
It should be based on Child BC- i.e. Revenue here.
Next

Web Template Type: Popup List Template
Next
Select the field that u want to show up in the MVG applet select 3-4 field of Revenue here bcz for that opportunity we want to show revenue that’s why

Next
Next
Finish.
Add one more list column to this Applet (Manish MVG Applet)

Applet-- Manish MVG Applet

List—List Column—

Name-Primary
Field = SSA PRIMARY FIELD
Display Name = Primary
Html Type = Check Box
Html Icon Map = Check
Run Time = True.
Note..We can create a mvg applet withough wizard as well

Final Step.

Go to that Applet where we have to show that MVG.

Go to Applet.-- Opportunity Form Applet – Child
Control—Create New.

Name ..Caption ..Field .Html Row Html Type MVG Applet Runtime Visible
Manish .Manish .Manish MVF Y .Field .Manish MVG Applet Y .Y

Go to the applet -- Opportunity Form Applet – Child—right Click—Edit Web Lay Out.
Add the Control i,e. Label and Text Box(Drag and Drop to the Applet) named Manish.

Compile Locked Projects.
At last you see the changes.See the images for the changes.