Workfile creation

milu753001

Active Member
I want to create a workfile which will be copy of F4211
where i wil add another calculated field into workfile .
then base on this workfile i will design my report

can any one guide me for this :Iam riting the steps i should take

steps involved

1) Copy F4211 and name it as F5511 and add another Data Item in F5511 to be updated from Report varriable.
2) In a section i update the fields of F5511 from F4211(invisible section),Using update Table I/O, which going to be tedious .
Is there any bussiness function from where i can do the update.
3)Create other section based on f5511 view.
 
Prasant,

If you only need one (or even a few) extra fields, then do not copy F4211. Create a new table with the same key as F4211 (DOCO,DCTO,KCO,LNID) and add your custom fields.

This way, it is easier to update the F55xx table as you do not need to map all fields from F4211. And you can base your report on a view linking F4211 and F554211... which is then called a 'tag file'

Hope this helps

Philippe
 
your initial idea, using a table IO (Insert or update depending on whether there is already a record in F55xx) is the right one... now, when do you need to create the new information field?
Can it be done offline (in which case you could use a report, running on the scheduler, to do the job), or does the user enter the information, which gets saved in the tag file?
 
I got your idea .i have created the table F55XX which will has key field and a filed which is integral part of line number.
I creaed a view based on these table .

But how do load the field of F55XX from F4211
you have any idea? I m trying to do taht in a section of report which will be invisble.

If any other option is ther plz let me know
 
Prasant,

Could you explain what you are trying to do exactly?
If you want to calculate and store that value independently of the report printing, then you could, as I said, have a specific report for that purpose and run it on the scheduler.
Alternatively, as you said, create the main section of your report to read only F4211, and for each line (in ER 'Do Section') update the tag file F55xxx with the calculated information. Then at the end of the section (ER 'End section') call a conditional section of the report that uses the view linking F4211 and F55xxx.

Hope this helps

Philippe
 
Hi, milu

If I understand correctly what you are asking is how to populate the F55 table with F4211 values, and then how to keep the F55 table updated every time a F4211 record is inserted, or deleted, right?

To populate for the first time I guess the best solution is to create the F55 table and then ask your DBA person to copy every record Key from F4211 to your new table, or build some code yourself to read it and insert using Select All and Fetch Next loop.

To keep the F55 table updated along with F4211 you could, for example, create a Table Trigger on F4211 so that every time a record is inserted or deleted from it, you do the same with your F55 table.

Regards
 
Hi Marcelo,

Yes, the Table Trigger is the real solution
cool.gif
and I just was on to reply this, but I am really afraid, that it will be another / next "Never Ending Story"
wink.gif


Regads,

Zoltán
 
Hi Zoltan,

I know... but I can't resist the urge to help.
It's the list curse or something.
grin.gif
 
Hey

Can you give one example table ER trigger.

1)after deletion from f4211 delete from f55XX
2)Similarly for insert,update
If you have some specific coding can you send it to me
as i have worked on triggers

Where I shoud put the ER .does in F55xx?
 
HEY!

Let's milu, try to finish your never ending issue.
Currently I can not work for a 40-60 minutes, because our partner's remote terminal server had to be re-started, so I have a bit of time for you - and I hope, I will have patience enough too.

As I had read your posts and exchanged some private message, I tried to reconstruct your issue - along your 7 threads on the single issue:

blush.gif
total on Line number
blush.gif
Select and fetch next
blush.gif
Fetch next
blush.gif
Custom level break logic on line number-call a section
blush.gif
custom-level break on kine number-urgent
blush.gif
workfile creation-urgent
blush.gif
Workfile creation

Let's go...

S1.) You have a report section, based on F4211.

Am I right?

S2.) You wanted a total on line number, but based it on only the integer part.

I helped you to solve this, suggesting:
[ QUOTE ]
1.) Make your detail section invisible.
2.) Set the desired sequencing on the section and make Level Break everything in sequencing down to Line Number - including Line Number too of course.
3.) Create a Level Break Footer section on Line Number.
4.) Place aggregate Totals for Units and Price on the footer section.
5.) Place additional fields on that section, what is required for you to display on the report.

6.)In the Before Level Break event of the detail section add the following ER line:

BC Line Number (F4211) = floor([BC Line Number (F4211)])


in the assignment you have to go to the Expression Manager on the right side and select the floor function from the General category (right bottom pane).

6.) In the Do Section event of the Level Break Footer section fill the fields with the appropriate PC (Previous Column) values - exept for the total fields.


[/ QUOTE ]

Though, you have never confirmed in your original thread, whether does it work or does not.

This issue had been solved.

Am I right?

S3.) You wasn't able to fetch from F4074 to F4211 (nice, long thread
cool.gif
)

The problem was simply, that you fetched F4074 with the truncated Line Number value, as key.

Am I right?

S4.) You would like to fetch F4074 for each F4211 and accumulate a price field from F4074 on the footer section of floor(LineNumber) level break.

Am I right?
============
Now, you included into your original issue the work file creation, record insert, update, delete and table triggers.

If I understood your original issue - then forget them (for a while at least, please) and do the following.
=============

A.) Accomplish the "Before Level Break" trick, as I suggested.

B.) Define a report scope ER variable, based on LNID. Let's name it "rpt_mnLineNumberOriginal_LNID
C.) Enhance the very complicated
cool.gif
ER code in the Before Level Break event the following way:

rpt_mnLineNumberOriginal_LNID = BC Line Number (F4211)

BC Line Number (F4211) = floor([BC Line Number (F4211)])

D.) Place an appropriate numeric Report Variable (RV) for your price onto the detail section (RV Price).

E.) Modify your select in your previously published code in the Do Section event of the detail section.

IF BC Line type = 'CN"

F4074.Select
BC Document (Order No, Invoice, etc.) (F4211) = TK Document (Order No, Invoice, etc.)
BC Order Type (F4211) = TK Order Type
BC Order Company (Order Number) (F4211) = TK Order Company (Order Number)
rpt_mnLineNumberOriginal_LNID = TK Line Number
VA rpt_F4074PriceAdjustmentType = TK Price Adjustment Name
F4074.Fetch Next
RV Price <- TK Amount - Price per Unit
else
RV Price = BC Amount _extende(F4211)

F.) (as Finally
laugh.gif
) Place an aggregate Total on RV Price onto your Level Break Footer section.
====================================

At last but not least, let us know how does it work BUT PLEASE, not in an other thread again! THANKS!

Good luck,

Zoltán
 
************************
First to JDEList:
Forgive me this disappointed post. Thanks.
It seems so, I had a bad day today too
blush.gif

************************
Hi Milu,

I am hopelessly waiting for your answer
frown.gif
as I was waiting earlier, when I suggested to you the Before Lever Break trick with floor(BC LineNumber).
...while you previosly replied a lot of post immediatelly, creating new-and_new-and_new-and_new... questions.

I am really disappointed
frown.gif

...mainly because I know, you were online for a longer time after my post and I had seen, that you checked this thread, where my reply was the single, what you never checked and replied before.

I think, I had done everything, what I was able - to help you in your problem - waisting lot of time of me.

I suppose, I deserve a brief answer
blush.gif


My last suggestion was not too complicated to realize:
+1 ER variable to add
+1 ER line to add
+1 line to modify in your Select statement

Hopelessly - and may be last time (at least for you),
frown.gif
frown.gif
frown.gif
frown.gif

z...
 
Back
Top