2006 Jun 06 12:25 PM
hi all,
i want to multiply two fields, i m using multiply keyword as
MULTIPLY OBJ1 BY OBJ2.
BUT IT IS GIVING ERROR AS MULTIPLY NOT EXPECTED.
REGARDS,
YUNUS
2006 Jun 06 12:26 PM
data: f1 type i value 3,
f2 type i value 4,
f3 type i.
f3 = f1 * f2.
write : f3.
or
data: f1 type i value 3,
f2 type i value 4,
multiply f1 by f2.
write : f1.
hi all,
i want to multiply two fields, i m using multiply keyword as
MULTIPLY OBJ1 BY OBJ2.
BUT IT IS GIVING ERROR AS MULTIPLY NOT EXPECTED.
REGARDS,
YUNUS
2006 Jun 06 12:26 PM
data: f1 type i value 3,
f2 type i value 4,
f3 type i.
f3 = f1 * f2.
write : f3.
or
data: f1 type i value 3,
f2 type i value 4,
multiply f1 by f2.
write : f1.
2006 Jun 06 12:27 PM
Hi yunus,
1. Ideally it should work.
2. There might be some typing / minor mistake.
3. just copy paste and check, if this works.
4.
report abc.
data : a type i,
b type i,
c type i.
*----
a = 5.
b = 10.
multiply a by b.
write a. "---50
regards,
amit m.
2006 Jun 06 12:28 PM
Did you see if you have ended the previous statement with a period?
This works fine in my system.
Regards,
Ravi
2006 Jun 06 12:29 PM
hi
data : obj1 type i.
data : obj2 type i.
MULTIPLY OBJ1 BY OBJ2.does not give me any error..
please check your previous statements..
regards
satesh
2006 Jun 06 12:30 PM
hi,
use
OBJ1 * OBJ2.
alternatively see this eg:
DATA: DAYS_PER_YEAR TYPE P VALUE 365,
HOURS_PER_DAY TYPE F VALUE '24.0',
MINUTES_PER_YEAR TYPE I VALUE 1.
MULTIPLY MINUTES_PER_YEAR BY DAYS_PER_YEAR.
MULTIPLY MINUTES_PER_YEAR BY HOURS_PER_DAY.
MULTIPLY MINUTES_PER_YEAR BY 60.
rgds,
latheesh
Message was edited by: Latheesh Kaduthara
2006 Jun 06 12:32 PM
Hi Yunus,
REPORT test.
*
data: i type i value 10.
data: j type i value 20.
*
write: i, j.
*
multiply i by j.
*
write: i, j.
This works correct.
Which Declaration do you have for OBJ1 and OBJ2.
Regards, Dieter
2006 Jun 06 12:33 PM
Hi,
what is the <b>data type of the fields OBJ1 and OBj2</b>. MULTIPLY supports only I,P and F fields.
MULTIPLY OBJ1 BY OBJ2 is a correct statement only where OBJ1 will contained the result.
equivalent to
OBJ1 = OBJ1 * OBJ2.
Regards,
Aswin
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |