Saturday, January 18, 2020

Clear cache of Data Maps After Making Changes

Data Maps are one of the objects that is stored in Cache. So once a Data maps has been created or modified, the cache must be cleared in order to get the changes reflected in the application.
Following are the options we can use to clear the cache and to see the changes.
  • Restart the Siebel Server or Component to get the change permanently.
  • In site map go to the Administration –> Outbound Web Services or Administration –> Inbound Web Services view and click the "Clear Cache" button.



  • Use a Workflow with a step to call the Business Service "EAI Data Transformation Engine" with method "Purge" (no arguments are required).

GetProfileAttrAsList Function

GetProfileAttrAsList function returns the MVG value as a list. 

We can use GetProfileAttrAsList in the EXISTS operator to create expressions to match MVG profile attributes with appropriate Siebel content.

GetProfileAttrAsList function Syntax: GetProfileAttrAsList ('profile')

Example: If State MVG has the values CA, GA, and MA, where CA is primary; 
GetProfileAttrAsList ('State')  returns CA, GA, MA.

InList Function

InList function, will searches for the string in Comma Separated Values, based on the string provided to search (two arguments are mandatory) and returns True if string occurs one or more times in a comma-separated list.
InList Function Syntax:
InList(“<string to search>”,”<comma separated values>”)
Example: InList("xyz", "asd,xya,xyz")

Friday, January 17, 2020

Different types of Applet

Following are the types of applet which are there in Siebel.
  • Association List
  • Detail
  • MVG
  • Pick List
  • Playbar
  • Standard
  • Task



Generate DB and DB Extract from Server Manager

Generate DB from Server Manager

To generate DB using server manager you require to login into Server Manager then type the following command:

start task for comp GenNewDb server ss_dev with dbffile=sse_utf8.dbf

After that you can check the progress using below command:

list tasks for comp GenNewDb


Database Extract (DB Exract)

To run Database Extract, firstly connect with server manager then type below command:

start task for comp DbXtract server ss_dev with Client="USER",InitMethod="Sql Anywhere",EncryptLocalDbPwd="False",EncryptLocalDbMethod="None",Username="sadmin user name",Password="sadmin password"    

After that you can check the status using below command:

list tasks for comp DbXtract

For DB Extract of Multiple clients you can use below command:start task for comp DbXtrct with client=client1,client2,client3,client4

In the above mentioned commands, 
ss_dev = Siebel server, and 
USER,client1,client2,client3,client4 = is the name of local user to extract the database for. 

Different types of Workflow modes

There are four types of Workflow modes which we use in Siebel.

  • 7.0 Flow
  • Interactive Flow
  • Long Running Flow
  • Service Flow





Siebel Keyboard Shortcuts

Following are the Siebel application keyboard shorts which are useful while working in the application.

About Record: Ctrl+Alt+K
Technical Support: Ctrl+Alt+J
Site Map: Ctrl+Shift+A
New Query: Alt + Q
Run Query: Alt + Enter
Refine Query: Alt + R
Undo Record: Ctrl + U
Delete Record: Ctrl + D
New Record: Ctrl + N
Copy Record: Ctrl + B
Save Record: Ctrl + S
Select All: Ctrl + A
Send Email : F9
Print: Ctrl + P
Log Out: Ctrl + Shift + X

UseDictionaryInTransactionLogging = FALSE

If you want to avoid creation of diccache.dat file while using dedicated client which is connected to Database server, then use the below paramter under [ServerDataSrc] section in the CFG file.


UseDictionaryInTransactionLogging = FALSE 

Please refer below snapshot of the CFG for the location of the parameter

Now, next question comes out that what is diccache.dat file?

Diccache.dat is a cache file which is used by Siebel server programs to optimise the performance while loading the Siebel Repository. Diccache.dat file contains a subset of the repository (which is called the "dictionary") required by the server programs. This file includes the information about tables, columns, indexes and docking objects.


