How to get number of digits in given amount
Hi Experts,
How to get number of digits in given amount.
Regards
Mohit
Check this :
data: v_data1 type p decimals 3 value '12.860',
v_char1 type char20,
v_char2 type char20,
v_char3 type char20,
len type i.
write v_data1 to v_char1.
split v_char1 at '.' into v_char2 v_char3.
len = strlen( v_char3 ).
write:/ v_char2,
/ v_char3, " this holds the digit value
/ len. " number digits
Similar Messages
-
How to get number of rows return in SELECT query
i'm very new in java, i have a question:
- How to get number of rows return in SELECT query?
(i use SQL Server 2000 Driver for JDBC and everything are done, i only want to know problems above)
Thanks.make the result set scroll insensitve, do rs.last(), get the row num, and call rs.beforeFirst(), then you can process the result set like you currently do.
String sql = "select * from testing";
PreparedStatement ps =
con.prepareStatement(sql,ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY);
ResultSet rs = ps.executeQuery();
rs.last();
System.out.println("Row count = " + rs.getRow());
rs.beforeFirst();~Tim
NOTE: Ugly, but does the trick. -
How to get temperature from digital camera in to controller
how to get temperature from digital camera in polarising microscope using t95 controller without adc.dll
Ask the manufacturer of your camera…
What kind of answer do you expect? -
How i get number of record in repet frame?
Hi,
How i get number of record in repet frame?
Regards
JomarJomar,
you can use Summary Columns in the Data Modell. Create them on group higher that your wished group (so on the pane for an first group of a query), use as Source the primary column and as reset at the group, where the summary column is located.
If you hide some instances via format triggers, that you could use a counter inside the format triggers to count the rows.
Regards
Rainer -
How to get the split period wage type amount in payslip?
How to get the split period wage type amount in payslip?
Payroll period for 01.01.09 to 31.01.09.
1. Employee is active from 1.1.09 to 10.01.09
2. Employee is inactive from 11.01.09 to 20.01.09
3. Employee is again active from 21.01.09 to 31.01.09
In Result Table three split periods are created.
From 01.01.09 to 10.01.09 u2018Basic Salaryu2019 Wtype 1101 amt is 20.00
From 11.01.09 to 20.01.09 u2018Basic Salaryu2019 Wtype 1101 amt is 00.00
From 21.01.09 to 31.01.09 u2018Basic Salaryu2019 Wtype 1101 amt is 10.00
My requirement is to print only the last split period in payslip from 21.01.09 to 31.01.09. May you please help me in this regard.
Thanks in advance
Regards,
Rajesh.Hi
Try to read the below:
WPBPC : Distribute Lump Sum Wage Elements to WPBP Periods
Object
Operation
Use
Operation WPBPC distributes the amount of the current wage type to the
active WPBP periods in the payroll period.
Input
The current wage type in the header entry of table OT is used as input
for this operation.
Procedure
Within payroll, wage types are assigned to a fixed WPBP period by
infotype 0014 Recurring Payments/Deductions, for example. However, you
may want to distribute this payment to all active WPBP periods, which is
what would happen if the wage type were entered in basic pay. Therefore,
various specifications exist for parameter S:
o If the specification is 'A', and if several active WPBP periods
exist, the amount is simultaneously reduced on a calendar-day basis.
o If the specification is 'D', the wage type is distributed to all
existing WPBP periods without the amount being reduced.
o If the specification is 'S', and if the validity period starts or
ends during the period, the entry in table WPBP is split using this
date. The wage type is stored in table OT for the corresponding WPBP
period.
This parameter is only allowed if processing was accessed using
function P0014.
In this case, infotype 0014 must be processed before absence
valuation and function PARTT. Otherwise, rejections occur during
payroll processing.
o Specification 'X' is the combination of 'A' and 'S'.
This parameter is only allowed if processing was accessed using
function P0014.
o If the specification is 'W', and if the validity period starts or
ends during the period, the entry in table WPBP is split using this
date (as with option 'S'). Unlike 'S', the wage type is not stored
in table OT.
This parameter is only allowed if processing was accessed using
function P0014.
o If the specification is ' ', the wage type is stored in table OT for
each WPBP period in which the validity interval fits.
This parameter is only allowed if processing was accessed using
functions P0014 or P0015.
If the WPBP split is set for a wage type, the wage type is stored
without changes in table OT. If you specify a different wage type name
in the second parameter, the wage type is stored with this name in table
OT. Before you execute operation WPBPC, you may therefore need to delete
the split using operation ELIMI.
If a country-specific split (C1, C2, or C3 split) is set, the operation
interprets it as an error. The employee in question is rejected by
payroll. All other splits are transferred as they are.
Output
The processed wage type, or the wage type specified in the operation
call, is written to table OT (output table) with the appropriate split
indicator and reduced amount as operation output for each WPBP period.
Parameter specification 'W' is the only exception.
Syntax
OOOOOSVVVV
OOOOO WPBPC Operation name
S
blank distribute to all WPBP periods
S split and distribute WPBP
W split but do not distribute WPBP
A distribute to active WPBP periods
with calendar-day reductions
D distribute to all existing
WPBP periods
X combination of 'S' and 'A'
VVVV Results wage type
blank input wage type = results wage type
wage wage type name of input wage type is replaced
type by wage type name of results wage
name type
Wage type before operation:
Example
M100 02 3000
WPBP split
01 June 01 - June 20 active
02 June 21 - June 30 active
VVVV Results wage type
blank input wage type = results wage type
wage wage type name of input wage type is replaced
type by wage type name of results wage
name type
Wage type before operation:
Example
M100 02 3000
WPBP split
01 June 01 - June 20 active
02 June 21 - June 30 active
Wage type before operation:
WType WPBP Amount
M100 00 3000.-
M200 02 2000.-
Operation: WPBPCA
Wage type after operation:
WType WPBP Amount
M100 01 2000.-
M100 02 1000.-
M200 02 2000.-
Operation: WPBPC
Wage type after operation:
WType WPBP Amount
M100 01 3000.-
M100 02 3000.-
M200 02 2000.-
Regards
Team Member. -
How to read number of digits in a given decimal number by using abap
Hi ,
How can we read the number of digits present in a decimal number , just before decimal.
For example: I have this number - 200.00
Now I want to read how many digits are present in this number before decimal ( . ) point. so in this case the number of digits are 3( 200). Similarly if we have a number 15.00, in this case number of digits is 2 ( 15 ) before decimal point.
How can i acheive this by using abap.
Regards
PGHi
There are differenent logics available.The previous reply was really good. get another way also.
Data: v_dec type p decimals 3,
v_temp type char20,
v1 type char10,
v2 type char10,
v_len type i.
v_temp = v_dec.
split v_dec at '.' into v1 v2 .
condense v1 no-gaps.
len = strlen( v1 ).
Regards,
Chellamma Chandrasekar. -
How to get net price of a given material(Just like in VA01)
Hello Experts,
How do I get the net price of a given material? Just like when entering a
material in VA01(sales order creation). Hope you can help me guys.
Thank you and take care!This is a million dollar question.
It depends on how the pricing have been configured in your system and only your SD consultant can answer it correctly. Price in VA01 could be determined by using the pricing conditions or, if allowed, a manual user entry (i.e. when users just type in the price). Discounts, taxes, etc. are calculated in a similar way, also based on the configuration.
Pricing conditions are displayed in transaction VK13. You might want to take a look at an order in VA03 -> double-click on a line and go to Conditions tab. There are buttons Analysis and Condition Rec. that might be useful for your research. It is possible to configure different price for the same material and different customer, distribution channel, etc., so you will have to ask your SD consultant how to get the correct number in each case.
Just FYI the net price on the order/contract is in VBAP-NETWR and condition are stored in the tables Annn, e.g. A901, etc. The tables are generated according to the configuration and are different in each system. -
How to get number of rows in tableview
Hello,
Could anybody help me on how to get the number of rows in a tableview? Sort of using DESCRIBE TABLE in classic ABAP.
Thanks,
RickyThere is an attribute of the class CL_HTMLB_TABLEVIEW named
ROWCOUNT.
Inside an event u need to get this info use this code:
Replace 'Monitor' for the ID of your tableview
DATA: tv TYPE REF TO CL_HTMLB_TABLEVIEW,
r_count type i,
tv ?= CL_HTMLB_MANAGER=>GET_DATA(
request = runtime->server->request
name = 'tableView'
id = 'Monitor' ).
IF tv IS NOT INITIAL.
DATA: tv_data TYPE REF TO CL_HTMLB_EVENT_TABLEVIEW.
tv_data = tv->data.
r_count = tv_data->rowcount.
ENDIF. -
How to get number of pages in word document
I am developing an OCR application where I need to get number of pages of word documents. I am currently assuming that each page consists of 46 lines but some how, I am not getting convinced with this logic. Is there any simplest way to get this information?
Let me tell you that in the OCR system I am converting tiff iamges to .txt file and again reading txt file and counting number of pages based on number of lines.
regards,
RanjanThe number of pages depends on the font size, length of each line and any page break in between.
You could just say, one page per 46 lines, it depends on how accurate you must be.
Why not count the number of pages you scanned? -
How to get number or size of selected messages
Hey all
Does anyone know how to get the number or the total size of a selected set of messages in Mail/10.8? I'm in the process of copying mail to an IMAP folder and want to get a general idea of how much stuff I'm sending before I do it.
Thanks!
MattThanks Leroy. That's what I was afraid of. It shows the size/quantity in IMAP folders, but not local folders. I would love a "status bar" as in the Finder, where it tells me how many messages I have selected ... one for the feedback form, I think.
best
Matt -
How to get an non digital License?
Hi,
I want t install a License for the Solution Manager. The System is out of time, so that I can only use saplicense.exe to install this. But in the file, that I have recieved from SAP is only the digital key and that can I not install in that case. Does somebody know, how to install this file or how to get the other key?
Thanks,
PeterThanks, but the Solution Manager-"Server" doesn't start complete. Before the license was out of time, the "Server" starts normal. So I think, that I can not access via SAP GUI. I haven't test it.
I will do this tomorrow, but when this solution not solve the problem, what can I do?
Greets,
Peter -
ALV_GRID How to get number of lines after filted applyed?
Hi, all!
The task is to display title in alv_grid like
"N records selected (X records on the screen)".
It means, N records in dataset and X records displayed after filter applyed by user.
But i can't get number of lines after filter applyed from the alv_grid.
Can anybody help me?
Thanks & regards,
KonstantinHi,
If it goes through PBO/PAI cycle after user sets the filter then in your PBO call method get_filtered_entries of CL_GUI_ALV_GRID and then do a describe statement on the table.
Number of entries in your grid table - number of entries in this filtered entries table will give you the displayed entries after the filter is set.
If it does not go through PBO/PAI cycle then register for after_user_command and I think the fcode for filter is '&FILTER' and code for the above logic in your handler method..
Hope this helps..
Sri -
How to get number of rows and columns in a two dimensional array ?
Hello,
What would be the simplest way to get number of rows and columns in a two dimensional array represented as integers ?
I'm looking for another solution as For...Each loop in case of large arrays.
Regards,
PetriHi Petri,
See a attached txt file for obtaining two arrays with upper and lower index values
Regards
Ray
Regards
Ray Farmer
Attachments:
Get2DArrayIndex.txt 2 KB -
How to get Number of Column in Excel file
Hi All,
My requirment is to get Number of Column in Excel file which i want to upload,
so please suggest if there is any possible way to get this functionality.
Thanks
AnirudhUse FM "ALSM_EXCEL_TO_INTERNAL_TABLE".
Adjust the values of i_begin_col & i_end_col parameters in this FM.
CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
EXPORTING
FILENAME =
I_BEGIN_COL =
I_BEGIN_ROW =
I_END_COL =
I_END_ROW =
TABLES
INTERN =
EXCEPTIONS
INCONSISTENT_PARAMETERS = 1
UPLOAD_OLE = 2
OTHERS = 3
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Regards,
BBR. -
How to get the top most community given a sub community ID
Hi,
I have developed a custom navigation scheme with top level communities as top nav and the sub communities of the top level communities in the left nav.
Now when the user selects a particular sub community in the left nav the top level community in the top nav should be highlighted.
I am able to get the first level parent community of the current community but not able to recursively reach the top most community.
I have tried the following piece of code
IPTCommunityManager ptOM = (IPTCommunityManager) ptMgr.GetInterfaces("IPTCommunityManager");
IPTCommunityInfo ptCommunityInfo = ptOM.CachedOpenCommunityInfo(communityID ,true);
IPTQueryResult result = ptCommunityInfo.GetParentCommunity() ;
I dont know how to get the communityID from result
Any pointers in this regards will be very helpful
ThanksTo get community ID from the result just use this code:
int nCommID = result.ItemAsInt(0, PT_PROPIDS.PT_PROPID_OBJECTID);
The NavigationModel class in portalpages project has a wealth of code dealing with these types of tasks. Look around there if you don't know how to code something, it is a good source for examples.
You would then get the CommunityInfo object for the parent community ID and call GetParentCommunity again until you reach the top. The IPTCommunityInfo objects are cached so the performance will not be too bad.
Maybe you are looking for
-
AIA FP 11.1.1.4 install problem
Hi, Currently I try to setup some POC application. First of all I would need a working AIA FP installation. I tried to install every component to my windows 7 box, but the AIA installer gives me some errors. I'm going to give some details about the s
-
Muse; Business Catalyst; Ecommerce. Need input!
HEY EVERYBODY! Alrighty then. Here's the situation. Working in Muse, doing quite a few sites with it. Great stuff. Also a Business Catalyst Partner (Branding level soon! Woot!) Let me get this out of the way first: I'm not a code expert. Hence the re
-
Link properties except setAction
Hi all, In Javascript is there any other possibility to add an action (for goto page view, goto named destination) except "setAction()" Thanks, Christober
-
My theory on why the 1.0.1 update won't work for some...
Ok, I've racked my brain and this is the only thing I could come up w/ because I'm following the instructions to a tee. I took a closer look @ the Firmware Update page and noticed this: "It now runs on localized systems that use languages that read r
-
Is it worth buying the old Mac pro now, for iOS dev and designing?
I want to replace my old Macbook Pro unibody 2008 late model, and buy something instead of that. Currently it has 8gb ram, an SSD drive, but it's getting slower and slower. I want to replace it with something, and if I don't have to I won't spend ~30