Mapping Help for replacing source value
Mapping Help for replacing source value
Posted: Mar 14, 2006 1:06 AM Reply
Hi all,
I am unable to do transform the source value to required target value,
From Source ADDRESS_TYPE = 'HOME' should be replaced with 03 to target field ANSSA, and 'MAIL' to be replaced with 05, I am trying to do it but i am unable to handle it, please give u r valuable suggestions,
The source structure is like this,
- <Event ID="239" TRANS_TYPE="ADR">
<PersAddr GEO_LOC_CD="US" EMPLID="29" ADDRESS_TYPE="HOME" EFFDT="02/15/2006" ADDRESS1="92nd Floor" ADDRESS2="812backstreet" ADDRESS3="" ADDRESS4="" CITY="London" COUNTY="" STATE="AN" POSTAL="EC2N 4AG1" COUNTRY="GBR" KEY1="29" KEY2="HOME" KEY3="02/10/2006" />
<PersAddr GEO_LOC_CD="US" EMPLID="29" ADDRESS_TYPE="MAIL" EFFDT="02/15/2006" ADDRESS1="92nd Floor" ADDRESS2="812backstreet" ADDRESS3="" ADDRESS4="" CITY="London" COUNTY="" STATE="AN" POSTAL="EC2N 4AG1" COUNTRY="GBR" KEY1="29" KEY2="MAIL" KEY3="02/10/2006" />
</Event>
REGARDS,
sridhar
Hi,
This can be done using user-defined function as well.
Code the function as...
if(Addr_Type.equals("HOME"))
return "03";
else if(Addr_Type.equals("MAIL"))
return "05";
else
return "Invalid Address Type";
Here, Addr_Type is Input String Argument for this function.
Map this function between ADDRESS_TYPE and ANSSA.
Regards,
Uma
Similar Messages
-
Add custom field in the F4 help for selecting source field in tcode FMDER
HI,
I an working in FUND MANAGEMENT, i want to add custom field in the F4 help for selecting source field in t-code FMDERIVE.
How this possible.
Regards,
PankajOK
-
Need Mapping Help: Generate index if value comes
Hi Experts,
I need mapping help to generate index if value comes form source. we have 4 fields in item level of source and target side we have to pass the these filed values and sequence number.
below given the structures:
Source: Target:
Item Item
A1 Text
A2 Seq_No
A3
A4
my requirement is if A1 filed values comes from source we should pass to text and pass seq_no to constant-1, same as A2,A3 and A4 filed values also we should pass to text and seq_no for A2 is 2 and A3 is 3 and A4 is 4. suppose if A1 value is not coming from source we should pass seq_no for A2 is 1. if A1 and A3 filed values are not coming from source then we should pass seq_no for A2 and A3 are 1 and 2.
can you please help me how to achieve this. appreciate for your support.
Regards,
Sanjay.Hi Sanjay,
you can try this mapping
1. Generate the target 4 ITEM's by duplicating the subtree as shown below 3 times.
Now create the each target item starting from first by mapping them to A1,A2,A3 and A4 respectively. I have shown the first ITEM mapping above. similarly you can map A2 to ITEM[1],
A3 to ITEM[2] and A4 to ITEM[3].
2. Now you can map the A* fields to Text one to one as shown below
Please repeat the same for A2,A3 and A4 to respective Text fields.
3.
First seq_no field as shown
and similarly others as shown
Regards
Anupam -
Hi Experts,
I need help in mapping. All mapping is working fine. I am getting issue when mapping comment field to only BOX when it occurs multiple times.
Actually I am getting correct lines in queue , but it is not mapping correctly, It consider lines from first MIXPLT.
Target Structure:
BOX 0.n Z1WHCUSTC when Z1WHCONS is initial
++LIne 0..n Z1CUSTCD
++++Comment 0...n Z1WHCMTH
MIXPLT 0...n Z1WHCONS
BOX 0..n Z1WHCUSTC when Z1WHCONS is not initial
++LIne 0...n
++++Comment 0...n
Source Structure:Hi Ranj,
Did you import Idoc or Idoc xsd ?
If you imported xsd, open external definition IDoc check for errors like below.
I think the problem might be with source xml structure.
Regards,
Krupa -
Hallo!
I have a question for you!
I have a PowerMac G5 (2003) with cpu PPC G5 970 (v.2.2) 2GHz as seen in System Profiler;
My Mac is a Dual processor, but one CPU is brocken and today it runs with only one CPU.
Now I want to buy the second CPU in ebay, to replace the second CPU broken, but I can't find nothing of clear in apple part number, in fact I Have a CPU 630-4890.
Reading service manual I think that I must search a 661-2901, but i don't know if this is correct!
There is someone that can help me in this choice?
Thank a lot!
PaoloLook at the model number like the other member said to do . But it you change out the cpu yuo need to re calibrate the fans on it . You need the dvd that will re calibrate the fans for the new processor . The apple service diagnostic disk or better know as the thermal calibration of the fans . Thats a must or I think you will burn up the new processor .
get a service manual plus the disk I told you about . Goto ebay for that . -
Search help for a particular value
Hi ABAP gurus,
Suppose i have 2 fields in Selection-screen i.e Plant and Material, Plant have 3 values say 1000,2000,3000.Whenever user enter 1000 and Press f4 in Material field then all the material values related to plant 1000 should be displayed,Similarly with value 2000 & 3000.
Thanks in advance
Sumit Kumar Sharmahi sumit.
in report if you want search help based on another selection screen field value then you need to one function module to capture selection screen field value. i.e DYNP_VALUES_READ.
the following is the example program please go though for this no need of enter.
*Structure declaration
TYPES: BEGIN OF ty_posnr,
vbeln TYPE vbeln,
posnr TYPE vbap-posnr,
END OF ty_posnr.
*internal table creatioin
DATA:t_posnr TYPE STANDARD TABLE OF ty_posnr INITIAL SIZE 0.
DATA: t_dyn TYPE TABLE OF dynpread,
w_dyn TYPE dynpread.
DATA: g_vbeln TYPE likp-vbeln,
g_posnr LIKE vbap-posnr.
*Selection screen
SELECTION-SCREEN BEGIN OF BLOCK b1.
SELECT-OPTIONS: s_vbeln FOR g_vbeln NO INTERVALS NO-EXTENSION ,
s_posnr FOR g_posnr NO INTERVALS NO-EXTENSION .
SELECTION-SCREEN END OF BLOCK b1.
*At selection screen on event
AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_posnr-low.
PERFORM f4_help.
*& Form f4_help
* text
FORM f4_help .
w_dyn-fieldname = 'S_VBELN-LOW'.
APPEND w_dyn TO t_dyn.
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
dyname = sy-repid
dynumb = '1000'
* translate_to_upper = 'X'
* REQUEST = ' '
* PERFORM_CONVERSION_EXITS = 'X'
* PERFORM_INPUT_CONVERSION = 'X'
* DETERMINE_LOOP_INDEX = ' '
* START_SEARCH_IN_CURRENT_SCREEN = ' '
* START_SEARCH_IN_MAIN_SCREEN = ' '
* START_SEARCH_IN_STACKED_SCREEN = ' '
* START_SEARCH_ON_SCR_STACKPOS = ' '
* SEARCH_OWN_SUBSCREENS_FIRST = ' '
* SEARCHPATH_OF_SUBSCREEN_AREAS = ' '
TABLES
dynpfields = t_dyn
EXCEPTIONS
invalid_abapworkarea = 1
invalid_dynprofield = 2
invalid_dynproname = 3
invalid_dynpronummer = 4
invalid_request = 5
no_fielddescription = 6
invalid_parameter = 7
undefind_error = 8
double_conversion = 9
stepl_not_found = 10
OTHERS = 11
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CLEAR w_dyn.
READ TABLE t_dyn INTO w_dyn WITH KEY fieldname = 'S_VBELN-LOW' .
IF sy-subrc = 0.
SELECT vbeln
posnr
FROM vbap
INTO TABLE t_posnr
WHERE vbeln = w_dyn-fieldvalue.
ENDIF.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
* DDIC_STRUCTURE = ' '
retfield = 'POSNR'
* pvalkey = ''
dynpprog = sy-repid
dynpnr = '1000'
dynprofield = 'S_POSNR-LOW'
* STEPL = 0
* WINDOW_TITLE =
* VALUE = ' '
value_org = 'S'
* MULTIPLE_CHOICE = ' '
* DISPLAY = ' '
* CALLBACK_PROGRAM = ' '
* CALLBACK_FORM = ' '
* MARK_TAB =
* IMPORTING
* USER_RESET =
TABLES
value_tab = t_posnr
* FIELD_TAB =
* RETURN_TAB =
* DYNPFLD_MAPPING =
* EXCEPTIONS
* PARAMETER_ERROR = 1
* NO_VALUES_FOUND = 2
* OTHERS = 3
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " f4_help
It will work fine. If you satisfied give points.
regards.
laxman -
Different mapping programs for same source and target
Hi All,
I have to map the incoming idoc to xml messages.
But based on customer numbers in incoming idoc i have to use different mapping programs and map to same xml messages.
1 source message - n mapping programs - 1 target message
(based on cust numbers)
I dont want to harcode the customer numbers to find out the mapping programs.
Can anyone guide me in this on how to achieve this functionality...
thanks
GiridharHi,
have you tried to use Conditions in the Interface Determination?
You can add multiple lines in the 'Configured Inbound Interfaces' and attach different mappings to each of them by picking a condition (basically using an XPath Expression).
Check this Help Document,
the section 'Multiple Identical Inbound Interfaces with Conditions' describes what I believe is your scenario.<a href="http://help.sap.com/saphelp_nw04s/helpdata/en/42/ea20e737f33ee9e10000000a1553f7/frameset.htm">Multiple Identical Inbound Interfaces with Conditions</a>
regards,
Peter -
Need help for Data source 0CRM_TRPR_ATTR
Hello Friends,
We have 0CRM_TR info object and it contains attribute 0CRM_TR_ATTR ,Text 0CRM_TR_TEXT and Hier . For this attribute we are not getting multiple employee assigned to one territory, so SAP suggested us to use 0CRM_TRPR_ATTR data source.
I am using this and can able to see multiple employees at PSA level but when i load it into info object level its taking one employee. I don't want to use the option Compounding at info object level because this 0CRM_TR info object is using in Multi providers, cubes, infosets, ODS.
Please help me out how to get multiple employees at Info object level.
Thanks,
Devi.Hi Adarsh,
Please check the infoobject 0CRM_MKTELM which will laod data from 0CRM_MKTELM5_ATTR.
Please go through following link.
Load Sequence - SAP for Utilities: Documentation for Solution Manager Content - SAP Library -
3d graph color map help for cvi
I've plotted my data to a 3d graph using CW3DGraphLib. The data I am most interested in is the highest 10%. I can change the Z axis to only show this 10%, but the colors are all red. I would like to modify the color map so it maps only the data that I set in the max and min scale. 90 to 100%. Does anyone know how to do this? Also, I am looking for any additional help files on the CW3DGraphLib. When you click on the function panel it says no help file available.
Hello Keith,
I think the following forum will be helpful.
http://forums.ni.com/t5/LabWindows-CVI/the-method-CW3DGraphLib-DCWGraph3DPlot3DCurve-does-not-work/t...
Daniel -
Pipeline component for replace the values in send pipeline 837P
hi friends,
I am working in 837P splitting the claims.When i am sending using sendpipe line.
I need pass the 2010bb loop NM103 and NM109 defaluts values,
ex: NM103=100,NM109=0123456789
like can you help me write pipeline component to manipulate the XPath and replace the default values.
THanks
hkyou will need to extract data from the message coming on your receive location.
You can create two diffferent function which can do your task.
The first one is to get the stream from the message and create a seekable one to be used later on.
private Stream GetMessageStream(Microsoft.BizTalk.Message.Interop.IBaseMessage msg, Microsoft.BizTalk.Component.Interop.IPipelineContext context)
Stream stream = msg.BodyPart.GetOriginalDataStream();
if (!stream.CanSeek)
ReadOnlySeekableStream readStream = new ReadOnlySeekableStream(stream);
if (context != null)
context.ResourceTracker.AddResource(readStream);
msg.BodyPart.Data = readStream;
stream = readStream;
return stream;
The second method is the one that would perform the data extraction as follows.
private string ExtractDataValueXPath(Stream MsgStream, string MsgXPath)
XmlReaderSettings settings = new XmlReaderSettings()
ConformanceLevel = ConformanceLevel.Document,
IgnoreWhitespace = true,
ValidationType = ValidationType.None,
IgnoreProcessingInstructions = true,
IgnoreComments = true,
CloseInput = false
MsgStream.Seek(0, SeekOrigin.Begin);
XmlReader reader = XmlReader.Create(MsgStream, settings);
string strValue = null;
if (!string.IsNullOrEmpty(MsgXPath))
if (reader.Read())
XPathDocument xPathDoc = new XPathDocument(reader);
XPathNavigator xNavigator = xPathDoc.CreateNavigator();
XPathNodeIterator xNodes = xNavigator.Select(MsgXPath);
if (xNodes.Count != 0 && xNodes.MoveNext())
strValue = xNodes.Current.Value;
MsgStream.Seek(0, SeekOrigin.Begin);
return strValue;
You can update the node with the Xpath of the element.
Thanks
Abhishek -
I want to manually modify something in our ERP system. But I find some fields in table which is in date type have the value '0000-00-00'. How can I insert the same value to the database?
Our DBMS is oracle 816.
SQL> select to_char(t$curd,'yyyy-mm-dd hh:mi:ss') from triton.ttdsls051702
2 where
3 t$orno = 104497;
TO_CHAR(T$CURD,'YYY
0000-00-00 00:00:00
0000-00-00 00:00:00
0000-00-00 00:00:00
SQL> select to_date('0000-00-00' , 'yyyy-mm-dd') from dual;
select to_date('0000-00-00' , 'yyyy-mm-dd') from dual
ERROR at line 1:
ORA-01843: not a valid month
Please offer me some help. Thank you!Oracle has some funny ideas about dates. I tried this on 8.0.6, 8.1.7 and 9.0.1.
SQL> SELECT TO_CHAR(TO_DATE('01-01-0001','dd-mm-yyyy'),'j') FROM dual;
TO_CHAR
1721424
SQL> SELECT TO_CHAR(TO_DATE('1721423','j'),'dd-mm-yyyy') FROM dual;
SELECT TO_CHAR(TO_DATE('1721423','j'),'dd-mm-yyyy') FROM dual
ERROR at line 1:
ORA-01841: (full) year must be between -4713 and +9999, and not be 0
but ...
SQL> SELECT TO_CHAR(TO_DATE('1721424','j')-1,'dd-mm-yyyy') FROM dual;
TO_CHAR(TO
00-00-0000
again but...
SQL> CREATE TABLE t (dt DATE);
Table created.
SQL> INSERT INTO t SELECT TO_DATE('1721424','j')-1 from dual;
1 row created.
SQL> ALTER SESSION SET nls_date_format = 'dd-mm-yyyy';
Session altered.
SQL> select * from t;
DT
31-12-0000
yet again but ...
SQL> SELECT TO_CHAR(dt,'dd-mm-yyyy') FROM t;
TO_CHAR(DT
00-00-0000I think it is probably safe to set those dates to null, or some other acceptable default value depending on what t$curd means in your application.
TTFN
John -
Need Help for Replacement ASAP
Hi Guys
I need to calculate the nr of days between the current date and the Posting date . I have the char available (posting date) .
I have the req : CURRENT DATE POSTING DATE WHERE payment block is not initial. If I want to calculate this in Query I have Current date variable and Posting date variable for the formula when I calculated , its working fine. But If I want to restrict it with payment block not equal to # then its not working. I mean the result am getting is not restricting by payment block. Can any one let me know what might be the problem
RegardsHello,
Try to put payment block in the filter and exclude it.
Also there is a correction in 2004s Note 1047688 - Query returns no data (including and excluding selection)
https://service.sap.com/sap/support/notes/1047688
Happy Tony -
Mapping multiple source value to one target value in value mapping
Hello experts,
In my scenario, i need to map more than one source value to one target value in value mapping. Like:
1 TenderPickup
2 TenderLoan
7 TenderPickup
101 TenderPickup
102 TenderLoan
107 TenderPickup
But when I enter the same target value for the second time and try to save it, it gives me an error saying value mapping already exists.
But this should logically be allowed. How can this be done. Please provide a solution.
Thanks,
YashHi Prabhu,
When i right click on the target field, it gives me only 3 options:
1) Insert Row
2) Delete Value Mapping
3) Value Mapping in all agencies
I dont see nay option for duplicating rows.
What I hae done is in ID i clicked on TOOLS and then VALUE MAPPING. I checked the option "Value Mapping Agencies" and gave my source and target agencies detials. Then i clicked on DISPLY and in the next page I have 3 columns - Value for <source agency>, Value for <target agency> and Group name.
When I give duplicate values in the column Vlaue for <target agency>, it doesnt allow me to and if i right click in this column, i get the above mentioend options.
Please point out where i m going wrong.
Thanks,
Yash -
Data source value for data source reportData was null
hi i'm using struts 2 and jasperreports my problem is
it generate a pdf file with labels but no data in it..
and when i try to look at the logs of my sun application server
it says Data source value for datasource reportData was null.
reportData is an ArrayList of Personnel object.
here is my code..
public class EIS_HR_004_JASPER extends eisSupport {
private String reportId;
private String dateStart = null;
private String dateEnd = null;
private String pdfFile;
private final static String _REPORT_FOLDER = "EIS_HR_003";
private Report thisReport;
private String dateRange;
private ArrayList<Personnel> reportData;
public String execute(ActionMapping mapping,ActionForm form,
HttpServletRequest request, HttpServletResponse response)
throws Exception {
ReportBean reportBean = new ReportBean();
setThisReport(reportBean.getReport(getReportId()));
reportData=new ArrayList<Personnel>();
Personnel p1=new Personnel();
p1.setSurname("Dela Cruz");
p1.setFirstname("Juan");
p1.setExamcode("CSC111");
p1.setExamdate("January 1,2003");
Personnel p2=new Personnel();
p2.setSurname("Cruz");
p2.setFirstname("Miguel");
p2.setExamcode("CSC222");
p2.setExamdate("December 2,2003");
reportData.add(p1);
reportData.add(p2);
try {
JasperCompileManager.compileReportToFile(
"apps/reports/templates/hr004.jrxml",
"apps/reports/templates/hr004.jasper");
} catch (Exception e) {
e.printStackTrace();
return ERROR;
return SUCCESS;
public ArrayList<Personnel> getReportData() {
// setReportData();
return reportData;
here is part of my struts.xml
<action name="EIS-HR-004_JASPER" class="eis.report.EIS_HR_004_JASPER">
<result name="error">/apps/reports/ReportNotFound.jsp</result>
<result name="success" type="jasper">
<param name="location">apps/reports/templates/hr004.jasper</param>
<param name="dataSource">reportData</param>
<param name="format">PDF</param>
</result>
</action> i dont know why it doesnt retrieved the data from the ArrayList?
please help me..Thanks in advance.Hi,
Looking at the code, it seems you are compiling a JRXML and that is all.
Instead, you should fill it with data and then export the result to PDF.
No wonder you don't see any result.
You need to learn more about how JasperReports work. For a start, I can tell you that you could compile JRXML files as part of the application build process using an Ant task, and not dynamically, like you did. But no matter how you compile the report template, you actually need to fill it with data, using the JasperFillManager and then export it to PDF using the JasperExportManager.
You can see all this in our samples in the /demo/samples folder that is part of our project distribution package. There is even a sample Web application in the /demo/samples/webapp folder.
I hope this helps.
Teodor -
BW1 transaction for mapping newfield to data source in CRM
Hi,
This will be BW gurus working in the CRM Opportunity area.
Based on my current understanding I have copied the 0CRM_OPPT_H into ZCRM_OPPT_H and wanted to see whether I can map more partner function to map to the data source.
Currently, the following fields are offered by the SAP Delivered data source 0crm_oppt_h in CRM.
PARTNET FUNC DATA source field BDOC Mapping bwa1
IN CRM 0crm_oppt_h
Contact person contact_person PARTNER-PARTNER_NO
<NOT used> EXECUTING_CC PARTNER-PARTNER_NO
configured PF COMPETITOR PARTNER-PARTNER_NO
Emp responsible PERSON_RESP PARTNER-PARTNER_NO
Sales Prospect PROSPECT PARTNER-PARTNER_NO
SALES_EMPLOYEE Employee PARTNER-PARTNER_NO
Currently we have configured 4 more partner functions for our opportunity transaction, which are not available in the 0CRM_OPPT_H data source. However we shall need these fields to send to BW.
How can we extend the mapping in BWA1 after extending/appending the extraction structure (CRMT_BW_OPPT_H) of the data source? Shall we continue to map these addition fields in the data source to PARTNER-PARTNER_NO as mentioned above? What puzzles us that this is header info and the PARTNER_NO is able to bring info for different partner func.. How this is being possible?
If we also map the same for the additional partner fields will we be able to aviod the BADI/User exit and the code associated that populated these fields?
What is the BKM? How the BWA1 can be used for Extending for more partrner( functions?)
Thanks
AGNHi Aswin,
while this is really helpful to enable me to dig into further, the basic question is not yet answered.
Currently the data source 0CRM_OPPT_H are able to extract the following partner data
contact person
prospect
channel pertner
empoyee responsible
However only one( contact person 00000017) is mentioned in our CRM system in the SPRO steps that you have shown.. My first question is how then the data source is able to get the other partner function....
2> Secondly even if I mention all the partner functions in that transaction( as you have mentioned) how do the data source really know where to populate which partner function data.. since the bdoc mapping is Partner-partne_no...
For example if I maintain the following in SPRO
00000017 contact person
00000026 emplyee responsible
How do the data source gets rightly populated ( contact person value in the contact_person field and vice versa).. when the BDOC Mapping for both these two fields are simply partner-partner_no?
Appreciate a detail explanation from you on this.
Thanks
AGN
Maybe you are looking for
-
Trouble calling functions in PHP
I am trying to get around this problem that I have been stuck on so as to call a function in the $videoSQL list that uses an array list from a database. Any help would be appreciated.
-
No records in main.active table?
I just updated my Muse, made a few changes to my site and saved. While saving, Muse crashed. Now when I try opening the site I receive the message "This Adobe Muse site file cannot be opened. no records in main.active table"? I freaking out here a li
-
Parsing String to XML Attribute bug
Hello! I'm trying to convert String to org.w3c.dom.Document with javax.xml.parsers.DocumentBuilder, but when I check my XML Document after creating, I find that all the Attributes are like "" or " ". Does anyone have some idea why that problem is and
-
How can I delete the iTunes photo database?? on mac os
I just got a ipod and thought it would be fun to have all my pictures on it... not knowing that itunes makes a complete copy of all my pictures (25gb) in iphoto: iTunes constructs a photo database on your hard drive in order to make photo syncing fas
-
THX 5.1 550 Power Light Flashing
I recently posted that the fuse had blown on my Cambridge Soundworks THX 5.1 550 speakers. Well, I replaced the fuse and now there is no power to the speakers and the green light on the rear of the Powered Subwoofer is flashing on and off. I suspect