Diccache.dat, located in the SIEBEL_SERVER_HOME\bin directory, is accessed whenever a siebel server program is started. The file is automatically recreated if the file does not exist or if it is out of date.

How web template folders traversed in Siebel Open UI

Following is the search order if more than one folder contains web templates with the same name :

For Siebel Open UI clients:

  • ORACLE_HOME\siebsrvr\WEBTEMPL\OUIWEBTEMPL\custom
  • ORACLE_HOME\siebsrvr\WEBTEMPL\OUIWEBTEMPL
  • ORACLE_HOME\siebsrvr\WEBTEMPL


For High-interactivity and Standard-interactivity clients:

  • ORACLE_HOME\siebsrvr\WEBTEMPL\custom
  • ORACLE_HOME\siebsrvr\WEBTEMPL

Siebel Scripting (eScript) Guidelines


Following guidelines needs to be followed for writing optimum eScript:
  • Use declarative alternatives.
  • Use browser scripts for simple client-side functions such as field validation.
  • Do not return large result sets from server business services to browser scripts.
  • Minimize scripting on field-level or control-level events.
  • Use simple scripts on applet-level and business component-level events.
  • Caching data in Siebel eScript scripts. 
  • Declare your variables. 
  • Destroy any created objects when you no longer need them. 
  • Verify your script is defined on the appropriate method.
  • Verify your script is implemented in the right view. 
  • Avoid redundant repository object settings.
  • Use the ActivateField() method carefully.
  • Use the ExecuteQuery() method carefully.
  • Use SetSearchSpec() method rather than NextRecord() method.
  • Use ForwardOnly cursor mode.
  • Use appropriate error handling. 
  • Avoid nested query loops. 
  • Use the this object reference.
  • Use the Switch construct.
  • Finally Test your custom scripts.

Unlock Repository objects




Following are the SQL commands that we can use in unlocking siebel objects.


VIEW


UPDATE siebel.s_view view SET view.obj_locked_flg = 'N', view.obj_locked_date = NULL, view.obj_locked_by = null, view.obj_locked_lang = null


WHERE view.row_id = 'Row_Id';


commit;


TABLE


UPDATE siebel.s_table tab SET tab.obj_locked_flg = 'N', tab.obj_locked_date = null, tab.obj_locked_by = null, tab.obj_locked_lang = null


WHERE tab.name = 'CX_TEST_TABLE'


and tab.row_id = 'Row_Id';


commit;


BUSINESS COMPONENT


UPDATE siebel.s_buscomp bc SET bc.obj_locked_flg = 'N', bc.obj_locked_date = NULL, bc.obj_locked_by = null, bc.obj_locked_lang = null


WHERE bc.row_id = 'Row_Id';


commit;


BUSINESS SERVICE


UPDATE siebel.s_service serv SET serv.obj_locked_flg = 'N', serv.obj_locked_date = NULL, serv.obj_locked_by = null, serv.obj_locked_lang = null


WHERE serv.row_id = 'Row_Id';

commit;

APPLET


UPDATE siebel.s_applet appl SET appl.obj_locked_flg = 'N', appl.obj_locked_date = NULL, appl.obj_locked_by = null, appl.obj_locked_lang = null


WHERE appl.row_id = 'Row_Id';


commit;


PROJECT


UPDATE siebel.s_project  AS proj SET proj.locked_flg = 'N', proj.locked_date = null


WHERE proj.name = 'Test Project';


commit;

spf file in Siebel

Today I'll be going through Siebel user preference file also referred in siebel as .spf file. All the users settings done by the users and all the details of the users are stored in .spf file of that user. 

User preference file are stored in the form of:

USERID&Siebel_APPLICATIONNAME.spf

For example, SADMIN&Siebel Power Communications.spf will be the user preference file for the user SADMIN running Siebel Power Communications.





Location of user preference file (.spf):

