BAPI not returning the data
Hi,
I have developed the BAPI which gets the data from few tables and puts them in one structure. But when I am running I am not getting the output. When I am debugging the same the structure is getting populated but it is not getting returned. Please let me know what could be the issue.
Regards,
Ashutosh
Dear Aushutosh ,
Please check whether You have created structure of table in which you are taking values
Do as Such
Create Structure
through se11
Data Type : zname .
having field which you required
such as
name1
waers
klimk
skfor
cskfor
Then assign this Structure to your RFC i.e BAPi
in TAbles Tab
such as
Result like zname .
and then you use your code
to append data in result table
whit proper import parameter and Export parameter if any .
Regards
Deepak .
Similar Messages
-
ExtractValue not returning the data after dbms_xmlschema.CopyEvolve
Hi ,
I am facing the problem while selecting the value from the XMLTYPE table using extractValue.
Here address field is newly added to schema and evolved . But unable to get the address field value .
My procedures are like this
SQL> declare
2 res boolean;
3 xmlschema xmltype := xmltype(
4 '<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns.oracle.com/xdb">
5 <xsd:complexType name="t_person" xdb:SQLType="PERSONDT_T">
6 <xsd:sequence>
7 <xsd:element name="persondetails" type="persondetailsType"/>
8 <xsd:element name="companyinfo" type="companyinfoType"/>
9 <xsd:element name="salaryinfo" type="salaryinfoType"/>
10 </xsd:sequence>
11 </xsd:complexType>
12 <xsd:complexType name="persondetailsType" xdb:SQLType="PERSONDETAILS_T">
13 <xsd:sequence>
14 <xsd:element name="personname" type="xsd:string" />
15 <xsd:element name="personexperience" type="xsd:decimal" />
16 </xsd:sequence>
17 </xsd:complexType>
18 <xsd:complexType name="companyinfoType" xdb:SQLType="COMPANYINFO_T">
19 <xsd:sequence>
20 <xsd:element name="companystartdate" type="xsd:date" />
21 <xsd:element name="companystandard" type="xsd:decimal" />
22 </xsd:sequence>
23 </xsd:complexType>
24 <xsd:complexType name="salaryinfoType" xdb:SQLType="SALARYINFO_T">
25 <xsd:sequence>
26 <xsd:element name="salary" type="xsd:decimal" />
27 <xsd:element name="paymonth" type="xsd:string" />
28 </xsd:sequence>
29 </xsd:complexType>
30 <xsd:element name="person" type="t_person" />
31 </xsd:schema>');
32 begin
33 if (dbms_xdb.existsResource('/public/personDetails.xsd')) then
34 dbms_xdb.deleteResource('/public/personDetails.xsd');
35 end if;
36 res := dbms_xdb.createResource('/public/personDetails.xsd',xmlschema);
37 end;
38 /
PL/SQL procedure successfully completed.
SQL> begin
2 dbms_xmlschema.registerSchema ('www.PersonInfoUrl.com',xdburitype('/public/personDetails.xsd'),TRUE,TRUE,FALSE,TRUE);
3 end;
4 /
PL/SQL procedure successfully completed.
SQL> CREATE TABLE PERSON_COMP_TABLE
2 (empId VARCHAR2(100) CONSTRAINT pk_PERSONCOMP PRIMARY KEY
3 ,comments VARCHAR2(20)
4 ,joindate DATE
5 ,personjoininfo xmltype)
6 XMLTYPE COLUMN personjoininfo XMLSCHEMA "www.PersonInfoUrl.com" element "person"
7 /
Table created.
SQL> insert into PERSON_COMP_TABLE (empId ,comments ,joindate ,personjoininfo )
2 values ('2006NEW312','RDDEPT','15-jan-2006',
3 sys.XMLType.createXML(
4 '<?xml version="1.0" encoding="UTF-8"?>
5 <person xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="www.PersonInfoUrl.com">
6 <persondetails>
7 <personname>Robert </personname>
8 <personexperience>4.5</personexperience>
9 </persondetails>
10 <companyinfo>
11 <companystartdate>2004-07-24</companystartdate>
12 <companystandard>3.9</companystandard>
13 </companyinfo>
14 <salaryinfo>
15 <salary>2444.3</salary>
16 <paymonth> june </paymonth>
17 </salaryinfo>
18 </person>'))
19 /
1 row created.
SQL> select count(*) from PERSON_COMP_TABLE;
COUNT(*)
1
SQL> declare
xmlschema xmltype := xdburitype('/public/personDetails.xsd').getXML();
res boolean;
begin
select insertChildXML(
xmlschema,
'/xsd:schema/xsd:complexType[@name="companyinfo"]/xsd:sequence',
'xsd:element',
xmltype('<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="address" type="xsd:string"
'xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
into xmlSchema
from dual;
if (dbms_xdb.existsResource('/public/personDetails.xsd')) then
dbms_xdb.deleteResource('/public/personDetails.xsd');
end if;
res := dbms_xdb.createResource('/public/newpersonDetails.xsd',xmlschema);
end;
PL/SQL procedure successfully completed.
Elapsed: 00:00:00.74
SQL> commit;
Commit complete.
Elapsed: 00:00:00.56
SQL> begin
dbms_xmlschema.CopyEvolve
xdb$string_list_t('www.PersonInfoUrl.com'),
XMLSequenceType(xdburitype('/public/newpersonDetails.xsd').getXML()),
null
end;
PL/SQL procedure successfully completed.
Elapsed: 00:00:08.49
SQL> commit;
Commit complete.
Elapsed: 00:00:00.52
SQL> select count(*) from PERSON_COMP_TABLE;
COUNT(*)
1
SQL> insert into PERSON_COMP_TABLE (empId ,comments ,joindate ,personjoininfo )
values ('1234PTR','DTSDDEPT','12-jan-2006',
sys.XMLType.createXML(
'<?xml version="1.0" encoding="UTF-8"?>
<person xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="www.PersonInfoUrl.com">
<persondetails>
<personname>Julie </personname>
<personexperience>3.5</personexperience>
</persondetails>
<companyinfo>
<companystartdate>2005-11-21</companystartdate>
<companystandard>3.9</companystandard>
<address>santaclara</address>
</companyinfo>
<salaryinfo>
<salary>2444.3</salary>
<paymonth> june </paymonth>
</salaryinfo>
</person>'))
1 row created.
SQL> select count(*) from PERSON_COMP_TABLE;
COUNT(*)
2
SQL> SELECT empid, extractValue(personjoininfo,'/person/companyinfo/address') FROM PERSON_COMP_TABLE
2 /
empid
E
1234PTR
Here "address " is not returned. it has return the value "santaclara".
How to solve this ?. Please advise
Thanks
GovindaAfter chasing down couple of silly mistakes I was able to get your example to work
SQL> call dbms_xmlschema.deleteSchema ('www.PersonInfoUrl.com',4)
2 /
Call completed.
SQL> declare
2 res boolean;
3 xmlschema xmltype := xmltype(
4 '<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns.oracle.com/xdb">
5 <xsd:complexType name="t_person" xdb:SQLType="PERSONDT_T">
6 <xsd:sequence>
7 <xsd:element name="persondetails" type="persondetailsType"/>
8 <xsd:element name="companyinfo" type="companyinfoType"/>
9 <xsd:element name="salaryinfo" type="salaryinfoType"/>
10 </xsd:sequence>
11 </xsd:complexType>
12 <xsd:complexType name="persondetailsType" xdb:SQLType="PERSONDETAILS_T">
13 <xsd:sequence>
14 <xsd:element name="personname" type="xsd:string"/>
15 <xsd:element name="personexperience" type="xsd:decimal"/>
16 </xsd:sequence>
17 </xsd:complexType>
18 <xsd:complexType name="companyinfoType" xdb:SQLType="COMPANYINFO_T">
19 <xsd:sequence>
20 <xsd:element name="companystartdate" type="xsd:date"/>
21 <xsd:element name="companystandard" type="xsd:decimal"/>
22 </xsd:sequence>
23 </xsd:complexType>
24 <xsd:complexType name="salaryinfoType" xdb:SQLType="SALARYINFO_T">
25 <xsd:sequence>
26 <xsd:element name="salary" type="xsd:decimal"/>
27 <xsd:element name="paymonth" type="xsd:string"/>
28 </xsd:sequence>
29 </xsd:complexType>
30 <xsd:element name="person" type="t_person"/>
31 </xsd:schema>');
32 begin
33 if (dbms_xdb.existsResource('/public/personDetails.xsd')) then
34 dbms_xdb.deleteResource('/public/personDetails.xsd');
35 end if;
36 res := dbms_xdb.createResource('/public/personDetails.xsd',xmlschema);
37 end;
38 /
PL/SQL procedure successfully completed.
SQL> begin
2 dbms_xmlschema.registerSchema ('www.PersonInfoUrl.com',xdburitype('/public/personDetails.xsd'),TRUE,TRUE,FALSE,TRUE);
3 end;
4 /
PL/SQL procedure successfully completed.
SQL> DROP TABLE PERSON_COMP_TABLE
2 /
Table dropped.
SQL> CREATE TABLE PERSON_COMP_TABLE
2 (
3 empId VARCHAR2(100) CONSTRAINT pk_PERSONCOMP PRIMARY KEY
4 ,comments VARCHAR2(20)
5 ,joindate DATE
6 ,personjoininfo xmltype
7 )
8 XMLTYPE COLUMN personjoininfo XMLSCHEMA "www.PersonInfoUrl.com" element "person"
9 /
Table created.
SQL> insert into PERSON_COMP_TABLE (empId ,comments ,joindate ,personjoininfo )
2 values ('2006NEW312','RDDEPT','15-jan-2006',
3 XMLType(
4 '<?xml version="1.0" encoding="UTF-8"?>
5 <person xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="www.PersonInfoUrl.com">
6 <persondetails>
7 <personname>Robert </personname>
8 <personexperience>4.5</personexperience>
9 </persondetails>
10 <companyinfo>
11 <companystartdate>2004-07-24</companystartdate>
12 <companystandard>3.9</companystandard>
13 </companyinfo>
14 <salaryinfo>
15 <salary>2444.3</salary>
16 <paymonth> june </paymonth>
17 </salaryinfo>
18 </person>'))
19 /
1 row created.
SQL> select count(*) from PERSON_COMP_TABLE
2 /
COUNT(*)
1
SQL> declare
2 xmlschema xmltype := xdburitype('/public/personDetails.xsd').getXML();
3 res boolean;
4 begin
5 select insertChildXML
6 (
7 xmlschema,
8 '/xsd:schema/xsd:complexType[@name="companyinfoType"]/xsd:sequence',
9 'xsd:element',
10 xmltype('<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="address" type="xsd:string"/>'),
11 'xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
12 )
13 into xmlSchema
14 from dual;
15
16 if (dbms_xdb.existsResource('/public/newPersonDetails.xsd')) then
17 dbms_xdb.deleteResource('/public/newPersonDetails.xsd');
18 end if;
19
20 res := dbms_xdb.createResource('/public/newPersonDetails.xsd',xmlschema);
21 end;
22 /
PL/SQL procedure successfully completed.
SQL> commit
2 /
Commit complete.
SQL> begin
2 dbms_xmlschema.CopyEvolve
3 (
4 xdb$string_list_t('www.PersonInfoUrl.com'),
5 XMLSequenceType(xdburitype('/public/newPersonDetails.xsd').getXML()),
6 null
7 );
8 end;
9 /
PL/SQL procedure successfully completed.
SQL> select count(*) from PERSON_COMP_TABLE
2 /
COUNT(*)
1
SQL> insert into PERSON_COMP_TABLE (empId ,comments ,joindate ,personjoininfo )
2 values ('1234PTR','DTSDDEPT','12-jan-2006',
3 XMLType(
4 '<?xml version="1.0" encoding="UTF-8"?>
5 <person xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="www.PersonInfoUrl.com">
6 <persondetails>
7 <personname>Julie </personname>
8 <personexperience>3.5</personexperience>
9 </persondetails>
10 <companyinfo>
11 <companystartdate>2005-11-21</companystartdate>
12 <companystandard>3.9</companystandard>
13 <address>santaclara</address>
14 </companyinfo>
15 <salaryinfo>
16 <salary>2444.3</salary>
17 <paymonth> june </paymonth>
18 </salaryinfo>
19 </person>'))
20 /
1 row created.
SQL> commit
2 /
Commit complete.
SQL> select count(*) from PERSON_COMP_TABLE
2 /
COUNT(*)
2
SQL> SELECT empid, extractValue(personjoininfo,'/person/companyinfo/address') FROM PERSON_COMP_TABLE
2 /
EMPID
EXTRACTVALUE(PERSONJOININFO,'/PERSON/COMPANYINFO/ADDRESS')
2006NEW312
1234PTR
santaclara
SQL>The mistakes included the XPath used to insert the new element into the XML Schema
You had
'/xsd:schema/xsd:complexType[@name="companyinfo"]/xsd:sequence',
where as the correct XPath is
'/xsd:schema/xsd:complexType[@name="companyinfoType"]/xsd:sequence',
and then you had
if (dbms_xdb.existsResource('/public/personDetails.xsd')) then
dbms_xdb.deleteResource('/public/personDetails.xsd');
end if;
res := dbms_xdb.createResource('/public/newpersonDetails.xsd',xmlschema);
end;
which means that once the document newpersonDetails.xsd had been created once a subsequent execution of the testcase would fail as the document would already exist.
I'm also a little confused... Your testcase implies that you were able to insert the second document, but the number of rows in the table is still shown as 1 after the insert apparently succeeded. Since you did not correctly update the XML Schema before the calling copyEvolve I do not understand how your output shows that the second insert succeeded. -
Problem with QAAWS - not returned the data when passed param
I am working with QAAWS which has input parameter MONTH
I used the MS SQL, in the universe this field described as
DATEPART(MONTH,ARS_Test.dbo.RG1088.PERIOD)
or
CONVERT(char,month(ARS_Test.dbo.RG1088.PERIOD))
where field ARS_Test.dbo.RG1088.PERIOD is type DateTime.
When I build the QAAWS-connection in the Query As A Web Service and I set promt value of parameter MONTH = 4 and query returned 10 records.
I saved this connection
After that I created DataConnection QAAWS in Xcelsius where set reference in the input parameter Month to cell where is value '4'.
I run preview mode and refresh DataConnection - as a result I can't get any data from QAAWS.
Please, help, me
Thanks,
VladimirHi Benni,
Thanks for the reply,
In the system object , i went to the "User Administration" option, then i found following entry's
User Administration Host Name
User Administration Path
User Administration Protocol - Select -httphttps
These above entry's are not sure what i need to enter.
In the "User Management" option , i found the following entry's
Authentication Ticket Type - SAP Logon Ticket
- SAP Assertion Ticket
Logon Method - > -SAPLOGONTICKET
-UIDPWX509CERT
User Mapping Fields >
User Mapping Type > user
admin
admin,user
Can u tell me what u want to me change in the above options
is that above options u are discussed about or sth else.? can u please elabrate your explanation.
Regards
Vijay -
Search term 'CompanyID = 0' does not return the data I need.
Hi all,
I have implemented an integration to get data of Contact from Eloqua by SOAP APIs.
In my test data, some contacts have company information whose ID is 0 and some ID is 1. When using searchTerm 'CompanyID = 1', I could get the records whose Company ID is 1. But when using 'CompanyID = 0', 0 record(s) would be returned.
Is there anything special for the value 0?
Any suggestions?
Thanks,
BiaoHi Dharmesh,
I tried other IDs greater than 0 and all work well.
My block issue now is that, I could find some Contacts with CompanyID 0 but there is no filter to select them out.
Any suggestions?
Thanks,
Biao -
How to know if the data model qry is not returning any data
Hi
If my report doesn't have data (meaning if the data model qry doesn't retreive any data), I wan't to show this text: "There is no data returned."
My question is how would I know that the qry is not returning any data. I know I can create a text field, and write a trigger on it, to set it True or False depending on the fact that data is being returned or not.
Thanks
ShaluHi,
In Data Model create a summary column for function=count on one of your columns.
Then for BeforeReport trigger you can write
function BeforeReport return boolean is
begin
if :CS_RPT_NODATA > 0 then
return (TRUE);
end if;
SRW.MESSAGE(300,'There is no data');
return (FALSE);
end;
Regards, Gicu -
Not showing the Data in VC application
Hi I have developed the application in VC.
It is showing the data some times , it is not showing the data. Can u please let me know what is the problem.
when i checked using the Test Data service . It is showing the data. Then i have developed step by step, in between the time i use to run the application , it was showing the data. finally i have assigned to some role and user id. then also it is showing the data.
Next day after i run the application , it is not showing the data. displaying the message .
"No Data Found".
But when i run the BAPI at the back end R/3 it is giving the data properly.
Can u tell me what might be the problem
REgards
VijayHi Krishna,
check the logs in the NWA. It seems that your connection is broken down sometimes, maybe a timeout. How many records does your data service return?
Check it with external debugging of the BAPI, when you can reconstruct the error.
Best Regards,
Marcel -
Error: 'BP category 1 does not fit the data in category 2'
Hi,
i have written a program to create a contact person and the code for it is pasted below...when i run this program i get nothing but this message in the status bar 'BP category 1 does not fit the data in category 2'...can someone tell me wht the error means and y it is coming.
thanks:)
pushpa
*table for storing the line by line records in the excel file
TYPES: BEGIN OF TTAB,
REC(1000) TYPE C,
END OF TTAB.
DATA ITAB TYPE TABLE OF TTAB WITH HEADER LINE.
*variable for storing the name of the excel file to be uploaded
DATA UP_FILE TYPE STRING.
*data to be uploaded
TYPES: BEGIN OF TDAT,
FLD1 TYPE BAPIBUS1006_CENTRAL_ORGAN-NAME1,
FLD2 TYPE BAPIBUS1006_ADDRESS-STREET,
FLD3 TYPE BAPIBUS1006_ADDRESS-CITY,
FLD4 TYPE BAPIBUS1006_ADDRESS-REGION,
FLD5 TYPE BAPIBUS1006_ADDRESS-POSTL_COD1,
FLD6 TYPE BAPIBUS1006_ADDRESS-COUNTRY,
FLD7 TYPE BAPIBUS1006_CENTRAL-PARTNEREXTERNAL,
END OF TDAT.
DATA IDAT TYPE TABLE OF TDAT WITH HEADER LINE.
DATA: BUSINESSPARTNER TYPE BAPIBUS1006_HEAD-BPARTNER,
CENTRALDATA TYPE BAPIBUS1006_CENTRAL,
ORGANIZATION TYPE BAPIBUS1006_CENTRAL_ORGAN,
ADDRESS TYPE BAPIBUS1006_ADDRESS,
BAPIRETURN LIKE BAPIRET2 OCCURS 0 WITH HEADER LINE.
PARAMETERS P_FILE TYPE LOCALFILE.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FILE.
CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
EXPORTING
STATIC = 'X'
CHANGING
FILE_NAME = P_FILE.
START-OF-SELECTION.
UP_FILE = P_FILE.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
FILENAME = UP_FILE
TABLES
DATA_TAB = ITAB
EXCEPTIONS
FILE_OPEN_ERROR = 1
FILE_READ_ERROR = 2
NO_BATCH = 3
GUI_REFUSE_FILETRANSFER = 4
INVALID_TYPE = 5
NO_AUTHORITY = 6
UNKNOWN_ERROR = 7
BAD_DATA_FORMAT = 8
HEADER_NOT_ALLOWED = 9
SEPARATOR_NOT_ALLOWED = 10
HEADER_TOO_LONG = 11
UNKNOWN_DP_ERROR = 12
ACCESS_DENIED = 13
DP_OUT_OF_MEMORY = 14
DISK_FULL = 15
DP_TIMEOUT = 16
OTHERS = 17.
*writing out the contents of the internal table itab
LOOP AT ITAB.
WRITE:/ ITAB-REC.
CLEAR IDAT.
SPLIT ITAB-REC AT CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB
INTO IDAT-FLD1 IDAT-FLD2 IDAT-FLD3 IDAT-FLD4 IDAT-FLD5 IDAT-FLD6 IDAT-FLD7.
APPEND IDAT.
ENDLOOP.
LOOP AT IDAT.
MOVE: IDAT-FLD1 TO ORGANIZATION-NAME1,
IDAT-FLD2 TO ADDRESS-STREET,
IDAT-FLD3 TO ADDRESS-CITY,
IDAT-FLD4 TO ADDRESS-REGION,
IDAT-FLD5 TO ADDRESS-POSTL_COD1,
IDAT-FLD6 TO ADDRESS-COUNTRY,
IDAT-FLD7 TO CENTRALDATA-PARTNEREXTERNAL,
'0001' TO CENTRALDATA-PARTNERTYPE.
CALL FUNCTION 'BAPI_BUPA_CREATE_FROM_DATA'
EXPORTING
PARTNERCATEGORY = '1'
CENTRALDATA = CENTRALDATA
CENTRALDATAORGANIZATION = ORGANIZATION
ADDRESSDATA = ADDRESS
IMPORTING
BUSINESSPARTNER = BUSINESSPARTNER
TABLES
RETURN = BAPIRETURN.
IF BAPIRETURN IS NOT INITIAL.
READ TABLE BAPIRETURN INDEX 1.
MESSAGE
ID BAPIRETURN-ID
TYPE BAPIRETURN-TYPE
NUMBER BAPIRETURN-NUMBER
WITH BAPIRETURN-MESSAGE_V1
BAPIRETURN-MESSAGE_V2
BAPIRETURN-MESSAGE_V3
BAPIRETURN-MESSAGE_V4.
EXIT.
ENDIF.
REFRESH BAPIRETURN.
CLEAR BAPIRETURN.
CALL FUNCTION 'BAPI_BUPA_ROLE_ADD'
EXPORTING
BUSINESSPARTNER = BUSINESSPARTNER
BUSINESSPARTNERROLE = 'BUP001'
DIFFERENTIATIONTYPEVALUE =
TABLES
RETURN = BAPIRETURN.
IF BAPIRETURN IS NOT INITIAL.
READ TABLE BAPIRETURN INDEX 1.
MESSAGE
ID BAPIRETURN-ID
TYPE BAPIRETURN-TYPE
NUMBER BAPIRETURN-NUMBER
WITH BAPIRETURN-MESSAGE_V1
BAPIRETURN-MESSAGE_V2
BAPIRETURN-MESSAGE_V3
BAPIRETURN-MESSAGE_V4.
EXIT.
ENDIF.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
WRITE:/ 'Business Partner ID:', BUSINESSPARTNER.
ENDLOOP.Hi Pushpa,
you can use following code to create relationships using BAPI. In this Business partner is organisatin. contact persion paramenter is person. other information related to relationship details
CALL FUNCTION 'BAPI_BUPR_CONTP_CREATE'
EXPORTING
BUSINESSPARTNER = SEARCH_PARTNER
CONTACTPERSON = CONTACT_SAP
VALIDFROMDATE = '00010101'
VALIDUNTILDATE = '99991231'
DEFAULTRELATIONSHIP =
ADDRESSGUID =
CENTRALDATA = WA_CENTRAL_DATA
ADDRESSDATA = WA_ADDR_DATA
TABLES
BAPIADTEL = I_TEL_DATA
BAPIADFAX = I_FAX_DATA
BAPIADTTX =
BAPIADTLX =
BAPIADSMTP = I_EMAIL_DATA
BAPIADRML =
BAPIADX400 =
BAPIADRFC =
BAPIADPRT =
BAPIADSSF =
BAPIADURI =
BAPIADPAG =
BAPIAD_REM =
BAPICOMREM =
RETURN = I_RETURN
hope this will help you
Siva -
BAPI not returning dataset thru iviews to EP from ECC
Hi All,
We have ERP 6.0 and we are trying to use BAPI to pull data from ECC to EP using SAP RFC-iviews.
We have configured the system object , we are getting the all the BAPI FM info from ECC during creating of new rfc-iview, but when we try to preview the iview by giving the input to the FM is not returning any data.
We have tested the same FM from SE37 and able to get the dataset.
Please suggest me if any configuration to be done.
Thanks,
Subhash.GProblem is solved, while giving input in iview we have to give exact details like for customer number it stores like 0000000001, if we give only 1 it's won't interpet as it was in Data dictionary... but while testing in sm37 you can give as 1 for customer number.
Thanks,
Subhash -
ExecuteWithParams is not returning the rows from cache
Hi,
We have two VO's based on same entity ,whenever new row is inserted in one VO and we do executeWithParams on another VO ,It is not returning the rows which are uncommitted.
I replaced the executeWithParams with a custom method in AM in which I am executing the query after applying the view criteria and setting query mode.Its returning rows which are uncommitted.
Jdev Version which I am using is 11.1.1.7.0
ExecuteWithParams used to work with uncommitted data in 11.1.1.6.0 .
Do we need to raise a bug on framework or Am I missing something?
Edited by: sharavnkumar_malla on Oct 18, 2012 1:02 AMStill the same answer, even after you updated the question. We (the public) don't have 11.1.1.7, know nothing about 11.1.1.7, and cannot help you with 11.1.1.7. Questions about internal builds belong on internal forums.
-
I am using TABLE(CAST()) operation in PL/SQL and it is returning me no data.
Here is what I have done:
1. Created Record type
CREATE OR REPLACE TYPE target_rec AS OBJECT
target__id NUMBER(10),
target_entity_id NUMBER(10),
dd CHAR(3),
fd CHAR(3),
code NUMBER(10),
target_pct NUMBER,
template_nm VARCHAR2(50),
p_symbol VARCHAR2(10),
pm_init VARCHAR2(3),
target_name VARCHAR2(20),
targe_type VARCHAR2(30),
target_caption VARCHAR2(30),
sort_order NUMBER (4)
2. Created Table type
CREATE OR REPLACE TYPE target_arr AS TABLE OF target_rec
3. Created Stored procedure which accepts parameter of type target_arr and runs the Table(Cast()) function on it.
Following is the simplified form of my procedure.
PROCEDURE get_target_weights
p_in_template_target IN target_arr,
p_out_count OUT NUMBER,
IS
BEGIN
SELECT count(*) into p_out_count
FROM TABLE(CAST(p_in_template_target AS target_arr)) arr;
END;
I am calling get_target_weights from my java code and passing p_in_template_target with 10140 records.
Scenario 1: If target_pct in the last record is 0, p_out_count returned from the procedure is 0.
Scenario 2: If target_pct in the last record is any other value(say 0.01), p_out_count returned from the procedure is 10140.
Please help me understand why the Table(Cast()) is not returning the correct results in Scenario 1. Also adding or deleting any record from the test data returns the correct results (i.e. if keep target_pct in the last record as 0 but add or delete any record).
Let me know how can I attach the test data I am using to help you debugging as I don’t see any Attach file button on Post Message screen on the forum.I am not able to reproduce this problem with a small data set. I can only reproduce with the data having 10140 records.
I am not sure if this is the memory issue as adding a new record also solves the problem.
This should not be the error because of wrong way of filling the records in java as for testing purpose I just saved the records which I am sending from java in a table. I updated the stored procedure as well to read the data from the table and then perform TABLE(CAST()) operation. I am still getting 0 as the output for scenario 1 mentioned in my last mail.
Here is what I have updated:
1. Created the table target_table
CREATE Table target_table
target_id NUMBER(10),
target_entity_id NUMBER(10),
dd CHAR(3),
fd CHAR(3),
code NUMBER(10),
target_pct NUMBER,
template_nm VARCHAR2(50),
p_symbol VARCHAR2(10),
pm_init VARCHAR2(3),
target_name VARCHAR2(20),
target_type VARCHAR2(30),
target_caption VARCHAR2(30),
sort_order NUMBER (4)
2. Inserted data into the table : The script has around 10140 rows. Pls let me know how can I send it to you
3. Updated procedure to read data from table and stored into variable of type target_arr. Run Table(cast()) operation on target_arr and get the count
PROCEDURE test_target_weights
IS
v_target_rec target_table%ROWTYPE;
CURSOR wt_cursor IS
Select * from target_table;
v_count NUMBER := 1;
v_target_arr cws_target_arr:= target_arr ();
v_target_arr_rec target_rec;
v_rec_count NUMBER;
BEGIN
OPEN wt_cursor;
loop
fetch wt_cursor into v_target_rec; -- fetch data from table into local record.
exit when wt_cursor%notfound;
--move data into target_arr
v_target_arr_rec := cws_curr_pair_entity_wt_rec(v_target_rec target_id,v_target_rec. target_entity_id,
v_target_rec.dd,v_target_rec.fd,v_target_rec.code,v_target_rec.target_pct,
v_target_rec.template_nm,v_target_rec.p_symbol,v_target_rec.pm_init,v_target_rec.template_name,
v_target_rec.template_type,v_target_rec.template_caption,v_target_rec.sort_order);
v_target_arr.extend();
v_target_arr(v_count) := v_target_arr_rec;
v_count := v_count + 1;
end loop;
close wt_cursor;
-- run table cast on target_arr
SELECT count(*) into v_rec_count
FROM TABLE(CAST(v_target_arr AS target_arr)) arr;
DBMS_OUTPUT.enable;
DBMS_OUTPUT.PUT_LINE('p_out_count ' || v_rec_count);
DBMS_OUTPUT.PUT_LINE('v_count ' || v_count);
END;
Output is
p_out_count 0
v_count 10140
Expected output
p_out_count 10140
v_count 10140 -
Report needed to list the persons- not returning the safety tools back
dear friends,
in our client place, the stores departement, allots safety equipements to thier employee's, by mentioning duration period for return.
stores departement, already noted the date of issue and date of return in asset register.some of the employees are not returning the safety equipements,.
in as01- create asset field(from & to )duration is specified. how to track this.
so my clients is asking a report,which describes the list of employees, they were not returning the safety tools. is there any way to do this.
kindly help me in getting the solution.
regards,
g.v.shivakkumarWell, this is really a SQL question, not an ApEx question, but here goes....
Your query would return r_number and status_id from any record that contains a status_id of 2 and not 4. Well, if it's 2, it can't be 4, so it's really returning any record where status_id is 2, which would be rows with ID 12, 876, and 33. What I think you want is a query where you find a status_id of 2 and no other record in the database has the same r_number only with a status_id of 4.
Try
select r_number, status_id from table1
where status_id = '2'
and r_number not in (select r_number from table1 where status_id = '4')
This works, but may not be the most efficient query. -
How to consume the webservice if it returns the data in dataset format
Dear All,
We have a requirement to consume webservice created in .NET platform. In that webservice they are returning data in dataset format. In this case i am not able to create a proxy. It is showing the following information.
Cannot generate proxy (object schema mis
WSDL, see long text)
<?xml version="1.0" encoding="utf-8" ?>
- <wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://tempuri.org/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" targetNamespace="http://tempuri.org/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
- <wsdl:types>
- <s:schema elementFormDefault="qualified" targetNamespace="http://tempuri.org/">
<s:import namespace="http://www.w3.org/2001/XMLSchema" />
- <s:element name="getTaskEffort">
- <s:complexType>
- <s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="SPRProjectId" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
- <s:element name="getTaskEffortResponse">
- <s:complexType>
- <s:sequence>
- <s:element minOccurs="0" maxOccurs="1" name="getTaskEffortResult">
- <s:complexType>
- <s:sequence>
<s:element ref="s:schema" />
<s:any />
</s:sequence>
</s:complexType>
</s:element>
</s:sequence>
</s:complexType>
</s:element>
</s:schema>
</wsdl:types>
- <wsdl:message name="getTaskEffortSoapIn">
<wsdl:part name="parameters" element="tns:getTaskEffort" />
</wsdl:message>
- <wsdl:message name="getTaskEffortSoapOut">
<wsdl:part name="parameters" element="tns:getTaskEffortResponse" />
</wsdl:message>
- <wsdl:portType name="OntimeWSSoap">
- <wsdl:operation name="getTaskEffort">
<documentation xmlns="http://schemas.xmlsoap.org/wsdl/">This method.</documentation>
<wsdl:input message="tns:getTaskEffortSoapIn" />
<wsdl:output message="tns:getTaskEffortSoapOut" />
</wsdl:operation>
</wsdl:portType>
- <wsdl:binding name="OntimeWSSoap" type="tns:OntimeWSSoap">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
- <wsdl:operation name="getTaskEffort">
<soap:operation soapAction="http://tempuri.org/getTaskEffort" style="document" />
- <wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
- <wsdl:service name="OntimeWS">
<documentation xmlns="http://schemas.xmlsoap.org/wsdl/" />
- <wsdl:port name="OntimeWSSoap" binding="tns:OntimeWSSoap">
<soap:address location="http://hts-pcs-0808/OntimeData/Ontime.asmx" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
I tried to consume webservice http://student.ohecampus.com/projects/group95/stud17/assignment7/validateEmail.asmx, which will return the data in boolean format. In this case, i am able to create a proxy and it is working fine. Can anyone help me out.
Thanks in advance.
Regards,
KarthickDear Raja,
I checked with webservice owner who created the webservice. They are telling that there is no problem in XML file which they gave. The webservice they provided is consumed in many application and it is working fine. When in SAP, i tried to create a proxy it is showing the in information which i mentioned in earlier posted forum message.
Kindly advice.
Regards,
Karthick -
Binocular search for Cost Center is not returning any data
Hi Gurus,
When clicking on the SRM-Shooping Cart-Cost Assignment- Account Assignment Overview- Cost center Binocular search icon, it is not returning any data. However, when drilling down in the Account Assignment Overview, you will see another Binocular search icon for Cost Center which is working fine.
Any idea of how you troubleshoot it.
Thanks in advace for your help.
HANot sure about the cost assignment drill down, but after we applied SP13 to SRM server 550 the binoculars for cost center stopped working. the following note corrected this.
Note 1259735 - Search help of generic account does not work
If it has never worked, then probably need to setup a RFC dialog user for the F4 search help, Multiple threads on here around the dialog user for F4 with details on configuration and use.
JF -
OraDynaSet not returning the correct number of records.
Hello All, I am writing VB code in Excel 2007 and retrieving records from a Oracle 9i database. When I run my query from TOAD or any other sql app I get 56 records returned for certain query. However, when I do it from VB in excel and write the values to the excel file, it will not return the last 3 records, any suggestions? Here is part of my code:
Worksheets("Report").Range("A3").Value = ""
Worksheets("Report").Range("B3").Value = "Period"
Worksheets("Report").Range("C3").Value = "Budget"
Worksheets("Report").Range("D3").Value = "Projected"
strSQL = "select group_name,period_name,budget_value,budget_value project from nlas_bdgt_loading_stg where plant = " & plant & " and group_number = 1 order by group_number, period_num"
Set OraDynaSet = objDataBase.DBCreateDynaset(strSQL, 0&)
If OraDynaSet.RecordCount > 0 Then
OraDynaSet.MoveFirst
'Loop the recordset for returned rows
For i = 4 To OraDynaSet.RecordCount
'Put the results in columns
ActiveSheet.Cells(i, 1) = OraDynaSet.Fields(0).Value
ActiveSheet.Cells(i, 2) = OraDynaSet.Fields(1).Value
ActiveSheet.Cells(i, 3) = OraDynaSet.Fields(2).Value
ActiveSheet.Cells(i, 4) = OraDynaSet.Fields(3).Value
OraDynaSet.MoveNext
Next i
End If
Thanks,
ChrisHello.
It's a bit weird. It works for me. If you have a look at oo4o help:
CopyToClipboard Method
Example
Applies To
OraDynaset
Description
Copy the rows from the dynaset to the Clipboard in text format.
Usage
OraDynaset.CopyToClipboard(NumOfRows ,colsep [optional],rowsep [optional] )
Arguments
NumOfRows Number of rows to be copied to the dynaset ,
colsep Column separator in CHAR to be inserted between columns
rowsep Row seperater in CHAR to be inserted between Rows
Remarks
This method is used to facilitate transfer of data between Oracle Object for OLE’s cache (dynaset) and Windows applications such as Excel or Word. CopyToClipboard copies data starting from current position of the dynaset up to the last row.
Default column separator is TAB (ASCII 9).
Default row separator is ENTER (ASCII 13).
Can it be that you don't have all the References needed?
Octavio -
Hi,
I have some ibots that I scheduled to run on a daily basis and which were working perfectly.
Suddenly the same ibots, they run but the content of the attachment says "The specified criteria did not return any data".
I checked the log files and could not see any relavant error.
If I go back in the report that I am sending through the ibot, it runs without any problem.
I tried to send it in different formats and run as different users, but the results are still the same!
Any idea what else I could check?
Type: Warning
Severity: 50
Time: Wed May 15 14:10:19 2013
File: project/webodbcaccess/odbcconnectionimpl.cpp Line: 199
Properties: RptPath-/shared/MICROS/giuliano/cube_build_verification;SID-btilnnapkfo2omg91a71b9m6n2;bindID-1;connID-31;ThreadID-4640;statementID-364;RSP-o:go~r:report
Location:
saw.odbc.statement.fetch
saw.subsystem.portal.pdf
saw.delivers.rpc.getDeviceContent
saw.rpc.server.responder
saw.rpc.server
saw.rpc.server.handleConnection
saw.rpc.server.dispatch
saw.threadPool
saw.threads
SQLFetchScroll returned code SQL_NO_DATA_FOUNDThanks it solved the issue.
But One more thing Now I have placed the parameters in the where clause of the query
Query-
select field1,field2,field3,field4,field5,job_name,candidate_name,interview_date from etc.ethr_irc_int_details
where field1 is not null
and job_name = :1
and candidate_name = :2
and interview_date = :3
in the VO I am executing
public void iniQuery(String S1, String S2,String S3)
System.out.println("insdie ini query of the VO");
System.out.println("S1 "+S1);
System.out.println("S2 "+S2);
System.out.println("S3 "+S3);
this.setWhereClauseParams(null);
this.setWhereClauseParam(0,S1);
this.setWhereClauseParam(1,S2);
this.setWhereClauseParam(2,S2);
executeQuery();
and in AM
ETHRIntDetailsVOImpl IDVO = (ETHRIntDetailsVOImpl)this.getETHRIntDetailsVO();
// IDVO.executeQuery();
// OAViewObject IDVO = (OAViewObject)findViewObject("ETHRIntDetailsVO");
IDVO.iniQuery(S1,S2,S3);
Row row = IDVO.first();
again I am not getting any data in the row??
Any idea if I am doing any thing wrong..
Please help urgently.
Thanks
Ashish
Maybe you are looking for
-
Help: Font size smaller when it's a link
This has been something that's been driving me crazy for over a year and I can't seem to figure it out. After a couple of hours searching online, I thought I'd see if anyone here would be willing to help. I seem to have no problem changing fonts and
-
I can't save a document to mulitple locations in Pages? Is there a workaround? What genius Apple software developer came up with this?
-
Windows 7 boot camp (Macbook Pro 13") function keys
Hey everyone, I've had Bootcamp installed on my Mac prettty much since a few days after I bought it about 3 weeks ago. I've always had this issue- but finally thought I'd do something about it. So, when I'm booted into Windows 7 (ultimate, 64 bit) my
-
A safe alternative to use adobe flash player on iPad
I have found that there are some alternative browser options/apps out there that will allow you to function on iOS with sites that use adobe flash. Im wondering if this is a good idea, since I need to use it with a particular budgeting/bill pay site
-
Exact difference between VOimpl and VORowimpl and EO.
Can anybody tell me whats the exact difference between VOimpl and VORowimpl and EO. Thanks