HI PLEASE HELP ME,
I WNAT TO COPY THE DATA FROM MY CUSTOMISED RECORD SAY BP_VENDOR TO VENDOR(DELEIVERED TABLE) USING AN APP ENGINE WHICH CALLS AN CI,I HAVE CREATED THE CI FOR THE DELIEVERD COMPONENT WHERE IA M GOING TO COPY MY DATA.EX:VNDR_LOAD,I HAVE CREATED THE CI,THE CODE IS
Local File &fileLog;
Local ApiObject &oSession, &oBfHexVndrId;
Local ApiObject &oVendorAttVwCollection, &oVendorAttVw;
Local ApiObject &oInstallationApCollection, &oInstallationAp;
Local ApiObject &oVndrCcrCdVwCollection, &oVndrCcrCdVw;
Local ApiObject &oApVndrAttCollection, &oApVndrAtt;
Local ApiObject &oVndrVatRgstrnCollection, &oVndrVatRgstrn;
Local ApiObject &oVendorInvoiceCollection, &oVendorInvoice;
Local ApiObject &oVndrGovSrcCollection, &oVndrGovSrc;
Local ApiObject &oVndrGovCertCollection, &oVndrGovCert;
Local ApiObject &oVndrHdrIndClCollection, &oVndrHdrIndCl;
Local ApiObject &oVndrRptElemCollection, &oVndrRptElem;
Local ApiObject &oVendorIdNbrsCollection, &oVendorIdNbrs;
Local ApiObject &oVndrSrchadrVwCollection, &oVndrSrchadrVw;
Local ApiObject &oTaxGeocodeTmpCollection, &oTaxGeocodeTmp;
Local ApiObject &oVndrAddrScrolCollection, &oVndrAddrScrol;
Local ApiObject &oVendorAddrCollection, &oVendorAddr;
Local ApiObject &oVendorAddrPhnCollection, &oVendorAddrPhn;
Local ApiObject &oVndrCntctScrCollection, &oVndrCntctScr;
Local ApiObject &oVendorCntctCollection, &oVendorCntct;
Local ApiObject &oVndrCntctPhnCollection, &oVndrCntctPhn;
Local ApiObject &oVndrLocScrolCollection, &oVndrLocScrol;
Local ApiObject &oVndrRtvFeeCollection, &oVndrRtvFee;
Local ApiObject &oApVndrLocAttCollection, &oApVndrLocAtt;
Local ApiObject &oVendorLocCollection, &oVendorLoc;
Local ApiObject &oVendorPayCollection, &oVendorPay;
Local ApiObject &oVndrBankAcctCollection, &oVndrBankAcct;
Local ApiObject &oVendorTypeCollection, &oVendorType;
Local ApiObject &oEmailPayMthdCollection, &oEmailPayMthd;
Local ApiObject &oVendorWthdJurCollection, &oVendorWthdJur;
Local ApiObject &oVendorWthdCollection, &oVendorWthd;
Local ApiObject &oVndrLocIdNbrCollection, &oVndrLocIdNbr;
Local ApiObject &oVndrIndClassCollection, &oVndrIndClass;
Local ApiObject &oVndrUrlCollection, &oVndrUrl;
Local ApiObject &oVlocAddrVwCollection, &oVlocAddrVw;
Function errorHandler()
Local ApiObject &oPSMessageCollection, &oPSMessage;
Local number &i;
Local string &sErrMsgSetNum, &sErrMsgNum, &sErrMsgText, &sErrType;
&oPSMessageCollection = &oSession.PSMessages;
For &i = 1 To &oPSMessageCollection.Count
&oPSMessage = &oPSMessageCollection.Item(&i);
&sErrMsgSetNum = &oPSMessage.MessageSetNumber;
&sErrMsgNum = &oPSMessage.MessageNumber;
&sErrMsgText = &oPSMessage.Text;
&fileLog.WriteLine(&sErrType | " (" | &sErrMsgSetNum | "," | &sErrMsgNum | ") - " | &sErrMsgText);
End-For;
rem ***** Delete the Messages from the collection *****;
&oPSMessageCollection.DeleteAll();
End-Function;
try
rem ***** Set the Log File *****;
&fileLog = GetFile("C:\Temp\BF_VENDOR_CI.log", "w", "a", %FilePath_Absolute);
&fileLog.WriteLine("Begin");
rem ***** Get current PeopleSoft Session *****;
&oSession = %Session;
rem ***** Set the PeopleSoft Session Error Message Mode *****;
rem ***** 0 - None *****;
rem ***** 1 - PSMessage Collection only (default) *****;
rem ***** 2 - Message Box only *****;
rem ***** 3 - Both collection and message box *****;
&oSession.PSMessagesMode = 1;
rem ***** Get the Component Interface *****;
&oBfHexVndrId = &oSession.GetCompIntfc(CompIntfc.BF_HEX_VNDR_ID);
If &oBfHexVndrId = Null Then
errorHandler();
throw CreateException(0, 0, "GetCompIntfc failed");
End-If;
rem ***** Set the Component Interface Mode *****;
&oBfHexVndrId.InteractiveMode = False;
&oBfHexVndrId.GetHistoryItems = True;
&oBfHexVndrId.EditHistoryItems = False;
rem ***** Set Component Interface Get/Create Keys *****;
&oBfHexVndrId.SETID = "BUPA";
&oBfHexVndrId.VENDOR_ID = "0000020001";
&oBfHexVndrId.VENDOR_PERSISTENCE = "R";
rem ***** Execute Get *****;
If Not &oBfHexVndrId.Get() Then
rem ***** No rows exist for the specified keys.*****;
errorHandler();
throw CreateException(0, 0, "Get failed");
End-If;
rem ***** Execute Create ******;
rem If Not &oBfHexVndrId.Create() Then;
rem ***** Unable to Create Component Interface for the Add keys provided. *****;
rem errorHandler();
rem throw CreateException(0, 0, "Create failed");
rem End-If;
rem ***** Begin: Get/Set Component Interface Properties *****;
rem ***** Get/Set Level 0 Field Properties *****;
&fileLog.WriteLine("&oBfHexVndrId.NAME2 = " | &oBfHexVndrId.NAME2);
rem &oBfHexVndrId.NAME2 = [*];
&fileLog.WriteLine("&oBfHexVndrId.CORPORATE_SETID = " | &oBfHexVndrId.CORPORATE_SETID);
rem &oBfHexVndrId.CORPORATE_SETID = [*];
&fileLog.WriteLine("&oBfHexVndrId.CORPORATE_VENDOR = " | &oBfHexVndrId.CORPORATE_VENDOR);
rem &oBfHexVndrId.CORPORATE_VENDOR = [*];
&fileLog.WriteLine("&oBfHexVndrId.CUST_ID = " | &oBfHexVndrId.CUST_ID);
rem &oBfHexVndrId.CUST_ID = [*];
&fileLog.WriteLine("&oBfHexVndrId.AR_NUM = " | &oBfHexVndrId.AR_NUM);
rem &oBfHexVndrId.AR_NUM = [*];
&fileLog.WriteLine("&oBfHexVndrId.WTHD_SW = " | &oBfHexVndrId.WTHD_SW);
rem &oBfHexVndrId.WTHD_SW = [*];
&fileLog.WriteLine("&oBfHexVndrId.VAT_SW = " | &oBfHexVndrId.VAT_SW);
rem &oBfHexVndrId.VAT_SW = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_STATUS_PO = " | &oBfHexVndrId.VNDR_STATUS_PO);
rem &oBfHexVndrId.VNDR_STATUS_PO = [*];
&fileLog.WriteLine("&oBfHexVndrId.HUB_ZONE = " | &oBfHexVndrId.HUB_ZONE);
rem &oBfHexVndrId.HUB_ZONE = [*];
&fileLog.WriteLine("&oBfHexVndrId.EEO_CERTIF_DT = " | &oBfHexVndrId.EEO_CERTIF_DT);
rem &oBfHexVndrId.EEO_CERTIF_DT = [*];
&fileLog.WriteLine("&oBfHexVndrId.INTERUNIT_VNDR_FLG = " | &oBfHexVndrId.INTERUNIT_VNDR_FLG);
rem &oBfHexVndrId.INTERUNIT_VNDR_FLG = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_AFFILIATE = " | &oBfHexVndrId.VNDR_AFFILIATE);
rem &oBfHexVndrId.VNDR_AFFILIATE = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_A = " | &oBfHexVndrId.VNDR_FIELD_C30_A);
rem &oBfHexVndrId.VNDR_FIELD_C30_A = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_B = " | &oBfHexVndrId.VNDR_FIELD_C30_B);
rem &oBfHexVndrId.VNDR_FIELD_C30_B = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_C = " | &oBfHexVndrId.VNDR_FIELD_C30_C);
rem &oBfHexVndrId.VNDR_FIELD_C30_C = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_D = " | &oBfHexVndrId.VNDR_FIELD_C30_D);
rem &oBfHexVndrId.VNDR_FIELD_C30_D = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_E = " | &oBfHexVndrId.VNDR_FIELD_C30_E);
rem &oBfHexVndrId.VNDR_FIELD_C30_E = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_F = " | &oBfHexVndrId.VNDR_FIELD_C30_F);
rem &oBfHexVndrId.VNDR_FIELD_C30_F = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_G = " | &oBfHexVndrId.VNDR_FIELD_C30_G);
rem &oBfHexVndrId.VNDR_FIELD_C30_G = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_H = " | &oBfHexVndrId.VNDR_FIELD_C30_H);
rem &oBfHexVndrId.VNDR_FIELD_C30_H = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_I = " | &oBfHexVndrId.VNDR_FIELD_C30_I);
rem &oBfHexVndrId.VNDR_FIELD_C30_I = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_FIELD_C30_J = " | &oBfHexVndrId.VNDR_FIELD_C30_J);
rem &oBfHexVndrId.VNDR_FIELD_C30_J = [*];
&fileLog.WriteLine("&oBfHexVndrId.VNDR_CCR_STATUS = " | &oBfHexVndrId.VNDR_CCR_STATUS);
rem &oBfHexVndrId.VNDR_CCR_STATUS = [*];
&fileLog.WriteLine("&oBfHexVndrId.OFAC_STATUS = " | &oBfHexVndrId.OFAC_STATUS);
rem &oBfHexVndrId.OFAC_STATUS = [*];
&fileLog.WriteLine("&oBfHexVndrId.OFAC_LAG_DAYS = " | &oBfHexVndrId.OFAC_LAG_DAYS);
rem &oBfHexVndrId.OFAC_LAG_DAYS = [*];
&fileLog.WriteLine("&oBfHexVndrId.OFAC_SKIP_VAL = " | &oBfHexVndrId.OFAC_SKIP_VAL);
rem &oBfHexVndrId.OFAC_SKIP_VAL = [*];
&fileLog.WriteLine("&oBfHexVndrId.CORP_VNDR_FLG = " | &oBfHexVndrId.CORP_VNDR_FLG);
rem &oBfHexVndrId.CORP_VNDR_FLG = [*];
&fileLog.WriteLine("&oBfHexVndrId.CREATE_BILLTO_CUST = " | &oBfHexVndrId.CREATE_BILLTO_CUST);
rem &oBfHexVndrId.CREATE_BILLTO_CUST = [*];
&fileLog.WriteLine("&oBfHexVndrId.SUPPORT_TEAM_CD = " | &oBfHexVndrId.SUPPORT_TEAM_CD);
rem &oBfHexVndrId.SUPPORT_TEAM_CD = [*];
&fileLog.WriteLine("&oBfHexVndrId.COLLECTOR = " | &oBfHexVndrId.COLLECTOR);
rem &oBfHexVndrId.COLLECTOR = [*];
&fileLog.WriteLine("&oBfHexVndrId.CR_ANALYST = " | &oBfHexVndrId.CR_ANALYST);
rem &oBfHexVndrId.CR_ANALYST = [*];
&fileLog.WriteLine("&oBfHexVndrId.CITY = " | &oBfHexVndrId.CITY);
rem &oBfHexVndrId.CITY = [*];
&fileLog.WriteLine("&oBfHexVndrId.STATE = " | &oBfHexVndrId.STATE);
rem &oBfHexVndrId.STATE = [*];
&fileLog.WriteLine("&oBfHexVndrId.POSTAL = " | &oBfHexVndrId.POSTAL);
rem &oBfHexVndrId.POSTAL = [*];
&fileLog.WriteLine("&oBfHexVndrId.COUNTRY = " | &oBfHexVndrId.COUNTRY);
rem &oBfHexVndrId.COUNTRY = [*];
&fileLog.WriteLine("&oBfHexVndrId.ADDRESS1 = " | &oBfHexVndrId.ADDRESS1);
rem &oBfHexVndrId.ADDRESS1 = [*];
&fileLog.WriteLine("&oBfHexVndrId.ADDRESS_OPERATOR = " | &oBfHexVndrId.ADDRESS_OPERATOR);
rem &oBfHexVndrId.ADDRESS_OPERATOR = [*];
&fileLog.WriteLine("&oBfHexVndrId.NAME1_OPERATOR = " | &oBfHexVndrId.NAME1_OPERATOR);
rem &oBfHexVndrId.NAME1_OPERATOR = [*];
&fileLog.WriteLine("&oBfHexVndrId.SNAME_OPERATOR = " | &oBfHexVndrId.SNAME_OPERATOR);
rem &oBfHexVndrId.SNAME_OPERATOR = [*];
&fileLog.WriteLine("&oBfHexVndrId.AUTO_FILL = " | &oBfHexVndrId.AUTO_FILL);
rem &oBfHexVndrId.AUTO_FILL = [*];
rem ***** Set/Get VNDR_VAT_RGSTRN Collection Field Properties -- Parent: PS_ROOT Collection *****;
&oVndrVatRgstrnCollection = &oBfHexVndrId.VNDR_VAT_RGSTRN;
Local integer &i1105;
For &i1105 = 1 To &oVndrVatRgstrnCollection.Count;
&oVndrVatRgstrn = &oVndrVatRgstrnCollection.Item(&i1105);
&fileLog.WriteLine("BLOCK 1");
&RECORD_VALUE = CreateSQL("SELECT SETID,BF_REQUEST_ID,COUNTRY,COUNTRY_2CHAR,VAT_RGSTRN_ID,HOME_COUNTRY_FLG FROM PS_BF_VNDR_VAT_RGS", &setid, &VENDOR_ID, &COUNTRY, &COUNTRY_2CHAR, &VAT_RGSTRN_ID, &HOME_COUNTRY_FLAG);
While &RECORD_VALUE.FETCH(&setid, &VENDOR_ID, &COUNTRY, &COUNTRY_2CHAR, &VAT_RGSTRN_ID, &HOME_COUNTRY_FLAG)
&fileLog.WriteLine(&setid);
&fileLog.WriteLine(&VENDOR_ID);
&fileLog.WriteLine(&COUNTRY);
&fileLog.WriteLine(&COUNTRY_2CHAR);
&fileLog.WriteLine(&VAT_RGSTRN_ID);
&fileLog.WriteLine(&HOME_COUNTRY_FLAG);
&fileLog.WriteLine("BLOCK 2");
&oVndrVatRgstrn = &oVndrVatRgstrnCollection.InsertItem(1);
&oVndrVatRgstrn.SETID = &setid;
&fileLog.WriteLine("&oVndrVatRgstrn.SETID = " | &oVndrVatRgstrn.SETID);
&oVndrVatRgstrn.VENDOR_ID = &VENDOR_ID;
&fileLog.WriteLine("&oVndrVatRgstrn.BF_REQUEST_ID = " | &oVndrVatRgstrn.VENDOR_ID);
&oVndrVatRgstrn.COUNTRY = &COUNTRY;
&fileLog.WriteLine("&oVndrVatRgstrn.COUNTRY = " | &oVndrVatRgstrn.COUNTRY);
&oVndrVatRgstrn.COUNTRY_2CHAR = &COUNTRY_2CHAR;
&fileLog.WriteLine("&oVndrVatRgstrn.COUNTRY_2CHAR = " | &oVndrVatRgstrn.COUNTRY_2CHAR);
&oVndrVatRgstrn.VAT_RGSTRN_ID_0 = &VAT_RGSTRN_ID;
&fileLog.WriteLine("&oVndrVatRgstrn.VAT_RGSTRN_ID_0 = " | &oVndrVatRgstrn.VAT_RGSTRN_ID_0);
&oVndrVatRgstrn.HOME_COUNTRY_FLG = &HOME_COUNTRY_FLAG;
&fileLog.WriteLine("&oVndrVatRgstrn.HOME_COUNTRY_FLG = " | &oVndrVatRgstrn.HOME_COUNTRY_FLG);
End-While;
End-For;
rem ***** End: Get/Set Component Interface Properties *****;
rem ***** Execute Save *****;
rem If Not &oBfHexVndrId.Save() Then;
rem errorHandler();
rem throw CreateException(0, 0, "Save failed");
rem End-If;
rem ***** Execute Cancel *****;
rem If Not &oBfHexVndrId.Cancel() Then;
rem errorHandler();
rem throw CreateException(0, 0, "Cancel failed");
rem End-If;
catch Exception &ex
rem Handle the exception;
&fileLog.WriteLine(&ex.ToString());
end-try;
&fileLog.WriteLine("End");
&fileLog.Close();
THE DATA IS FETECHED FROM MY CUSTOMISED TABLE BUT NOT COPIED IN TO MAIN TABLE,INSTEAD IT SHOWS EMPTY SPACE,BUT APP ENGINE RUNS TO SUCCESS,PLEASE HELP ME.
MY QUESTION I WNAT TO COPY THE DATA FROM ONE TABLE TO ANOTHER TABLE WHEN I RUN THE APP ENGINE WHICH CALLS AN CI
HELP ME PLEASE
Title | Under | Posted on |
---|---|---|
Component interface Error: no rows exist for the specified keys | PeopleSoft Technical | 03/15/2019 - 3:54am |
ADD 24 months starting from current month.(peoplesoft) | PeopleSoft Functional | 07/29/2018 - 8:44pm |
TRC values dropdown | PeopleSoft Technical | 04/04/2018 - 12:54am |
how to find missing sequence in GRID and print the mising sequence number while saving through peoplecode | PeopleSoft Technical | 09/11/2017 - 4:49am |
Did you see the delivered VNDR_IMPORT process?
Please don't keep posting the same question all over the place. I know you've asked the same questiong and below is the link
http://www.compshack.com/forum/peoplesoft/peoplesoft-technical/can-any-one-tell-me-how-to-insert-values-from-one-table-to-ano
You are not getting any data into your delivered table cause you have not finished the CI code. You can not just drag the CI over and expect it to work like magic. You need to go in and replace all [*] with the right field values and you need to remove the "rem" from infornt of the fields you want to assign values to!
Example:
rem &oBfHexVndrId.NAME2 = [*];
should be something like:
&oBfHexVndrId.NAME2 = &name2;
&name2 should be a value that you have assigned somewhere in your program and not anything you just made up!
Give back to the community and help it grow!
* Help with unanswered forum questions and issues
* Register or login to share your knowledge at your own blog
i know that i asked this question already,did u responded to this,and moreover this site is for asking question,so u no need to bother about asking question and u r not an dictator lepa.thanks for the reply
Hi,
I also have the same issue, have this is resolved.plz update for the same
Regards
Mak
Dictator? hahaha - you must be watching the news a lot lately. I'm sorry I came across that way, didn't mean to - welcome to the site and hope you get your issue resolved. Sorry again budd.
Give back to the community and help it grow!
* Help with unanswered forum questions and issues
* Register or login to share your knowledge at your own blog
As a matter of fact Lepa is the dictator here.. ;)
just kidding...
Ashar is right, I own this place. You do what I say or you are gone. I kind of like this kind of power, and i'm not stepping down - ha!
Give back to the community and help it grow!
* Help with unanswered forum questions and issues
* Register or login to share your knowledge at your own blog
LOL.. :P