people code imp. questions



1.Define PeopleCode?
A: PeopleCode is an object oriented proprietary (case-insensitive) language used to express business logic for PeopleSoft  applications.
2.where can you write the PeopleCode?
A: 1.Record field level
2.Page people code
3.Component level people code
4.Component record people code
5.Component record field people code
6.menu item people code
7.Application engine people code
8.Component interface people code
9.Messaging people code
10.Application package people code
3.whwre peoplecode get stored?
A:Database server(PSPCMPROG) table
4.order of peoplecode events firing?
5.when workflow even fires?
A: after the save pre change work flow event get  fired.
6.What are the types of data types are available in PC? give me some Ex for each?
A:1.Conventional(float, integer) 2.Object data types(record, rowset)
7.what are the comments available in PS?
A:Rem, /* */,<* *>
8.variable types available in PC?
A:user defined and  system defined
9.what is the component processor?
10.explain about the component buffer and data buffer?
11.difference b/n sqlexec and createsql?
12.what is the getsql function in PC?
13.Transfer()with syntax
14.transferpage()with syntax
15.expalin about ACTIVE event?
16.Define about Funclib()
17.what is differed processing?
18.what is a rowset?
19.order of events PC events firing in differed processing?
20.diff b/n saveprechange and savepostchange?
21.diff b/n saveedit and fieldedit?
22.expalin about fieldformula?
23.diff b/n prebuild and postbuild?
24.what is diff b/n winmessage and msgget functions?
25.explain use of gray and ungray fun ?
26.purpose of all and none functions ?
27.what are the PC function to use control the translate values dynamically?
A:adddropdownitem and deletedropdownitem
28.what are the foundations classes which are useful to access component buffer?
29.syantax to declare a variables in PC?
30.define standalone rowset?
31.diff b/n getrowset and createrowset?
32.use of scrollflush()
33.explain about the workflow event?
34.explain about thinhtime and thicktime function?
35.in whic pC events dosave function is useful?
FieldEdit, FieldChange, or ItemSelected
36.callappengine() explain with syantax?
37.what is the difference b/n err msgget and war msgget?
38.expalin about remote call feature in PC?
39.some PC file attachment functions?
40.define PC editor?
41.  diff b/n meta sql and normal sql?
42. Which PeopleTool is used to input peoplecode? - Application Designer.
43. When is PeopleCode case sensitive?
PeopleCode is only case sensitive within a quoted literal.
44.  In which PeopleCode would you code errors and warnings?
SearchSave, FieldEdit, SaveEdit and RowDelete primarily. You may also code errors and warnings in RowSelect.
45.What is the biggest drawback to Fieldformula?
Since FieldFormula is performed every time the panel is displayed on every row of data, its biggest drawback is the performance overhead it adds.
46. What other PeopleCode event might you expect to find with RowInit?
FieldChange. Since RowInit initializes the data before it is displayed, usually it is used along with FieldChange to accommodate any of the changes that are performed by the operator once the panel is displayed.
47. How does SavePostChg differ from all other Peoplecode events?
SavePostChg is different from all other Peoplecode events since it is performed after the updates are made on the database.
48. What happens if you don't declare a variable?
If a variable is not declared PeopleCode will assume it is a local variable.
49. Why are application specific people-code functions used?
PeopleCode functions are used to perform the same logic in multiple programs while only having to maintain it in one place.
50. How is a PeopleCode function called?
A PeopleCode function is called by referencing the function name and then passing the function the appropriate number of parameters in parentheses.
51. How must a PeopleCode function be defined so that it can be used as a variable in the calling program?
In order for a PeopleCode function to be used as a variable, it must be defined using a "Returns" in the Function statement. Also, at least one "Return" statement must be used in the function code.
52. Why is the Message Catalog used?
The Message Catalog is used to store the text of error and warning messages that will be used in PeopleSoft applications. This allows the same message to be used in more than one PeopleCode program while only maintaining it in one place. It also prevents the text of messages from being hard-coded into Peoplecode programs.
53. How is a message added to the Message Catalog?
To add a new message to the Message Catalog, the correct message set should first be retrieved. A new message can be added to the set by performing a row insert (F7). The new message number will automatically be assigned.
54. Which message sets does PeopleSoft reserve as its own?
Message sets 1 through 19,999 are reserved for use by PeopleSoft applications. Message sets 20,000 through 29,000 can be used by PS users.
55. How is a message retrieved from the Message Catalog in PeopleCode?
To retrieve a message from the Message catalog in PeopleCode, the MsgGet built in function is used. The required parameters of the function are message set, number and a default message.
56. When should WinMessage be used?
The WinMessage built-in function is used to display an information message to the operator without performing normal error and warning processing. It also can be very helpful when used for debugging.
57. When would FieldChanged, RecordChanged, RecordDeleted, RecordNew, and PanelGroupChanged be used?
These built-in functions can be used in SaveEdit, SavePreChg, or SavePostChg programs to filter down the processing to occur only when necessary.
58.  Why is PriorValue used?
The PriorValue built-in function is used to determine the value of a field before it was changed.
59.What is the CurrentRowNumber?
It is the number of the row of data the application processor is performing PeopleCode on in the buffers on the client workstation.
60.How does AddToDate work?
This function is passed a date field and then the number of years, months and days to add. Leap years are automatically taken into consideration, and negative numbers may be passed as parameters to subtract from the date.
61. Which two cross reference reports are best for PeopleCode? How do they present their data?
XRFFLPC reports for one field all of the PeopleCode programs where it is referenced. XRFPCFL does the opposite. It reports for one PeopleCode program all of the fields it uses.
62. What does Find in PeopleCode do?
The Find in PeopleCode utility will scan through all of the PeopleCode on a database looking for a specific character - string.
63.When is it useful to select the Export to File option in Find in PeopleCode?
An Export report produces an unformatted copy of all of the source code where the character string was found. This can be very helpful in an upgrade.
64. How can you use WinMessage as part of the debugging process?
A WinMessage can be used to set break points and display the current value of fields and variables in the PeopleCode debugging process.
65. How do you turn on the PeopleCode trace?
·                     The PeopleCode trace can be turned on by selecting the Set push button on the PeopleCode Trace Control panel.
·                     It can also be turned on by saving options in the Configuration manager, logging out of Psoft and logging back on.
·                     It can also be turned on within PeopleCode by using the SetTracePC built-in function.
66. What is the name of the file created by the trace? DBGI.TMP which is stored in TEMP directory.
67. How do you turn off the PeopleCode trace?
The PeopleCode trace can be stopped by turning off all of the check boxes on the PeopleCode trace control panel and selecting the set push button.
It can also be turned off within PeopleCode by passing the parameter zero to the SetTracePC built-in function.
Once the PeopleSoft session is closed, the PeopleCode trace will also automatically be turned off.
68. How many rows of data can there be at occurs level 0?
There can only be one row of data for each record definition at occurs level 0. Scroll bars are not allowed at this level.
69. How many rows of data can be there at occurs level 1?
There can be multiple rows of data for each record definition at occurs level 1 since a scroll bar can be used to navigate between them.
70. What must exist at occurs levels 1,2,and 3 but not occurs level 0? - A scroll bar.
71. How does the application processor allocate buffers to hold data?
The application processor starts allocating buffers at occurs level 0 and then works its way down. It uses the panel and record definitions to determine the data it needs. From a panel definition, fields are allocated in TAB order. Generally, if there is one field from record definition on the panel, the entire row will be brought into the buffers. The exceptions are fields that are in the search dialog box, derived work fields and related display fields.
72. What record definitions will perform PeopleCode in a panel group?
Any record definition that is not used as a related display record will perform PeopleCode in a panel group.
73. In what order will PeopleCode be performed on the buffers in a panel group?
PeopleCode starts at the top of the buffers in a panel group and works its way down to the bottom. The PeopleCode programs on a given row will be performed in the same order as the fields on the record definition.
74.  When should the SQLExec function be used instead of the scroll buffer functions?
Dates are converted within SQLExec built-in function by using the system variables %DateIn and %DateOut.
75. What are the drawbacks of using a SQLExec built in function?
Since the SQL statement is contained within quotes, it is a black box to PeopleSoft. Means the programmer is responsible for the syntax, efficiency and maintenance of the SQL. Also, if a SQLSelect is being performed within the function, only one row of data can be returned.
76. What are Inline variables? How are they used?
Inline variables are used to reference the value of fields stored in the buffers in SQL statements. An inline variable consists of a colon followed by the appropriate record and field name to be referenced. 136. How are dates converted within SQLExec statements? Dates are converted within SQLExec built-in function by using the system variables %DateIn and %DateOut.
77. What parameters are passed to the built-in function SQLExec?
The SQLExec built-in function is passed the SQL statement to perform within quotes, followed by any bind variables or output variables if necessary.
78. What PeopleCode event is fired before a popup menu is displayed?
PrePopup. It allows you to alter the appearance of the popup menu.
79.What functions may be used to alter the appearance of a menu item?
DisableMenuItem, EnableMenuItem, HideMenuItem, CheckMenuItem and UnCheckMenuItem.
80. When is the ScrollFlush function used?
Is used to remove the rows of data from within a scroll bar without deleting them from the database.
81.What are the parameters of a ScrollFlush function?
Name of the primary record definition for the scroll bar where the rows of data will be removed.
82.in which PC events domadel func can't be used?
savepre,save post,workfl,rowselect
83.what is domodal with syantax?
DoModal(PAGE.pagename, title, xpos, ypos, [level, scrollpath, target_row])
84. PeopleCode Tables

