2010 Feb 12 4:40 PM
Hello everyone
I am using BAPISDORDER_GETDETAILEDLIST to retrieve the sales order data. It is generally working fine.
BUT, when some one is changing a sales order and I am using the BAPISDORDER_GETDETAILEDLIST to retrieve the data, I am getting the old data not the one that has just been saved.
I need to wait several seconds (20 to 30 seconds) to have the updated data.
Is there any way to specify to BAPISDORDER_GETDETAILEDLIST to take the latest information?
That problem doesn't exist when using tcode va02. If some one is making a change and someone else is using tcode va02 right a way after the save, the data is correct.
Any suggestions?
Regards
dstj
2010 Feb 13 4:09 AM
Hi,
Sometimes it's really a good idea to have a look at BAPI interface as well as code. That BAPI has a parameter I_MEMORY_READ. Here is also a comment from the beginning of BAPI.
* Werte für I_MEMORY_READ:
* SPACE = zuerst Pufferzugriff, dann DB-Zugriff
* 'A' = nur Datenbankzugriff
* 'B' = nur Pufferzugriff
It's not that hard to guess what it does mean even if you don't speak German. By default BAPI uses cache and then DB.
Cheers
2010 Feb 15 7:02 PM
Hello Martin
The parameter I_MEMORY_READ is an optional one.
Even than, if we are assigning it to space, as mentioned, that doesn't change the result.
Based on my understanding, SPACE is refering first to memory then DB.
We are still facing delay between the sales order save ending process and the result of the BAPI.
I was wondering if there were a problem with the BAPI.
Regards
dstj
2010 Feb 15 10:40 PM
Hi,
no, it's written in that comment.
SPACE = zuerst Pufferzugriff, dann DB-Zugriff
this line means SPACE = first buffer, then DB. So you need to set it to A if you don't want to use buffer. I don't understand your comment regarding optional. This parameter can be used to modify behavior of this BAPI. As it's written in the comment by default it goes to buffer first (which makes sense).
Cheers
2010 Feb 16 5:22 PM
Hello Martin
Based on your comment, I am probably misunderstanding the values.
Please confirm if I understand properly or not.
SPACE = First look if the latest information is already in the buffer, if there is nothing in the buffer look to the DB
A = Look into the DB only. So if the latest information is in buffer, because the update is not yet processed, the DB is containing old data
B = Look only in the buffer. Return nothing if there are no data in the buffer.
Is my undestanding is right?
Regards
dstj
2010 Feb 16 10:16 PM
Hi,
it should be as you stated but I haven't tested it.
Cheers
2010 Feb 17 2:48 PM
Hello Martin
If I am right, I tested with the parameter I_MEMORY_READ = ' ' and it doesn't work like I expected.
Even if the data is in the buffer, it seams not to return the latest information.
I will have to test with the other parameters.
I let you know my result.
Regards
dstj
2010 Feb 17 10:31 PM
Hi,
just small comment. Omitting parameter I_MEMORY_READ and setting I_MEMORY_READ to blank is equal. You need to test it with I_MEMORY_READ = 'A'.
Cheers
2010 Dec 27 2:01 PM
Hello, Daniel.
You is right!
For parameter I_MEMORY_READ:
SPACE = first access buffer, after access SD tables in DB
A = access only tables in the DB
B = access only tables in the buffer