OBJNR is blank at VBAK and VBAP tables
Dear collegues,
There´s a strange situation on customer´s system. When end-user create a new quotation, the OBJNR field at VBAK and VBAP tables doesn´t fill itself, it remains blank. I believed that the field was filled when the document was saved. What´s wrong?
Regards, Otávio.
Hi,
This might be due to many reasons.Please check if there any dumps related to it in ST22/SM21.
Also check if there any enough dialog/bckg work process to process the job.
filling up takes more time depending on the no of records in the application tables.
regards
Nagaraju
Similar Messages
-
Performance problems selecting form vbak and vbap
Hello,
I am try to select data from the vbak and vbap databasetables. The tables have more than a million of entries. I tried my best with two related selectstatements and the 'FOR All ENTRIES' syntax. The query takes more than 30 minutes. Is there a more efficient way than the following query, for example an inner join?. Tanks.
Regards, Lars.
FORM firstselect.
SELECT kvkorg kvtweg kspart kauart k~kunnr
kvsbed kaugru kvbeln kmandt
FROM VBAK AS k
INTO CORRESPONDING FIELDS OF TABLE t_outtab1
WHERE k~vkorg IN s_vkorg AND
k~vtweg IN s_vtweg AND
k~spart IN s_spart AND
k~auart IN s_auart AND
k~kunnr IN s_kunnr AND
k~vsbed IN s_vsbed AND
k~augru IN s_augru AND
k~vbeln IN s_vbeln.
ENDFORM.
FORM secondselect.
SELECT pposnr pvstel p~werks
pabgru pmatnr p~kwmeng
pzzurmeng pvrkme pmandt pvbeln
FROM VBAP AS p
INTO CORRESPONDING FIELDS OF TABLE t_outtab2
FOR ALL ENTRIES IN t_outtab1
WHERE
p~vstel IN s_vstel AND
p~werks IN s_werks AND
p~matnr IN s_matnr AND
p~abgru IN s_abgru AND
t_outtab1-mandt = p~mandt AND
p~vbeln = t_outtab1-vbeln.
ENDFORM.FORM firstselect.
SELECT vkorg
vtweg
spart
auart
kunnr
vsbed
augru
vbeln
mandt
FROM VBAK
INTO TABLE t_outtab1
WHERE vkorg IN s_vkorg AND
vtweg IN s_vtweg AND
spart IN s_spart AND
auart IN s_auart AND
kunnr IN s_kunnr AND
vsbed IN s_vsbed AND
augru IN s_augru AND
vbeln IN s_vbeln.
ENDFORM.
FORM secondselect.
SELECT posnr
vstel
werks
abgru
matnr
kwmeng
zzurmeng
vrkme
mandt
vbeln
FROM VBAP TABLE t_outtab2
FOR ALL ENTRIES IN t_outtab1
WHERE vbeln = t_outtab1-vbeln
AND vstel IN s_vstel AND
werks IN s_werks AND
matnr IN s_matnr AND
abgru IN s_abgru .
ENDFORM.
Hope this helps u.
I will get u back with more answers.
One more important thing see that the order which u r using in the select query is the same as that in the table this will affect the performs a lot.
<i><b>The first field should be the vbeln and then see the order and change that first and the same order should be in the internal table taht u r defining also.
If u do these things surely u can improve performance.</b></i>
Message was edited by: Judith Jessie Selvi -
Contract Sign Date from VBAK and VBAP and VEDA.
Hi ,
I need to fetch the Sales Document from VBAK and VBAP and VEDA with the contract sign date for sales document line item .
Contract sign date is in selection screen as select options.
Please let me know how to fetch the sales Document per line item from these 3 tables considering that A sales document could have many line items and each can have a different sign date.
Thanks
SachinHi,
The link between all the tables VBAK, VBAP and VEDA is VBELN i.e sales document number.
However, while fetching from VBAP and VEDA you would need to consider POSNR as well.
As your ABAPer to code the logic using 'for all entries' method.
Regards,
Amit
Edited by: Amit Iyer on Jun 23, 2011 12:28 PM -
Link between Prps and Vbap table
Hi all,
How can i link PRPS and VBAP table .
Please suggest.
Thanks and regrads
Neha Kapoorhi,
neha try this.
PRPS-PSPNR = VBAP-PS_PSP_PNR
rgds
anver -
Help needed for report on tables vbak and vbap
Hello,
I needed help in one of my work issues, this is my first project and Iam still learning. kindly help.
I was asked to take erdat,vbeln,posnr from selection screen and compare it with the data already in tables vbap,vbak. If the data
already exists and exception needs to be raised saying that the 'data exists',but if the data is not present in the tables the
tables have to be updated. This has to be done using function module only.
Then I have to write a REPORT calling the above function module and finally displaying the number of records updated and the
list of them.
I have started writing a function module:
FUNCTION z_tableupdate.
""Local Interface:
*" IMPORTING
*" VALUE(DATE) LIKE VBAK-ERDAT DEFAULT SY-DATUM
*" VALUE(SALESORDERNO) LIKE VBAK-VBELN
*" VALUE(ITEMNO) LIKE VBAP-POSNR
*" EXPORTING
*" VALUE(EX_VBAP) LIKE VBAP STRUCTURE VBAP
*" VALUE(SYS) LIKE SY-SYSID
*" VALUE(EX_VBAK) LIKE VBAK STRUCTURE VBAK
*" EXCEPTIONS
*" DATA_UPDATED
*" DATA_EXISTS
SELECT * FROM vbak INTO vbak_wa WHERE erdat = date
AND vbeln = salesorderno.
ENDSELECT.
SELECT * FROM vbap INTO vbap_wa WHERE posnr = itemno.
ENDSELECT.
IF sy-subrc EQ 0.
ex_vbap = vbap_wa.
ex_vbak = vbak_wa.
ELSE.
RAISE data_exists.
ENDIF.
sys = sy-sysid.
ENDFUNCTION.
How is the above code for function module, will this work??
Now can I write a report to call the above function module and update the record?? if so, how to update ??? please help...Lots of thanks in advance.Hi
Welcome to SDN forum
Whay can't you write a simple report in SE38.
why you are using Fun module
Nothing wrong in it.
But first become perfetc in reports in SE38 and then do using the fun modules
write a simple select statement like
SELECT AVBELN AERDAT BPOSNR BMATNR
INTO TABLE ITAB
FROM VBAK AS A JOIN VBAP ON
AVBELN = BVBELN
WHERE A~VBELN IN S_VBELN AND
A~ERDAT IN S_ERDAT AND
B~POSNR IN S_POSNR.
IF SY-SUBRC <> O.
WRITE: / 'No data found'.
ENDIF.
First write this in SE38 by defining a proper selection screen and internal tables
then do as fun module
see the doc for fun module
Function Modules;
Check this matter.
Function Modules are Global ABAP programs created by SAP for reusable purpose.they have IMPORT,EXPORT and TABLE parameters, and EXCEPTIONS to through when error occurs.
You can create them from TCode SE37.
Go through the following doc:
Function modules are cross-program, reusable procedures that are organized into function groups, and whose functions are implemented between the statements FUNCTION and ENDFUNCTION. Function modules and their interfaces are created in the Function Builder.
Function Module Interfaces
The parameter interface of a function module is defined in the Function Builder. It includes the definition of interface parameters and the specification of exceptions that can be triggered by a function module. The Function Builder automatically generates comment lines below the FUNCTION statement in the source code of the function module, which represent the interface of the function module with the following syntax:
Syntax
... [IMPORTING parameters]
[EXPORTING parameters]
[CHANGING parameters]
[TABLES table_parameters]
[{RAISING|EXCEPTIONS} exc1 exc2 ...]
The syntax and semantics of IMPORTING, EXPORTING, CHANGING, RAISING, and EXCEPTIONS mainly correspond to the definition of method interfaces with [CLASS-]METHODS. The additional option of defining table parameters using TABLES is obsolete.
Interface parameters
The interface parameters are defined on the relevant tab pages in the Function Builder.
IMPORTING parameters are input parameters. When the function module is called, a suitable actual parameter must be specified for every non-optional input parameter. The content of the actual parameter is passed to the input parameter when the call is made. The content of an input parameter for which 'pass by reference' is defined cannot be changed in the function module.
EXPORTING parameters are output parameters. When the function module is called, a suitable actual parameter can be specified for every output parameter. The content of an output parameter that is defined for 'pass by value' is transferred to the actual parameter if the function module is completed without errors. An output parameter that is defined for pass by reference is not initialized when the function module is called.
CHANGING parameters are input and output parameters. When the function module is called, a suitable actual parameter must be specified for every non-optional input or output parameter. When the function module is called, the content of the actual parameter is passed to the input/output parameter, and when the function module is completed, the content of the input/output parameter is passed to the actual parameter.
TABLES parameters are table parameters. Table parameters are obsolete CHANGING parameters that are typed as standard tables with a header line. If an internal table without a header line or a table body is passed as an actual parameter to a formal parameter of this type, an empty local header line is generated in the function module. If an internal table with a header line is used as an actual parameter, both the table body and the header line are passed to the function module. Pass by value is not possible in formal parameters defined using TABLES. Formal parameters defined with TABLES can be replaced by formal parameters defined with CHANGING. A local work area can be created for the internal table in the function module by using the addition LIKE LINE OF itab of the DATA statement.
Exceptions
The exception of a function module are defined on the Exceptions tab page in the Function Builder. Here you can select exception classes to define whether class-based exceptions are declared or non-class-based exception are defined. Class-based exceptions are represented in the above syntax by RAISING, and non-class-based exceptions are represented by EXCEPTIONS.
The addition RAISING is used to declare class-based exceptions that can be propagated from the function module to the caller. Exceptions in the categories CX_STATIC_CHECK and CX_DYNAMIC_CHECK must be explicitly declared, otherwise a propagation can lead to an interface violation. A violation of the interface leads to the treatable exception CX_SY_NO_HANDLER. Exceptions of the category CX_NO_CHECK are implicitly always declared. The declaration of exceptions of the category CX_STATIC_CHECK is statically checked in the syntax check. For exceptions of the category CX_DYNAMIC_CHECK, the check is not performed until runtime. In a function module in which class-based exceptions are declared with the RAISING addition, the statement CATCH SYSTEM-EXCEPTIONS cannot be used. Instead, the relevant treatable exceptions should be handled in a TRY control structure.
The addition EXCEPTIONS is used to define a list of non-class-based exceptions that can be triggered in the function module using the statements RAISE or MESSAGE RAISING. Exceptions defined in this way - as with formal parameters - are bound to the function module and cannot be propagated. If an exception of this type is triggered in a function module, and no return value has been assigned to it with the homonymous addition EXCEPTIONS of the CALL FUNCTION statement when the call was made, this leads to a runtime error.
Note
For new developments after release 6.10, SAP recommends that you work with class-based exceptions that are independent of the function module.
RFC is a technology which is used to access a functions (Modules) from
the remote systems.
If a function module is set as remote enabled which can be access from
the remote system via RFC.Eg: U can access the Remote enabled function modules in ur VB,Webdynpro,Java,Visual composer program.
A function module can be set as remote enabled by SE37->Go to ur FM->click the option Button "remote enabled".
But Normal function modules can not accessd from the remote system.
Good Example for RFC enabled function module is : BAPI(Business Application Programming Interface)
Note: All BAPIs are Remote enabled but not all remote enabled function modules are BAPI.
CALLING A FUNCTION MODULE:
1)In U ABAP Editor --> Click "Patter" ---> Selection Option Button "Call Function"
--> Write the Corresponding FM name --> Hit Enter
2)The appropriate import ,export Parameters will be displayed in ur editor
3)Pass the Values Here.
Also check these links.
http://www.geocities.com/victorav15/sapr3/abapfun.html
Check this link:
http://help.sap.com/saphelp_erp2004/helpdata/en/9f/db988735c111d1829f0000e829fbfe/content.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/ef/d94b78ebf811d295b100a0c94260a5/frameset.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/43/41341147041806e10000000a1553f6/frameset.htm
Check this link:
http://help.sap.com/saphelp_erp2004/helpdata/en/9f/db988735c111d1829f0000e829fbfe/content.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/ef/d94b78ebf811d295b100a0c94260a5/frameset.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/43/41341147041806e10000000a1553f6/frameset.htm
See the following links:
http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db970e35c111d1829f0000e829fbfe/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/26/64f623fa8911d386e70000e82011b8/content.htm
Regards
Anji -
Hi there!
When i want to extract data ,partly related to header and partly related to item , what i do is, i give the conditions(header conditions like sales org.) for which i need data in VBAK and when i get the sales order numbers i exceute VBAP for these sales order to get item data....is this the correct way or is there a way to get the header as well as item data from the same table....Please suggest....Dear Swetha,
If you want to pull data from a single table use T-code: SE16N.
If you want to join multiple Tables then create a Query thrrough SQ00. You can select the required feild in this Query & generate a report based on required selection criteria..
Hope this Helps..
Thanks,
Jignesh Mehta -
How to link vbak and vbrp tables
hi friends,
i want to display lips table values based on lips-vbeln = it_vbrp-vgbel
here i want a filed thru which i can link vbrp-<fieldname> to vbak/vbap-vbeln
so that i can get values into it_vbrp.
here is equation.
it_vbrp => vbak-vbeln = vbrp-< ? >
it_lips => vbrp-vgbel = lips-vbeln.
thanks in advance for your co operation
regards,
Anil kumar pu can reach vbrp vbeln from vbrk vbeln
and to get vbrk vbeln from vbak vbeln
goto table VBFA
1.
GIVE VBFA-VBELV = VBAK-VBELN
and
VBFA-VBTYP_N = 'M'. "INVOICE IN CAPS
AND F8
THIS WILL GIVE U VBRK-VBELN .
NOW U CAN USE VBRK-VBELN TO FETCH VBRP
SIMILARLY
2.
IF U WANT TO PICK DELIVERY NUMBER FROM LIKP USING VBAK-VBELN.
SAME PPROCEDURE
PUT VBFA -VBELV = VBAK-VBELN
VBFA-VBTYP_N = ' J'. "IN CAPS
WILL FETCH U LIKP-VBELN "DELIVERY
USE THIS TO GET LIPS ENTRIES
hope this helps
regards,
vijay -
Hi Guys,
Can you pls check the query and suggest best approch to improve the performance as its going for dump.
VBAP as 2,22,34,404
VBAK as 25,54,345
and
r_matnr as 96,000 records.
SELECT vbapmatnr SUM( vbapkwmeng )
FROM vbak INNER JOIN vbap ON vbakvbeln = vbapvbeln
INTO TABLE t_xx
WHERE audat BETWEEN w_pstdat AND w_inidat
AND vkorg IN r_vkorg
AND auart IN r_auart
AND vbap~matnr IN r_matnr
AND vbap~werks EQ p_werks
AND vbap~pstyv IN s_pstyv
GROUP BY vbap~matnr.
Regards,
Srinivas M> Check for the View on VBAP AND VBAK that will help to increase the preformence
> instead of inner join
oh, a new option is recommended frequently in recent positing, after FAE is supported so much anymore.
BUT the View is only a dictionary defintion of a join, they are 100% identical on the database
There is not clear limit for the size of the ranges, usually in the order of 1000 or 2000. It will dump when whole resultings statement is above a limit, which is hard tto specify.
WHERE audat BETWEEN w_pstdat AND w_inidat
AND vkorg IN r_vkorg
AND auart IN r_auart
AND vbap~matnr IN r_matnr
AND vbap~werks EQ p_werks
AND vbap~pstyv IN s_pstyv
GROUP BY vbap~matnr.
This are actually several statements, which can be completely different. It depends which IN-Lists/Ranges are filled.
The join can react on that, it uses different accesses, if there are more conditions on vbak or
more vbap.
For the FAE you must programm two versions, one startung with vbak and one with vbak. And
you must determine which one will use. I doubt that you will better than the optimzer in the database.
Siegfried -
SAP Query error for VBAK and KONV tables
Dear Experts,
Want to create SAP Query for below requirement but faced some error
Step1) Extract the data from VBAK table w.r.t. order type , Sale org and date range
and collected the Sales order numbers and doc. condition record (KNUMV)
Step 2)In table KONV (Transactional condition record data) in this table provided input as doc. condition record (KNUMV) with respect to condition type ABCD
Manually i extracted data, there is no problem .
But customer want to generate SAP Query for above requirement
I tried to create but in t.code SQ02 when i tried to join the table VBAK and KONV i faced the below error
Table KONV cannot be used in a join.
How can I create SAP query for above requirement ???
if its not possible then create Z report is the only solution ??????
Thanks in advanceHello
You can not create Query report with joining KONV. But there is one solution for your problem. You can create Query report by using Database VAV. In this logical database you will find all SD tables and also KONV. Use only those tables and fields which you want in your query report. I have checked this and its working
Please try this and update the forum accordingly.
Edited by: moazzamjii on Jun 30, 2011 12:13 PM -
When a sales order is created the entered data is mainly stored in VBAP and VBAK. Is it true?
Hi,
What you have said is correct. Also, for you to understand the tables which are used in SD, you can download the list of SD tables in the following path.
http://www.erpgenie.com/abap/tables_sd.htm
Hope this helps.
Reward if thsi helsp. -
Reading VBAK, VBAP and VBFA table during a process
Hi friends,
I have an execution DUMP in a Z report, so I would be very thankful if you can give me your expert opinion.
I have a Z report which collects some information into an internal table. After that, I need to go over each record and read VABK, VBAP and VBFA tables and compute some quantities. It is not possible to do this in another way because I need to get some information first.
Of course, each table is being read in the corresponding sequence (1st VBAK, then VBAP and then VBFA and at the end LIPS table) using the key or part of it. The problem is that if the user wants to execute the report online, it will be finish in a dump at this routine.
My question is if it is possible to skip the dump getting VBAK and VBAP tables in memory and instead of reading directly, read them from memory. Notice that if I do this I need to put almost the entire table into memory. So, do you think that I will earn time or it will be the same or worse?
Thanks in advance & kind regards,
MMP.Hi everybody!
We applied the note but it doesn't help. We realized that we have a problem with records quantity, so the key user is going to analyze which other parameter could be helpful.
Thank everybody very much!
Kind regards. -
How to get the conition price by dividing the price from vbap table
Hi Experts,
i am given below one assisnment in which when user click on vbeln column which is common column in vbak and vbap table it goes to second interactive alv report in which contains Sales order items details from VBAP table.so please help me to solved my problem.So try to send me some reponse or u can send me report of step which i have given to you below.
Assignment
Qty field refers to the Target Qty field in the table VBAP.
To get Price in the unit divide the price by Condition Pricing Unit.
If SHKZG field is set, then multiply the amount by -1, making it negative.
Report Layout
Item Type Item Number Material Number Material Group Qty Unit
Material Number used by Customer Plant Net Price Pricing Unit Net value Currency
Moderator message: you've been asked ten times now to not dump your specs here. Once more, and your user ID will be deleted.
Edited by: Thomas Zloch on Dec 1, 2011 12:08 PMHi
Assuming you are using Jdev 11g.
Try with this
public void selectionRow(SelectionEvent se) {
String val = getManagedBeanValue("bindings.AttributeName.inputValue");
public static Object getManagedBeanValue(String beanName) {
StringBuffer buff = new StringBuffer("#{");
buff.append(beanName);
buff.append("}");
return resolveExpression(buff.toString());
public static Object resolveExpression(String expression) {
FacesContext facesContext = getFacesContext();
Application app = facesContext.getApplication();
ExpressionFactory elFactory = app.getExpressionFactory();
ELContext elContext = facesContext.getELContext();
ValueExpression valueExp =
elFactory.createValueExpression(elContext, expression,
Object.class);
return valueExp.getValue(elContext);
Vikram -
RELATIONSHIP BETWEEN VBAK/VBAP AND V46R_HEAD TABLE
Hi,
can you please tell me that is there any relationship between VBAK and V46R_HEAD TABLE or VBAP and V46R_HEAD TABLE table.
where V46R_HEAD TABLE is a structure and i want to display sme fields of vbak and some of V46R_HEAD and some of VBAP.
I got the relation between VBAK and VBAP ie. the field VBELN. But i am not getting the relation with V46R_HEAD sturcture.
Please help me to solve this problem.Hi,
the field vbeln is present in V46R_HEAD also.
Please check it!! Please do a CTR+F and look for VBELN.
Regards. -
Realtionship between J_1IEXCHDR and VBAP or VBAK
Hi All Expert,
Hw ru.
Please help me regarding relation ship between J_1IEXCHDR and VBAK or VBAP table.
currently i am using rdoc in J_1IEXCHDR table but cant fetch data.
PLease guide me which field i can use for relation ship.
*SELECT *
* FROM J_1IEXCHDR
* INTO TABLE it_J_1IEXCHDR
* FOR ALL ENTRIES in IT_VBRK
* where rdoc = it_vbrk-VBELN.
OR
select single exnum from J_1IEXCHDR into itab-exnum
where rdoc = it_vbak-vbeln.
itab-exnum = J_1IEXCHDR-exnum.
Thanking U,
Bhavesh Panchal.Hi,
Excise invoice is posted with reference to Billing document and not sales order. Hence, you would find billing doc no in J_1IEXCHDR-RDOC. To trace back to sales order no use VBFA(Sales document flow) table.
Check FM SD_DOCUMENT_FLOW_GET
Regards,
Amit
Edited by: Amit Iyer on Aug 28, 2009 12:09 PM -
Relation between RESB and AUFM tables
can any one tell me how to build the relation between the above two tables
first i am getting the data from resb
now i need to get the data from aufm
but there are no common key fields
while selecting the data from aufm i want to put the where conditon on key fields onlyhi
good
use this process to know the details.
Go to SQVI transaction... Create a qucik view.. ztest.. give desc..etc
Select data source as table join.... enter
now one screen will come with blank data (blue scrren)
in that application toolbar second button .. click that.. enter VBAK..
click that again.. enter VBAP.. now an image will come with links b/w vbak and vbap.. you can use any no. of tables there....
thanks
mrutyun^
Maybe you are looking for
-
How to import data from legacy system to SAP
How do we import legacy data to SAP system? Iu2019m a trainee on SAP HR, just wanted a brief description on that in layman terms? There are lot of threads related to issue please use Search forum for Better results before posting the query search t
-
Designing ADF task flow for Human task
Hi all, I have the following requirement. Find a participant from Active directory and assign the participant as manager (in business object) in ADF (taskdetails.jspx) Can you help me with the steps to implement the above requirement (on how to conne
-
Logic Pro 9 Menu Separator not showing up in Mavericks?
I'm trying to customize the menu bar in Logic 9 with separators, but when I go to edit the menu bar, the separator icons won't show up?
-
Will and old and used ipod classic sync to my current version of itunes?
Will a 3rd generation ipod classic sync with my current updated version of itunes on my mac? If so, can I put podcasts on it as well?
-
TS3999 Is there a way to see the date you invited someone to an event on your calendar?
Is there a way to see the date you invited someone to an event on your calendar?