2005 Apr 13 9:21 AM
Hi all,
I'm writing a query with sq01 and sq02.
In sq02 I have some joined tables, and 2 extras fields named: "TIME" and "LEFT_ER".
in this fields I wrote a code to calculate something from fields in the tables.
The problem is:
1. When I write the code in the coding section "Additional field/structure" for each field, If I want to use this fields in the selection fields (in sq01) the query can't find any record.
But if I run this query without any selection in this fields, I get all the records, with my calculated fields.
2. I tried to write this code in the coding section "Record processing", and it seems that I can use this fields in the selection fields (in sq01), and get all the records I wanted.
But in the sq02 I get a Warning messages:
"Access error in code for additional field *GET******
*GET****** has sequence number 00
Access to LEFT_ER with sequence number 00"
In this case my field LEFT_ER has no code.
And when I change the order of the sequence number, I didn't get the Warning message, but I could not use my fields in the selection fields (in sq01), like at the beginning.
HELP ME PLEASE.
Itzhak.
Message was edited by: Itzhak Tanami
Hi all,
I'm writing a query with sq01 and sq02.
In sq02 I have some joined tables, and 2 extras fields named: "TIME" and "LEFT_ER".
in this fields I wrote a code to calculate something from fields in the tables.
The problem is:
1. When I write the code in the coding section "Additional field/structure" for each field, If I want to use this fields in the selection fields (in sq01) the query can't find any record.
But if I run this query without any selection in this fields, I get all the records, with my calculated fields.
2. I tried to write this code in the coding section "Record processing", and it seems that I can use this fields in the selection fields (in sq01), and get all the records I wanted.
But in the sq02 I get a Warning messages:
"Access error in code for additional field *GET******
*GET****** has sequence number 00
Access to LEFT_ER with sequence number 00"
In this case my field LEFT_ER has no code.
And when I change the order of the sequence number, I didn't get the Warning message, but I could not use my fields in the selection fields (in sq01), like at the beginning.
HELP ME PLEASE.
Itzhak.
Message was edited by: Itzhak Tanami
2005 Apr 13 1:51 PM
Hi,
i've an idea .
pls define your help-fields :
1) as sel-option : s_f1 for bseg-dmbtr
and
2) as calculate-field : c_f1 for bseg-dmbtr
so for event e.g. GET BSEG .
you <b>1st</b> calculate your field .
e.g.
if bseg-shkzg = 'H'.
c_f1 = Bseg-wrbtr * -1.
else.
c_f1 = Bseg-wrbtr.
endif.and 2nd your restriction from sel-screen:
<b>check c_f1 in s_f1.</b>
good luck
Andreas
2005 Apr 14 9:09 AM
sorry, I didn't anderstand your solution.
My 2 fields (TIME and LEFT_ER), are extras fields which I added them (not from the tables).
In this fields I calculate somthing from fields from the tables.
How can I use the results of the calculations in the Selection Fields?
Thanks,
Itzhak.
2005 Apr 14 10:40 AM
Hi Itzhak,
1)you can make an <b>additional select-option</b> too:
->Once again:
add an additional select-option to your field time: <b>S_TIME</b> (for bkpf-uzeit)
so for event e.g. GET BSEG .(resp. Processing your dbtab)
you 1st calculate your field .
Time = dbtab-f1 + dbtab-f2 - dbtab-f3.
and 2nd your restriction from selection-screen:
<b>check time in S_TIME.</b>
Hope you get it !
Andreas