In Siebel Mobile or Dedicated Web Client, user preference file is stored on the local client machine at SIEBEL_CLIENT_ROOT\bin directory
In Siebel Web Client, user preference file is stored on the Siebel Server in the UserPref subdirectory under the Siebel File System directory.



We can change the .spf location directory by making changes in SharedModeUsersDir parameter. Which is present in the AOM component parameter.

Cascade Delete Property

The Cascade Delete property is used to determines whether a child record is deleted when the parent record is deleted.


  • Delete: Child records are deleted along with the parent.
  • Clear: The foreign key reference is removed if the parent record is deleted, but the child records remain in place. Value in the foreign key column is cleared. 
  • None: No records are deleted and the foreign key column is also not cleared. This is the default setting of the Cascade Delete property.

Which Siebel Objects have Sort Specification and Search Specification?

In this post I'll be taking you through the places where Sort specification and search specification are placed.

Following are the objects where we can have Search Specification:

Applet



Business Component





Link



Pick List



Following are the objects where we can have Sort Specification:

Business Component



Link


In Link, We can use sorting only in case of an association list to order the detail records retrieved which means it is specified for M:M links only.

Pick List



Force Active User Property

Today I'll will be going through Force Active property at Business Component level. As we all are aware about Force Active at the Field Level.



Where when Force Active is true then field is queried each time the business component is instantiated (we can check it in the SQL which gets triggered once BC is instantiated), even if field is not exposed on the user interface. Also, to note that setting this property to TRUE may reduce performance.


Similarly, we have Force Active property at the Business Component level,



It can have two values. TRUE or FALSE. By default for ever business component this property is set to FALSE.

If this property is set to TRUE, then all the fields in the Business Component are automatically retrieved from the database server. This will result in reducing the performance of the business component and is also not recommended.

Siebel CRM Administration Issues we face

Following page covers the Siebel CRM Administration issues we face and solutions to it. Please add if you have faced any issues. 

Siebel Interview Questions

Following page will provide frequently asked question during Siebel Interview with answers.

Siebel Interview Questions

Steps for Siebel CRM Database Restart



Following steps needs to be performed for taking Siebel CRM Database Restart

Step 1> Login to your Siebel CRM database through unix with credentials.

Step 2>lsnrctl stop LISTENER

Step 3> Check all the session on the database using command: ps -ef|grep LOCAL=NO
and kill all the inactive sessions using the command: kill -9 <Session Id>

Step 4> sqlplus sys as sysdba
 Enter the password.

Step 5>alter system checkpoint;

Step 6>alter system switch logfile;

Step 7>shu immediate;

Step 8>startup;

Step 9>exit

Step 10>lsnrctl start LISTENER

How to see active users in Siebel CRM application

Log into Server Manager and get a list of the object manager names

list components show SV_NAME, CC_NAME, CC_ALIAS , CP_DISP_RUN_STATE

Copy the CC_ALIAS of the Object manager. e.g. if the CC_ALIAS is eCommunicationsObjMgr_enu 

After that

List Active sessions for comp eCommunicationsObjMgr_enu show SV_NAME,CC_ALIAS,OM_LOGIN

HTML Number of Rows

In Applet Object there is an important property known as HTML Number of Rows, which represents the number of rows to be displayed when a list applet is rendered.

This property is exclusively applies to list applets.





In Siebel Configuration interview this is commonly asked topic. 

Virtual Business Component

Virtual business components (VBCs) are mechanisms in Siebel EAI by which data from an external system can be viewed in Siebel applications without having to store that data within the Siebel Database.

Class of VBC needs to be set as CSSBCVExtern as this class provides the VBC functionality.

A VBC requires a business service to provide the following standard methods for manipulating external data

1. Init (required)
2. Query (required)
3. Preinsert (optional)
4. Insert (optional)
5. Update (optional)
6. Delete (optional) 

There are two approaches to use VBCs:

1.Use the XML Gateway business service to pass data between the VBC and one of the Siebel transports, such as the EAI HTTP Transport or the EAI MSMQ Transport.
2. Create your own custom business service in Siebel eScript or in Siebel VB to implement the methods described above.

Enterprise Integration Manager (EIM)


About Siebel Enterprise Integration Manager (EIM)



  • Siebel EIM is a server component in the Siebel EAI component group that transfers data between the Siebel database and other corporate data sources.
  • Exchange of information is accomplished through intermediary tables called EIM/Interface tables.
  • The EIM tables act as a staging area between the Siebel application database and other data sources.
  • EIM is the primary method of loading mass quantities of data into the Siebel database.
  • EIM can be used to perform bulk imports, updates, merges, and deletes of data.
There are 4 different process/functions in Siebel EIM:

1. Import
2. Delete
3. Merge
4. Export

Siebel Vertical Application & Horizontal Application




Siebel Applications can be broadly classified as:


  • Vertical Applications
  • Horizontal Applications


Vertical Applications:
Vertical Applications are specifically made for one domain.
Eg.: Siebel eFinance, Siebel ePharma

Horizontal Applications:
Horizontal Applications are Common which can be used for any domain.
Eg.: Siebel Sales, Siebel Call Center

Auto Login to Siebel Client Tools

Siebel Client-Login Page

Siebel Tools-Login Page



The following syntax is very useful while working on Siebel as we need to login and logout for many times.

Right click on the icon, in properties window, you see Target value something like the following,
"C:\Siebel\8.1\Tools\BIN\siebdev.exe" /c "C:\Siebel\8.1\Tools\bin\enu\tools.cfg"

To automate your login to Local Database.

add the following
"C:\Siebel\8.1\Tools\BIN\siebdev.exe" /c "C:\Siebel\8.1\Tools\bin\enu\tools.cfg" /u USER/p USER /d local

here

/u : stands for user name
/p : stands for password
/d : stands for data source

Same configuration can be used for Siebel Clent as well.



Link Specification property in business component field object

Link Specification property should only be set to True if the field on the BC is used by child BC where: 

  • Child BC field references the parent field in the calculated value, Post Default Value or PreDefault Value using the syntax: Parent: 'BusComp.Field', 'BusComp.Field'; or 
  • The child BC references the parent field in a BC User Property: Parent Read Only Field.
  • If ParentFieldValue function is used to obtain the value of the parent BC field. 

Use of EAI Value Map in an integration field map source expression

EAI value map is when we need to convert a field value from it’s external representation into it’s internal representation and visa versa by referencing a EAI Value Map in a Data Map.

The source expression in an integration field map can use EAI value maps.

We can use the EAILookupSiebel function for inbound value mapping which uses the following syntax:

EAILookupSiebel(“”,[VALUE],[])

We can use the EAILookupExternal function for outbound value mapping which uses the following syntax:

EAILookupExternal(“”,[VALUE],[])

The following is an example integration field map source expression:

EAILookupExternal(“Country”, ifNULL(LookupName(‘COUNTRY’,[Bill To Country]), “UK”))

In this case, EAILookupExternal returns a value from the EAI data map table whereas LookupName returns a value from the LOV table.

EAI XML Write To File from eScript

While development we need to see property set to debug. 

Following snippet comes handy during that time:

var bsService = TheApplication().GetService("EAI XML Write to File");
var psOutputs = TheApplication().NewPropertySet();
psInputs.SetProperty("FileName","c:\\Propset.xml"); // Location and Name of Property Set file
bsService.InvokeMethod("WritePropSet",psInputs,psOutputs);

How to call Business Service from Calculated Field Expression

Through InvokeServiceMethod we can call Business service from a Calculated Field Expression.


Syntax:
InvokeServiceMethod ("Business Service Name", "MethodName", "inputarg1=" + [Field Name 1] + "," + "inputarg2=" + [Field Name 2], "outputarg")


