Skip to main content

Posts

Showing posts from April, 2013

T-Code Naming convention in SAP

The T-Code also called as Transaction Code in SAP has different meaning that depends on the functionality of application and few are customized one according to requirement. There are few standard T-Codes which remains same for most of the applications. example: Standard T-Code: SE16 SM37 Customizes T-Codes like: ZR01 In the above T-Code  SE : System Engineering,  SM : System  Maintenance. The last two numbers assigned in T-Codes are assigned for editing, view, creation, display etc..

How to write data in notepad using Loadrunner script

This code will save the Vendor numbers to a notepad file. (put it in vuserinit starting after Header) //Path for saving the notepad file, the file name is "MatDocument.txt" #define filename "C:\\Documents and Settings\\ravi\\Desktop\\MatDocument.txt" f_Write(char *str1) {          long a;          a = fopen(filename,"a+");          if (a==NULL)           {             return -1;          }          else          {             fprintf(a,"Material Document Number is %s\n",str1);      ...

Load Runner code for writing data in notepad

Below code is to save the Vendor numbers to a notepad. (put it in vuserinit starting after Header) //Path for saving the notepad file, the file name is "MatDocument.txt" #define filename "C:\\Documents and Settings\\ravi\\Desktop\\MatDocument.txt" f_Write(char *str1) {           long a;           a = fopen(filename,"a+");           if (a==NULL)            {               return -1;           }           else           {               fprintf(a,"Material Document Number is %s\n",str1);             ...

How to find out Memory Leak in an application?

There are many reasons for memory leak and being a tester its tough to find exact reason. The basic thing we need to understand what is memory leak? How it occurs? Memory leak can be defined as the un-allocated space in a system which was used by a program and after  use it was never returned to the operating system. This un-allocated (unused memory) can cause shortage of memory and may crash the entire system. There are few steps which may help to find out memory leak in  a system: We can monitor the memory graph by using perfmon and check if the memory utilization is keep on increasing and remain at peak even without any load, it shows the memory that was used while executing the program is still in use even the program doesn't needs it. The un-managed code is not efficient enough to release the memory and free it after use, which may cause out of memory issue. You can check the throughput graph while load testing and if there is sudden spike in it then it can be...

How do we write a user defined function in LoadRunner?

Create the external library that contains the function. This library must then be added to the bin directory of VuGen. And then, the user-defined function can be assigned as a parameter. -Source-Internet: We need to create an external DLL libraray to use the user defiend function. It can be substitued as paramter values. The syntax is: __declspec(dllexport) char *(char *, char *) Both the arguments passed are NULL for this function. An User-defined function could be : __declspec(dllexport) char *GetSysDate(char *, char *) This would return the system date. You could substitute this returned value for a parameter instead. Once the .dll is declared In LoadRunner script you can directly use this function: lr_load_dll("mydll.dll") Then you can call the functions in the .dll directly: date = GetSysDate(char1, char2) char1 and char2 and the names of variables Note: Within a header file you can also define other user defined functions to be called within the script. This pr...

What is JVM Monitoring

It is a Java profiler integrated with Eclipse to monitor CPU, Memory usage and T hreads  of Java applications. JVM Monitor would be useful to quickly inspect Java applications without preparing any launch configuration beforehand. JVM Monitor automatically finds the running JVMs on local host and you can easily start monitoring them. It is also supported to monitor Java applications on remote host by giving hostname and port number.