How to read BP header data in standardaddress context node
Hi,
we have the next requirement in CRM 7.0 WebUI:
In view BP_ADDR/StandardAddress the field STRUCT.TELEPHONETEL should only be an input field if the authorization group of the business partner has a certain value. So I tried to solve this in the I-getter method for this STRUCT.TELEPHONETEL field by reading the authorization group and change the rv_disabled value.
How should I read the authorization group? This is field STRUCT.AUTHORIZATIONGROUP and belongs to the HEADER node.
Can you please supply me an example code for this?
Thanks in advance!!
Kind regards,
Roy Willems
Hi,
In the get_i method use the below code to get BuilHeader entity.
Data: lv_entity type ref to cl_crm_bol_entity.
lv_entity ?= collection_wrapper->current( ).
lv_entity ?= lv_entity->get_parent( ).
if lv_entity is not bound.
lv_authgrp = lv_entity->get_property_as_string( iv_attr_name = 'AUTHORIZATIONGROUP' ).
endif.
Regards,
Arun
Edited by: Arun Kumar on Aug 9, 2010 12:58 PM
Similar Messages
-
How to change order header data before SAVE in CRM 2007
Hi,
I want to modify service order header value before saving it, to achieve this :
1) Implemented BADI ORDER_SAVE
2) in the method CHECK_BEFORE_SAVE, read order details by using FM CRM_ORDER_READ and done all validations.
3) Now i want modify one field value. how to do that ?
i came to know that by using FM CRM_ORDER_MAINTAIN or CRM_ORDERADM_H_MAINTAIN_OW data can be update/modify.
Is this right ? what are the parameters i need to pass and exactly in which method i have use this FM.
I want to pass the value in CRMT_ORDERADM_H_WRK(ET_ORDERADM_H) structure i.e. only for one filed.
Please let me know how it can be done.
Thanks
BhanuHi,
I am using following code, please correct if it is wrong.
DATA : IS_ORDERADM_H_COM TYPE CRMT_ORDERADM_H_COM,
CT_ORDERADM_H TYPE CRMT_ORDERADM_H_COMT,
IT_INPUT_FIELDS TYPE CRMT_INPUT_FIELD_TAB,
WA_INPUT_FIELDS TYPE CRMT_INPUT_FIELD,
IT_FIELD_NAMES TYPE CRMT_INPUT_FIELD_NAMES_TAB,
WA_FIELD_NAMES TYPE CRMT_INPUT_FIELD_NAMES,
IT_SERVICE_H TYPE CRMT_SERVICE_H_COMT,
WA_SERVICE_H TYPE CRMT_SERVICE_H_COM.
After reading order header data from "'CRM_ORDER_READ", pass header data to below structure
MOVE-CORRESPONDING EW_ORDERADM_H TO IS_ORDERADM_H_COM.
IS_ORDERADM_H_COM-ZZFLD00000Y = '123456'. <== want to save value in this field created on service header screen by using AET
APPEND IS_ORDERADM_H_COM TO CT_ORDERADM_H.
WA_SERVICE_H-REF_KIND = 'A'.
WA_SERVICE_H-REF_GUID = EW_ORDERADM_H-GUID.
WA_SERVICE_H-MODE = 'B'.
APPEND WA_SERVICE_H TO IT_SERVICE_H.
WA_INPUT_FIELDS-REF_GUID = EW_ORDERADM_H-GUID.
WA_INPUT_FIELDS-REF_KIND = 'A'.
WA_INPUT_FIELDS-OBJECTNAME = 'ORDERADM_H'. <= Is this right ?
WA_INPUT_FIELDS-LOGICAL_KEY = ? what is nothing but logical key
WA_FIELD_NAMES-FIELDNAME = 'ZZFLD00000Y'.
WA_FIELD_NAMES-CHANGEABLE = 'X'.
APPEND WA_FIELD_NAMES TO IT_FIELD_NAMES.
WA_INPUT_FIELDS-FIELD_NAMES = IT_FIELD_NAMES.
APPEND WA_INPUT_FIELDS TO IT_INPUT_FIELDS.
CALL FUNCTION 'CRM_ORDER_MAINTAIN'
EXPORTING
IT_SERVICE_H = IT_SERVICE_H <= is this required ?
CHANGING
CT_ORDERADM_H = CT_ORDERADM_H
CT_INPUT_FIELDS = IT_FIELD_NAMES
EXCEPTIONS
ERROR_OCCURRED = 1
DOCUMENT_LOCKED = 2
NO_CHANGE_ALLOWED = 3
NO_AUTHORITY = 4
OTHERS = 5.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
awaiting for your replies
Thanks
Bhanu
Edited by: Bhanupracash on Apr 6, 2011 2:14 PM -
How can read BOM component date before save the production order??
Hi Experts,
In our company, we need to develop a program to read the BOM component data of the production order
before we save the production order.
That for example ,when we create and release a production order , before we save the production
order,we want a porgram to read the BOM component data. If some component data can meet our
requriement (may be if there is material requirement quantity>100 EA),then the system will pop up a
small dialog box to remind us.
There is user exit PPCO0007 and PPCO0007.But it seems they only can read the head data of the
production order before we save the production order. And the BOM component data of the production
order are saved in the RESB(Reservation Table).So if we do not save the production order,all the BOM
component data are not saved in the RESB table.
So how can slove the problem??
How can read component date before save the production order??
Are there any other user exit we can use???Hi Just wanted to check am I right that you are trying to check if you have enough Materials Available before you release or Save the order right ? if this is your business objective then when you create order you have material availability tab which checks and gives error if shortage is there. Please let me know if is this wht you asking for ?
-
Vc++ how to read column header of cursor
How to fetch the Column name or header of the stored procedure which is using a cursor as the output.
P_out out sys_refcursor
need to read the column name of this output.
I am using Vc++ code to reterive the data, in Vc++ how to read column header of cursorYou haven't provided much detail to go on. How are you reading data from the ref cursor? Do you already have a reader from it?
Maybe this helps.
Greg
create or replace procedure proc1 (v1 out sys_refcursor) as
begin
open v1 for select * from emp;
end;
using System;
using System.Data;
using Oracle.DataAccess.Client;
using Oracle.DataAccess.Types;
public class RefCur
public static void Main()
using (OracleConnection con = new OracleConnection("user id=scott;password=tiger;data source=orcl"))
con.Open();
using (OracleCommand cmd = new OracleCommand("proc1", con))
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add(new OracleParameter("v1", OracleDbType.RefCursor, ParameterDirection.Output));
cmd.ExecuteNonQuery();
using (OracleDataReader reader = ((OracleRefCursor)cmd.Parameters[0].Value).GetDataReader())
for (int i=0;i<reader.FieldCount;i++)
Console.WriteLine(reader.GetName(i)); -
How to display the header data on different position in alv report
hi all,
how to display the header data on different position in alv report.
for example ,
customer name
xxxx xxxx
vendor name street
xxxx xxxx xxxxx
pls help me .hi
as per my understanding you need to trnasfer header internal table data to pdf..
please check the following links for internal table to pdf..
Convertion of Internal table data to PDF
This link is related to ur issue
Re: how to insert the calling of the FM: OTF to PDF
Thanks -
How to read and write data in to a specified range of cells(it include multiple row & columns) in excel
CVI Comes with a sample project that explains how to read/write to a Excel file: choose "Explore examples..." in CVI welcome page and navigate to <cviSampleDir>\activex\excel folder where you can load excel2000dem.prj.
Proud to use LW/CVI from 3.1 on.
My contributions to the Developer Zone Community
If I have helped you, why not giving me a kudos? -
How to read Group ID from Value Mapping Context in Cache Monitoring ?
Hi friends,
In RWB --> Cache Monitoring --> Integration Server (Java) -> (Search for Value Mapping Groups) in this each item is identified by Value Mapping Group (GroupID, Context, Identifier/Agency, Identifier/Scheme). Either we create Value Mapping Table in ID or replicate value mapping data directly from text file/SAP table etc., in run time cache, data will be identified in this manner.
Now, our requirement is to delete a record the Cache for a particular context. Two operations provided by XI one is 'Delete' and another one is 'DeleteGroup'. When we use either of this, we should know GroupID. Suppose, I replicated some large amount of data from my text file in Runtime Cache. Value Mapping Table is like that IN --> India, US --> USA, AU --> Australia, EG --> Egypt. Now, I am required to write a program to get the input country code from user which is going to delete in the value mapping table like IN/AU.... For this, what logic we should follow in the program is, First we scan the value mapping table and find the record (country code) which is match with the input. Then find the GUID value for this record. Now we use the DeleteGroup Operation and pass this GUID and then delete the record.
So, in essence, how to read the GUID from value mapping context.
Friends, Kindly help me to do this.
Thanks in advance.
Jegatheeswaran P.Did you get the way to read group id?
-
How to search data from a context node.
Hi Friends,
Thanks for ur help for previous problem . I am facing some other problem i.e how to
search data from a context node.
i have a context node :-
Car(main node) which consist of details, owners, engine and Brand as its sub node.
the value attibutes of difft nodes are:-
Car- category
Details- Mileage, Price, registration_no, miles_used
owner - name, phnno,addrs
Brand - main_brand, co_brand
Engine- Bhp,Rpm
Now i have to apply a search criteria on the basis of price, miles_used .
pls help to implement that .
Thanks & regards
Pravin jhaHi PRAVIN,
What I can understand from your problem is that, you have a list with various properties and you want to display them and search them in your WD App. If I am correct, use the following approach:
Instead of using "details, owners, engine and Brand" Nodes, use the attributes inside the parent node. i.e in the node Car, add all the attributes viz. Mileage, Price, registration_no, miles_used, name, phnno,addr etc.
Now you can create a table of this node "Car" and can easily search on the basis of any criteria.
I hope this solves your issue. If you are looking for something else, please revert, I'll be happy to help you.
Cheers!!!
Umang -
Retrieve data from other context node within the same context
Hi Experts,
I want to redefine method BUILD_TABLE for a table context node and I need to access data from another context node within the same context. I have looked through the methods of class CL_BSP_WD_CONTEXT_NODE_TV but could not find a mean of retrieving the other context nodes.
Any ideas?
Thanks a lot. Your help is appreciated.
Cheers,
JensHi Jens,
Check this [wiki|http://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=201066680] it should be helpful.
Regards,
Shobhit -
Seeburger AS2 MDN: Reading AS2 Header DATE field
Hello,
in my AS2 scenario (using Seeburger Adapter) I forward MDN messages to PI. Now I have the requirement to read the "DATE" field of the MDN AS2 Header an map it to a target field.
In the XML message monitoring there are two payload messages:
AckReport (application/xml) and
RAWMIMEMDN (application/octet-stream)
In the message RAWMIMEMDN I see the header data and also the DATE field, now the question is, can I use the RAWMIMEMDN somehow to extract the DATE field?
Thank you for your input.Looks like this: (However I am not sure how to use it in mapping as there are two PAYLOADS entries in SXMB, I have not seen this in any other scenario before, I guess I only have access to the XML part):
AS2-VERSION: 1.2
CONTENT-TYPE: multipart/report; report-type=disposition-notification; boundary="----=_Part_372_22591582.1258028532189"
AS2-TO: xxxxxx
FROM: xxxxxx
CONTENT-LENGTH: 798
AS2-FROM: xxxxx
MIME-VERSION: 1.0
SERVER: xxxxxx
MESSAGE-ID: <xxxxxx>
DATE: Thu, 12 Nov 2009 12:22:12 GMT
EDIINT-FEATURES: CEM
=_Part_372_22591582.1258028532189
Content-Type: text/plain; charset=us-ascii
This MDN (Message Disposition Notification) was automatically built on
Thu, 12 Nov 2009 12:22:12 GMT in response to a message with id
xxxxxx received from
xxxxx on Thu, 12 Nov 2009 12:22:10 GMT.
Unless stated otherwise, the message to which this MDN applies
was successfully processed.
=_Part_372_22591582.1258028532189
Content-Type: message/disposition-notification
Original-Recipient: rfc822; xxxx
Final-Recipient: rfc822; xxxxx
Original-Message-ID: xxxxx
Disposition: automatic-action/MDN-sent-automatically; processed
Received-Content-MIC: fzj1sSC/z3kmTWhfA6NaIQ==, md5
=_Part_372_22591582.1258028532189-- -
How to read file header/open filein binary mode
i am using FileConnenction API to read from a file. how can i open a file in binary mode so that i can read file header. In other words i want to open a file in binary mode.
You can always try looking at the [Header Signatures|http://www.techpathways.com/uploads/headersig.txt]. But it would probably be easier to adjust your application so it doesn't have to guess.
~ -
How to read the header of an FLV 1.1 file?
I would like to read the header of an FLV file and determine
if it's an FLV 1.1 file, and if so, get it's length. (Without
downloading the entire file. ) How do I do this?bump
-
How to read File Header in JAVA
I wanna upload a(doc/pdf) file from client site, where I hv to check whether the the file is originally a doc/pdf file or not, I mean not just the extension, but the actual header information of the file. Please some body help me to do this, I dont know how to read the file header. Thnx in advnc.
You can always try looking at the [Header Signatures|http://www.techpathways.com/uploads/headersig.txt]. But it would probably be easier to adjust your application so it doesn't have to guess.
~ -
How to read fieldcatalog of Data Entry View in CAT2
Hi,
I have a requirement wherein I need to validate the time data of 'Data Entry View' in TCode: CAT2. Here, there is a table control which uses dynamic field catalog (for days Eg: MO 11/07, TU 11/08.....SU 11/13).
Whenever a user enters the 'Key Date' from CAT2, the system automatically gets the Data Entry Period of that Key date.
For eg, let's say user enters Key date as '11/28/2011' then the Data entry period would be 11/28/2011 to 12/04/2011.
Requirement: Now the system should allow the user to enter time for November month only i.e. 28, 29 and 30. It should not allow the user to enter time data for December. In short the system should allow the user to enter times of only one month.
For this validation I'm using the User Exit: CATS0006 . Please suggest me how to read the above fieldcatalog,
And also let me know if this can be achieved by any other method.
Thanks,
SinghThanks Raymond. The problem is solved.
Below is some part of the logic...
Work area declaration
DATA: wa_check_table TYPE cats_comm.
Variables
DATA: w_cnt TYPE i.
Get the no. of records
DESCRIBE TABLE check_table LINES w_cnt.
Read the last record
READ TABLE check_table INTO wa_check_table INDEX w_cnt. "We can loop also
IF dateto4(2) GT datefrom4(2).
IF wa_check_table-workdate4(2) GT datefrom4(2).
MESSAGE e208(00) WITH text-001. "Appropriate Error Message
ENDIF.
ENDIF. -
How to read a byte data from maxdb data base
Dear All,
I have a issue in reading the data from database table.
I have a column named as templateData which contains the byte data (biometric template data, which comes from fingerprint device) which is DataType of LONG and CODE of BYTE.
I am not using the below to get the template data
Connection con = null;
Statement stmt = null;
ResultSet resultSet = null;
byte[] DbBioData = new byte[1024];
InitialContext ctx = new InitialContext();
if(ctx == null)
throw new Exception("Boom - No Context");
DataSource ds = (DataSource)ctx.lookup(db_drvstr);
con = ds.getConnection();
stmt = con.createStatement();
resultSet = stmt.executeQuery(db_query + " where SUBJECT_ID='"+ username +"'");
if(resultSet.next())
DbBioData = resultSet.getBytes(1);
_loc.infoT("verify", "verify::Got BioData From MAXDB" +DbBioData );
loc.infoT("verify", "verify::Query is: " +dbquery + " where SUBJECT_ID='"+ username +"'" );
But I am not getting the proper data, could anyone please tell me the way to read the biometric data from data base table.Hi Kishore,
is it me or is there no query definition in that code?
I see that you concatenate a "db_query" with a string to make up a WHERE clause, but the db_query is nowhere defined before.
So at least you should provide something like
stmt = con.createStatement("SELECT templateDate FROM <tablename> ");
before you do anything with the query.
Besides this: have you ever heard of SQL injections? Try to use BIND-variables instead of concatenating strings. Otherwise your application will spend much time just with parsing your queries...
Hmm... possibly the best thing you could do about this is to read the JAVA manual for MaxDB:
<a href="http://maxdb.sap.com/currentdoc/ef/2de883d47a3840ac4ebb0b65a599e5/content.htm">Java Manual (SAP Library - Interfaces)</a>
Best regards,
Lars
Edited by: Lars Breddemann on Dec 17, 2007 1:12 PM - corrected link
Maybe you are looking for
-
I purchased the Yoga Pro 2 on Thursday October 17. I love the computer for so many reasons, (especially since it replaces my 4 year old Compaq that was 6.5lbs!) however, I am also having a few issues with it. It is the i7/8GB/256GB model from BestBuy
-
Hello I purchased Photoshop CS2 in 2006. for Macintosh. Now I changed the Maverick version 10.9. But now I do not know where to download the same version, so I use bought in 2006 key. When pulled CS2 can not install it because my version is higher.
-
I have a Mini (2009) with a 120 GB hard drive and I want to replace with the largest drive a Mini will take. Is there a maximum hard drive size this thing will handle and if so what is it? Thanks.
-
'FOR ALL ENTRIES' in SELECT statements
Hi, I got a doubt in working of the 'FOR ALL ENTRIES' option in the SELECT statement. Here is my scenarion. Table A - Document Header Level (Key: Doc Number) Internal Table B - Document Item level (Keys: Doc num and Doc Item). So, for each record in
-
How can I use the terminal to upgrade my old macbook to linux
My old mb 1/1 white....is obsolete, but i'd like to use it in linux, because I can still upgrade it to the latest distro......