Note: We should avoid using InvokeServiceMethod if the Calculated Field is exposed in the UI. Business Service will be invoked every time user step off a record.

About ExecuteQuery Method

ExecuteQuery(ForwardOnly):

Use ForwardOnly Cursor Mode if you will traverse through the record set from FirstRecord using NextRecord and will not return to a previous record. 

ExecuteQuery():

If ForwardOnly cursor mode is not mentioned, it will be defaulted to ForwardBackward and to support this Siebel system has to create a Cache to maintain the entire record which would degrade the performance.

Scripting Alternatives




Following are the alternatives which needs attention before doing any scripting:

• Field validation
• User properties
• Workflow
• Personalization
• Run-time events
• State model
  

How to find the latest Record in Siebel?



SQL Query to Get Latest Record


There are times when we require to find latest record in siebel through SQL.

Following are the SQL which fetches the latest records of S_SRV_REQ table.

SELECT * FROM SIEBEL.S_SRV_REQ 

WHERE CREATED  = (SELECT MAX(CREATED) FROM SIEBEL.S_SRV_REQ);
OR
SELECT * FROM SIEBEL.S_SRV_REQ
WHERE (CREATED>sysdate); 

Note : CREATED Column is the created date of the record.


Where to write script "Browser versus Server Script"?

At times there comes a question as where to write code at Browser level or at Server level?

So to come up with the answer here are the differences between Browser and Server Script:

Browser script is used in the following scenarios:

  • When we require communication with the user (to show some informative message using popup or to get some response like Ok, Cancel which is used in dialog box)
  • Interaction with desktop applications.
  • Data validation and manipulation limited to the current record.
  • Browser scripts are stored as .js file.


Server script is used in the following scenarios:

• Query, insert, update, and delete operations.
• Access to data beyond the current record and to build complex logic.

DefaultFocus User Properties in Siebel

Default Focus user property is used when we need to set default focus on specific column in different modes of a list applet.

DefaultFocus user property can be used as shown in the screenshot below.




Following are three user properties which are used to set the DefaultFocus in siebel:

  • DefaultFocus_New    : It will set focus on specified field when user creates a new record.
  • DefaultFocus_Edit     : It Will set focus on specified field when user edit a record.            
  • DefaultFocus_Query  : It Will set focus on specified field when user queries on the applet.

Assignment Manager

Assignment Manager of Siebel assign business entities and work items to the most qualified candidates by using business rules set by sales, service, and marketing organizations.

Assignment Manager does this by matching candidates (viz. employees, positions, and organizations) to predefined and user-configurable assignment objects. To assign the most qualified candidate to each object, Assignment Manager applies assignment rules that you define to each candidate.

Following are major terms used in Assignment manager:
  • Assignment Objects
  • Candidates
  • Criteria

a) Assignment Objects: (means data that needs to be assigned) Find the types of data being assigned, such as accounts, opportunities, and service requests. An assignment rule may be used to assign one or more assignment objects

b) Candidates: (defines people, positions or organizations which will be assigned to that data) Assignment Manager assigns data to: Employee candidates, Position candidates, Organization candidates. An assignment rule may contain a list of candidates who are assigned if the rule passes or match data to candidates based on their skills.

c) Criteria: (tells which data will be assigned to which candidates) There can be multiple criteria per rule.

Few Business Component User Property for TBUI



Few Business Component user properties which could be helpful while working on TBUI (Task Based UI):

User Property: OracleCBOHint
Value:         ALL_ROWS

User Property: Immediate Commit In Task
Value:         TRUE

User Property: Dup Conflict In Task
Value:         Ignore new record

User Property: DB2 Optimization Level
Value:         3

** Use these user property after consulting your application architect.

Task Based UI EnableStandardMethods




If the EnableStandardMethods user property is declared on an applet, then in an applet we can perform various operation (Like editing multiple records) on various applet which are based on Task based UI.


User property : EnableStandardMethods
Possible values: Y or N

