How to split string on whitespace in Python?

CyberChants
Published on 14-Dec-2017 15:44:17
You can usesplit() from the string class. The default delimiter for this method is whitespace, i.e., when called on a string, it'll split that string at whitespace characters. For example: >>>"Please split this string".split() ['Please', 'split', 'this', 'string'] Regex can also be used to solve this problem. You can call the re.split() ... Read More

Multiple ALV grids on a single screen in SAP ABAP

vanithasree
Published on 13-Dec-2017 17:44:14
It is not possible to resize or place the grid at the particular position using function modules as ALVs are always displayed in the Fullscreen by using function modules.One of the method this can be done is that you create a screen using custom container and then use the class ... Read More

Limitation on number of columns in Visual Studio 2008

usharani
Published on 13-Dec-2017 16:24:20
This limitation is for Visual Studio. You would require writing separate queries to get different columns and combine the output by comparing common columns.

Viewing an ABAP program outside customer space.

varun
Published on 13-Dec-2017 16:21:31
The program is prefixed with “AQZZ”. This indicates that this is either created by the SAP query via transaction SQ01. You might not be able to look at the query but you can identify the Infoset on which the query relies. You can then enter the Infoset in SQ02 and ... Read More

How to delete a character from a string using python?

Rajendra Dharmkar
Published on 14-Dec-2017 15:38:30
If you want to delete a character at a certain index from the string, you can use string slicing to create a string without that character. For example, >>> s = "Hello World" >>> s[:4] + s[5:] "Hell World"But if you want to remove all occurances of a character or ... Read More

Determining values of parameters of given type on a given selection screen in SAP

varma
Published on 13-Dec-2017 15:47:35
The function module RS_SELSCREEN_INFO will provide you with the list of parameters and selection options once the report name is input. You can see full details about this FM by entering the name RS_SELSCREEN_INFO into the relevant SAP T-code like SE37 or SE80You can call this FM RS_SELSCREEN_INFO as below ... Read More

Getting age of tracefiles in SAP HANA database

usharani
Published on 13-Dec-2017 15:39:20
In SAP HANA database, you have diagnosis files include log and trace files, a mixture of other diagnosis, error, and information files.These files can be checked for diagnosis to find errors in SAP Hana database.In HANA db, you have trace files stored separated per host, so to get access to ... Read More

How to check if a string in Python is in ASCII?

Rajendra Dharmkar
Published on 14-Dec-2017 15:26:03
The simplest way is to loop over the characters of the string and check if each character is ASCII or not. exampledef is_ascii(s):     return all(ord(c) < 128 for c in s) print is_ascii('ӓmsterdӒm')OutputThis will give the output:FalseBut this method is very inefficient. A better way is to decode the ... Read More

Getting month name instead of numeric month number in report in SAP

Sreemaha
Published on 14-Dec-2017 10:48:55
There are various methods this can be donea) Use the Function module MONTH_NAME_GET - This Function module is used to return all the month and names in the respective language.b) You can also use the below formula −cstr(monthname(month({inputdate})))where “inputdate” is the date for which month name is required.c) Find the ... Read More

Use of String.compare for a varchar field in SAP

usharani
Published on 14-Dec-2017 10:43:03
Try to use SqlFunctions.DateDiff method overload which requires 3 inputs as follows −var res = from a in db.Set<table1>() where SqlFunctions.DateDiff("dd", a.Date, "20161922") >= 0 && SqlFunctions.DateDiff("dd", a.Date, "20161122") < 0 select a
Advertisements