2005 Feb 25 8:00 AM
Hello,
I need to add a line in a table (c) with data of two tables (a) (b). I have only one user-exit and it reads the data of only one table (a). I need both data of (a) (b) to add a line in (c). The user-exit is at the commit of the table (a), the commit of the table (b) comming just after.
I think to create an asynchronous function, call it in the user-exit and wait the commit of the table (b).
My user-exit is already call in an asynchronous function.
So, do you think it's dangerous to have two asynchronous function launch in the same time ? (process problem)
How would you do to wait a commit ? wait n seconds ? or there is a way to wait a commit on a table ?
Regards
Frédéric
2005 Feb 25 8:33 AM
Hi Frédéric!
You should search for different options.
Statement 'call function ... starting new task / in background' may trigger an implicit commit work -> this has to be avoided (at all costs), since later rollback work won't clear up whole transactions.
How about writing change pointers in exit for (a) and (b) - can be done without commit; only message (WE81) has to be customized, pointer activated (BD50) and CHANGE_POINTERS_CREATE_DIRECT can be used. Later you can read both entries 'asynchron' by a job.
Regards,
Christian
2005 Feb 25 8:33 AM
Hi Frédéric!
You should search for different options.
Statement 'call function ... starting new task / in background' may trigger an implicit commit work -> this has to be avoided (at all costs), since later rollback work won't clear up whole transactions.
How about writing change pointers in exit for (a) and (b) - can be done without commit; only message (WE81) has to be customized, pointer activated (BD50) and CHANGE_POINTERS_CREATE_DIRECT can be used. Later you can read both entries 'asynchron' by a job.
Regards,
Christian
2005 Feb 25 8:49 AM
Hi Christian,
Thanks for you repply,
Your solution looks very interesting, I never play with things like that. Do you know where I could find documentation ? I look in help.sap.com but I don't find a real doc.
I work in MSEG & MSEGO2 (OIL) this is not too big for this solution ?
Frédéric
Message was edited by: Frédéric Girod
2005 Feb 25 9:04 AM
Hi!
it's no problem - with appropriate server - to have 1 million change pointers per day (and jobs handling this).
Menu points for this settings are behind:
workbench - ALE - ALE development - IDOC - change service (free translated, but you should find it anyway). Documentation is linked to this key words, too.
But ALE-scenarios are much more sophisticated and have nothing to do with my process description.
Start was already described.
Your job should contain following:
FM CHANGE_POINTERS_READ
Your (a), (b), (c) handling
FM CHANGE_POINTERS_STATUS_WRITE
Daily or weekly BD22 'archiving'.
If you plan this job in higher frequency then your runtime (every 5 minutes, sometimes runtime of job is longer -> two active jobs), move ...status_write in the beginning (+ commit work) -> then second job only reads new pointers, not same again.
Regards,
Christian
2005 Feb 25 9:10 AM
Thank a lot for this answer Christian, I can stop borring SAP OSS now
Regards
Frédéric