Click here to load reader
Click here to load reader
Oct 23, 2014
Application Engine There are different types of variables in the Application Engine people code? Local variable these are available for the duration of the program in which they are declared. Global / Component These variables are available while the Application Engine program is running. They are saved at commits and checkpoints, So they can be used for restarts. Component variables are same as Global incase of the AE. What are the Different ways pass data between the steps? 1) State records One row can be passed and can have many state records. 2) Component/Global People code variables 3) Temporary records Multiple rows of data can be passed. What is Prerequisite for the State record? 1) Should be either Derived work record Or SQL Table. 2) Name of the record must end in AET; this is how the system identifies the record as a state record. 3) PROCESS_INSTANCE must be a key. 4) Any data types except character or numeric must required not be fields. Note: - No People code fires on an Application Engine state record. No Validation of translate values or Prompt tables are done.
How to read the runctrl parameters in AE
1) SQL: - %Select (EMPLID) Select EMPLID from PS_AERUNCONTROL where PROCESS_INSTANCE = %PROCESS_INSTANCE and ORPID = %oprid 2) People code: - &SQL = Select EMPLID from PS_AERUNCONTROL Where PROCESS_INSTACNE = | PS_TEST_AET.PROCESS_INSTANCE | and OPRID = | %oprid. %PROCESS_INSTANCE or %Bind (PROCESS_INSTANCE) can be used. %PROCESS_INSTANCE is more efficient and faster
How do you execute Application Engine through Push Button?1) CreateProcessRequest () , Schedule () 2) CallAppEngine.
What is the syntax for CallAppEngine? CallAppEngine (applid [, state record]); What are the 3 trace parameters you can pass to your psae.exe?- TRACE - TOOLSTRACESQL - TOOLSTRACEPC
Which Trace option is the best place to start for general performance information?- TRACE 384 mostly used trace value.
What is the difference between a Trace value and Trace parameters?A Trace parameter determines which type of trace is turned on. A Trace value determines what type of data is recorded in your trace files (s). Where does the trace file is written to? The trace file is written to the server directory when youve specified the trace on the client. If the client has %Temp% set to a drive or directory that does not exist on the server, PeopleSoft Application Engine does not generate a trace file. For an Application Engine program running on a server, PeopleTools writes the generic PeopleTools trace for SQL and PeopleCode trace files to the same directories as the AET traces. The prefix of the trace file name is also the same, and the suffix is trace. On the Windows workstation, the trace is written to the People Tools Trace File specified in the Trace folder of PeopleSoft Configuration Manager. What are the 3 common ways to pass a trace parameter and value to your program psae.exe? Configuration manager, Process Definition, Command prompt.
What are the Different types of Application Engine?Standard: Which is a Standard or normal entry-point program. Upgrade Only: Used by PeopleSoft Upgrade utilities only. Import Only: Used by PeopleSoft Import utilities only Daemon Only: Use for daemon type programs. Transform Only: Support for Extensible Stylesheet Language Transformations (XSLT). XSLT Transform programs. How is PSDAEMON process runed? One PSDAEMON process can run for each row in the PS_SERVERDEFN table. The PS_SERVERDEFN.DAEMONENABLED field must be set to 1.
Does system automatically modifies all static references in other programs to the renamed program? The system automatically modifies all static references in other programs to the renamed program. For instance, if you call the renamed program from another Application Engine program, the Call Section action in the calling program is modified to reflect the new program name. All sections and steps are saved under the new name. Only one occurrence of a program name can exist for a given database.What is the function that can have PeopleSoft Application Engine recompile a reused statement? Using the %Clear Cursor function. What happens if the renamed program is called in a dynamic Do action?
The reference is not automatically modified. You should also manually check and modify any embedded references to the new program name in CallAppEngine or other PeopleCode functions.
How do you program AE program for the restarts?Program Level
State Record One of the state record needs to SQL Table, Since All Derived work record will be re-initializing on commit. Program Properties On the Advanced tab in the program properties dialog box, make sure that disable restart is not checked. Configuration manager In the configuration manager, sure that Disable restart is not selected on the process scheduler tab.
Section LevelSection type The option for section type are prepare only and critical updates If the section is preparing data i,e select data, Populating temporary tables, or updating temporary tables then the section should be prepare only. If the section is updating the permanent application tables in the database, you should select critical update.
Step LevelAdd an order by clause %Select Field Select Field1 from PS_SOME_RECORD Where FIELD1 > %Bind (FIELD1) Order by FIELD1. Add a switch to the selected table Delete processed rows. The only restriction for batch runs occurs when you have restart enabled, and you are inside a Do Select that is of the Select/Fetch type (instead of "Re-select" or "Restartable"). with select/Fetch, all commits inside the loop are ignored, including the commit frequency if it's set.
Why Sections are reordered alphabetically by name?
Sections are always reordered alphabetically by name at save time to make it easier to locate a given section. However, order of execution is dependent on internal call section references, and is therefore independent of the order that sections are inserted and displayed.
What does On Error property do? The On Error property does not apply to compile errors (for example, specifying erroneous SQL statements). It checks only for execution-type errors. If your program has a syntax error, the program terminates.What is to be intend to include multiple SQL statements within a single action? Use the meta-SQL construct %EXECUTE. The previous sample SQL statement sample contains bind variables from a previous Application Engine action.
Entries in the AEREQUESTTBL table do not have any effect on Application Engine programs called from PeopleCode using the CallAppEngine function. What are the Tables Used in the Process Request Page? The Application Engine process request page inserts values into the following tables: AEREQUESTTBL. Contains all of the values that appear on the page except those in the Parameters group. AEREQUESTPARM. Includes only initial state record values specified in the Parameters group, if needed. How do you invoke an Application Engine program through the command line? Restarting. When a program abends, a system administrator might restart the program using the command line. If needed, you can locate all of the specific program and process information from Process Monitor on the Process Request Detail dialog box. Normally, users (or system administrators) perform a restart from Process Monitor. Development or Testing. Many developers include the command line in a batch file to launch a program they are developing or testing. This way, they can quickly execute the batch file as needed. This also enables separation of development of the application program from its associated pages. Debugging. To debug a program running on the server, you can sign into the server (using telnet, for example) and invoke the program from the command line. What are the Bulk Inserts ignored? Bulk Insert is also ignored when all three of the following conditions are true: the database platform is Oracle, the record contains and EFFDT field (effective date), and the record contains a mobile trigger. This is required because an Oracle database does not allow the reading of mutating tables in a row trigger. What is another way to populate PS_MESSAGE_LOG instead of Log Message action? You can also use MessageBox PeopleCode to populate PS_MESSAGE_LOG instead of using the Log Message action. This enables you to easily record errors encountered within Application Engine PeopleCode programs.
What happens is if an Application Engine program is not set up for restartability? When an Application Engine program is not set up for restartability, then commits are not controlled, monitored, or restricted by PeopleSoft Application
Engine. When Restart is disabled, commits are controlled by the program.PeopleSoft Application Engine does not commit a step containing a Do Select action with the Select/Fetch option enabled until the entire step completes successfully, regardless of the other options you have selected.
What is Set Processing? Set Processing uses SQL to process groups, or sets, of rows at one time rather than processing each row individually. With row-by-row processing you following a repetitive loop that selects a row, determines if it meets a given criteria, if so, apply rule x to row Update row, commit. With set processing, you only select those rows that meet the filtering criteria and then run the rule once again all the affected rows. Advantages of Set Processing?Improved Performance: - Our internal testing has revealed that, in an overwhelming majority of cases, set processing performs significantly better than it is -by-row counterpart for reasonable batch processing volumes. Minimized SQL Overhead: - It tends to use fewer Application Engine SQL statements that each processed more data than the statements executed in row-by-row processing. Easy Maintenance: - If ne