Ramu Prasad has Published 74 Articles

Creating SAP interface to pull data from web application

Ramu Prasad

Ramu Prasad

Updated on 11-Dec-2019 06:47:01

382 Views

Web Dynpro is a complex framework and it would be tough to integrate it to your Java application. You can use SAP Java Connector JCo. SAP Java Connector can be used to call Remote Function calls on SAP system.You can use already defined function modules to connect. You can take ... Read More

How to have a structure with a table in ABAP?

Ramu Prasad

Ramu Prasad

Updated on 10-Dec-2019 10:22:03

1K+ Views

The basic rule while specifying a table within a structure is that you have to give a non-unique constraint to that field.TYPES: myType TYPE TABLE OF string WITH NON-UNIQUE DEFAULT KEYThen use this in the structure definition:TYPES: BEGIN OF ty_itab, ….. myTable type myType, …….. TYPES: END OF ty_itab.Read More

Converting a file into a byte array in SAP ABAP

Ramu Prasad

Ramu Prasad

Updated on 05-Dec-2019 07:49:09

558 Views

Here is a code snippet to do the same.data: f_line type xstring.               // to get line by line content data: f_file type table of xstring.      // to get the final content data: f_filename type string value 'samplefile.txt'.   // store the ... Read More

What are the differences between struct and class in C++?

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:22

225 Views

The members and base classes of a struct are public by default, while in class, they default to private. Struct and class are otherwise functionally equivalent.They are however used in different places due to semantics. a struct is more like a data structure that is used to represent data. class, ... Read More

Java string comparison sample code examples

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:21

74 Views

We can compare Strings in Java using the compareTo() method and the == operator.comapareTo() method: The compareTo() method compares two strings lexicographically. The comparison is based on the Unicode value of each character in the strings. The character sequence represented by this String object is compared lexicographically to the character sequence ... Read More

Can a Vector contain heterogeneous objects in Java?

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:21

727 Views

Since a vector stores elements in the form of objects, you can store objects of various types (heterogeneous) in it.Example:import java.util.*; class Demo{} public class VectorSample {    public static void main(String args[]) {       Demo obj = new Demo();       Vector v = new ... Read More

What does the method getLast() do in java?

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:21

68 Views

The getLast() method of the class java.util.LinkedList returns the last element in this list.Example:import java.util.*; public class LinkedListDemo {    public static void main(String[] args) {       LinkedList list = new LinkedList();       list.add("Hello");       list.add(2);       list.add("Chocolate");       list.add("10"); ... Read More

How to replace characters on String in Java?

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:21

191 Views

The replace method of the String class accepts two characters and it replaces all the occurrences of oldChar in this string with newChar.Example Live Demoimport java.io.*; public class Test {    public static void main(String args[]) {       String Str = new String("Welcome to Tutorialspoint.com");       System.out.print("Return ... Read More

Single level inheritance in Java

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:21

11K+ Views

Single Level inheritance - A class inherits properties from a single class. For example, Class B inherits Class A.Example Live Democlass Shape {    public void display() {       System.out.println("Inside display");    } } class Rectangle extends Shape {    public void area() {       System.out.println("Inside area"); ... Read More

Copying ALV layout from one client to another in SAP if they are not user specific

Ramu Prasad

Ramu Prasad

Updated on 30-Jul-2019 22:30:20

471 Views

You can transport your ALV layouts to other system if they are not user specific. This can be performed in Layout Administration by raising a customizing request.Navigate to this path for Layout Administration:Main Menu -> Settings -> Layout -> Administration

Advertisements