PSPCMNAME: PeopleCode Reference table.

PSPCMPROG: Store actual PeopleCode programs (actual code behind PeopleCode events).
Process Request Tables

PSPRCSQUE: This record contains the process request information to run a process request.

PSPRCSRQST: This record contains the process request information to run a process request.

PS_PMN_PRCSLIST: A view to list all process requests in the Process Monitor except for "Delete" (runstatus = 2) process requests.
85.how to pass peoplecode execution?
There isn't a delivered way to pause the execution of PeopleCode. However, there are two alternatives that you can use:
  • The java.lang.Thread.sleep() Java Class method or;
  • The DBMS_LOCK.SLEEP() database procedure (Oracle only)
Using java.lang.Thread.sleep()
To use this approach, add the following line to your PeopleCode, passing a value in milliseconds which is the amount of time to sleep:
GetJavaClass("java.lang.Thread").sleep(1000);
The code above will sleep for 1000 milliseconds (1 second). Note that this approach uses up CPU cycles and has a performance hit on the application server. If you find this to be an issue, then the second approach may be better suited if you have an Oracle database.
Using DBMS_LOCK.SLEEP()
SQLExec("exec DBMS_LOCK.SLEEP(1)");
The code above will sleep for 1 second.
86.how to create a view using a PC?
87.explain diff  b/n rowinit and rowinsert?
88.how is searchinit is most often in peoplesoft application?
89.explain about hide and unhide?
90.%clientdate and %component?
91.why command push button is used and its advantages?
92.expalin arrays on PC?
93.how to refer a low level row from higher level?
94.explain the relationship b/w the classes?
95.how to change prompt table dynamically?
96.explain about on execute event?
97.where we write the PC in app packages?
98.what is the use of findin option regarding PC?
99.what is default processing?
100.what are the component level PC events?











No comments:

Post a Comment