How to configure a workflow policy?

Following steps should be followed for configuring Workflow Policy:

A> Firstly ensure Workflow Policy column is created in Siebel tools and it is added in workflow policy object.

B> Create workflow policy action to execute workflow.

C> Create workflow policy record and create conditions and associate action to the workflow policy.

D> Execute “Generate Trigger” task to create triggers.

E> Restart Workflow Monitor Agent.

Generating browser script manually (GENB)

To generate browser script we need to use the following syntax:

genbscript “cfg file path” “name of folder where browser script's are to be generated”

Example:

"D:\Siebel\8.1.1.11\Client\BIN\genbscript.exe" "D:\Siebel\8.1.1.11\Client\BIN\ENU\scomm.cfg" "D:\Siebel\8.1.1.11\Client\PUBLIC\enu"

Once browser scripts are generated then it will be available at:

Siebel installation\web client\public\enu.

Browsers scripts are generated as .js files.

Standard Interactivity versus High Interactivity





Siebel works with two types of framework viz. Standard Interactivity &  High Interactivity.


The difference between both the frameworks is how Siebel Client communicates with Server. In case of standard interactivity the changes you make to record are not committed automatically to the database and user has to explicitly save the record whereas in High interactivity even if you step off the record which means data is committed automatically.

Standard Interactivity mode resembles most traditional Web applications which means Customer applications are deployed in Standard Interactivity mode whereas Employee applications are typically deployed in High Interactivity mode.

Saturday, January 11, 2020

Siebel SRVRMGR Utility: Taking spool

If there is any requirement where we need to take export of Parameters or Components from SRVRMGR Utility through command prompt, then we need to follow following steps to extract spool while working with SRVRMGR in command line mode:


cmd:>srvrmgr /g GATEWAY_ADDR /e ENTERPRISE_SERVER_NAME /s SIEBEL_APPLISRVR_LOG_NAME /u USERNAME /p PASSWORD


srvrmgr:>spool C:\spool_parameter.txt


srvrmgr:> list parameters for component ADMProc


srvrmgr:> list advanced parameters for component ADMProc


srvrmgr:> list hidden parameters for component ADMProc


srvrmgr:> spool off


srvrmgr:> exit




Once you exit the SRVRMGR , then you will get spool_parameter.txt file ready with all required information.

How to setup logs in Local?

For debugging, we need to see the logs in the local so to setup log in the local machine, and to Increase the Log level in the developer client, refer below mentioned steps:


i.  Right Click on My Computer icon and Click on Properties.



ii. Navigate to Advanced TAB and Click on Environment Variables button.


                             


iii. Click on New in User variables and enter the following values :Variable : SIEBEL_LOG_EVENTSValue : 55 refers to the highest level of Log level

iv. Click on New in User variables and enter the following values :Variable :SIEBEL_LOG_DIRValue : C:\Logs\

You can mention your folder location where you want to store logs.








v. Close all your IE Browsers and Siebel applications and start to debug.

Clib function not supported in Client Side BS

After Siebel upgrade to 8.1.1.11 we can see that Clib function is not working in our existing client side Business Service script.

Following error can be seen:

 “Cannot access file system file”.

Starting from Siebel Version 8.1.1.11, below Clib functions are by default disabled to make application more secured.

Clib.fopen()
Clib.rmdir()
Clib.remove()
Clib.mkdir()
Clib.rename()
Clib.system()

To avoid error add/update below system preference in Application.
From Site Map navigate to 

Administration - Application screen > System Preferences view

System Preference Name: Allow File System Access
Value: True

Note: Even with the System Preference changes as mentioned above Clib function cannot be enabled in client side Business Service, but it will only for Siebel Server Side Business Service, compiled in Siebel Tools.

Updating parent BC depending on the status of child BC using configuration

Parent BC: Service Request Child BC: Action Requirement: When all the Actions corresponding to an SR are closed the SR status should be “Clo...