Issue while moving from string to field symbol -- waiting for help
Hi Abap Experts,
At present I got stucked here at client place. Please help me . Thanks in advance.
I have a structure in field symbol. I also have data in the string (rec ty )
I need to move it to corresponding fields in the field symbol. While moving, it is giving a dump.
data:linetype type string,
struc type ref to DATA.
field-symbols: <fs> type any.
linetype = i_strucname.
" Get internal table and attach the field-symbol
CREATE DATA struc type standard table OF (linetype).
ASSIGN struc->* TO <fs>.
<fs> = string. (dump is occuring here)
Hi,
My code:
data:linetype type string,
struc type ref to DATA.
field-symbols: <fs> type any ,
<f1> type any .
linetype = i_strucname (Z structure)
" Get internal table and attach the field-symbol
CREATE DATA struc type standard table OF (linetype).
ASSIGN struc->* TO <fs>.
I need to populate the Z structure at runtime with the appropriate field values from the string.
for example:
input: abc \ \xyz
structure: first ffield length 10, " MY Z STRUCTURE
second field length 5
third field length 10.
output: abc xyz
I get the structures dynamically.
Similar Messages
-
Issue while migrating from File to DB based repository for SAP adapter
Hi
I recently migrated from file based repository to DB based repository.
SAP Adapter: DB repository for JCA configuration
After that I created the new targets and the jca log file showed me correct entry saying that it read from DB repository.
Thread[Thread-6,6,main] [info ] Repository URL 'jdbc:oracle:thin:@db_host:1521/fmwdbqa' resolved to repositoty type: oracle
But when I restarted the weblogic server I observed that it is again reading from the file repository.
Thread[[ACTIVE] ExecuteThread: '3' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads] [info ] Repository URL 'file:///opt/apps/Oracle/Middleware/Oracle_SOA1/soa/thirdparty/ApplicationAdapters/config/XYZ/repository.xml' resolved to repositoty type: file
Any reason why this is happening? Any other setting required to avoid this?
Regards
SubhankarHi Manoj
I checked the web.xml under MW_HOME/Oracle_SOA1/soa/thirdparty/ApplicationAdapters/iwafjca.war/WEB-INF folder. The iway.jndi is set to below :
<param-name>iway.jndi</param-name>
<param-value>eis/OracleJCAAdapter/DefaultConnection</param-value>
I checked the outbound connection settings from Admin console under below path
Home >Summary of Deployments >iwafjca > configuration
I can see that the properties IWayRepoURL, IWayRepoUser and IWayRepoPassword are set to blank here. Where exactly are these property values picked from ? Or do I need to manually edit it here in admin console itself?
Regards
Subhankar -
Problem: Focus got lost, while moving from one cell to another cell using tab key.
Example: In an AdvanceDataGrid, there are three columns having custom ItemRenderer with Spark TextInput control (editable=true & focusEnabled=true).
When I try to move the focus in with in 2nd, 3rd & 4th column using tab key, focus got lost. Most of the time it’s working, but some time it doesn’t work. There’s no clue as to how may rows/columns the focus has jumped to; or whether the focus has gone out of the data grid altogether.
Observations: I am not sure whether this problem is because of custom component implementation or it is because of some issue related to Flex Component.
It only occurs when we perform some actions like some server call, some complex logic execution etc. at the focus out event of itemrenderer.
There is one property of datagrid i.e. editedItemPosition which contains row & column index of datagrid. On the focus out event, it gets null when focus got lost. We tried to set it, but it didn’t work.
Steps Performed:-
1. Currently focus is in 2nd column i.e. Apply to #.
2. Once I press tab key from 2nd column, it goes to 3rd column which is correct.
3. Now if I press tab key from 2nd column i.e. Payment #, focus should go to 3rd column, but it goes out of data grid and set the focus of button which is outside data grid.http://search.java.sun.com/search/java/index.jsp?qp=&nh=10&qt=%2Bjtable+%2Btab+%2B%22enter+key%22&col=javaforums
-
Issue while connecting from Biztalk adapter to SAP ECC 6.0
Hi Friends
Issue while connecting from Visulal Studio 2005 to SAP ECC 6.0 throgh Biztalk adapter2.0, even if we pass the correct login details, system is throwing an error like incorrect user/password.
Can you please tell anybody the solution for this.
Regards
PraveenHI,
is there a special "formation" to put in the user / pass ?
maybe a missing domain ? or missing values like "/" or "\" ?
Do you getting this error in the Biztalk Monitor (Visual 2005) ? -
What are the things we need to take care while moving from 11g to 12c.
Dear All,
One of my client having the application running on 11g and now he wants to move it on 12c.
Now he is asking to me that, what are the things will not work or impacted due to this. Any code level changes, syntax, functions etc are working in 11g and now there is difference or not working in 12c. Could you please help me in this.
Is there any document for all these thing. I searched on google but not able to find any specific doc.
Thanks in advance.
Regards,
ganeshGaurav_91 wrote:
Hi,
Moving from 11g to 12c will not impact anything.
Database in 11g will now act as PDB's in 12c.
And what makes you say so? What about the changes/fixes done in the optimizer that would alter the plans? What about if the client wants to use in-memory database option? And your statement that database in 11g will now act as PDB in 12c doesn't make any sense. What if the client is not willing to move to multitenancy? What about the scripts that are running in 11g without any issues and suddenly, will break in 12c due to PDB's ? Do you have any technical reference to validate your claim that there won't be any impact ?
Aman.... -
How to populate one internal table from another using field symbols
Hi Gurus,
I have a problem. I have to populate one internal table (sructure t_otput) from another internal table (sructure t_from) using field symbol.
Structure for from table.
types: begin of t_from,
year(4) type c,
ww(2) type c,
site type marc-werks,
demand type i,
end of t_from.
Structure for output table.
types: begin of t_display,
title(30),
WW1(10),
WW2(10),
WW3(10),
end of t_display.
The from table looks like this:
Year | WW | Site | Demand
2005 | 1 | OR1 | 12.00
2005 | 2 | OR1 | 13.00
2005 | 3 | OR1 | 14.00
The display table which has to be populated should look like this:
Title | WW1 | WW2 | WW3
OR1 | | |
Demand | 12.00 | 13.00 | 14.00
How to populate display table using field symbol?
Please give code snippets
Thanks,
GopalGopal,
Here is the code, however I am not vary clear about the ORG1 and Demand display that you have shown in the display. I am sure with this code it should not be a big deal to tweak in whatever manner you want.
TABLES : marc.
TYPES: BEGIN OF type_display,
title(30),
ww1(10),
ww2(10),
ww3(10),
END OF type_display.
TYPES: BEGIN OF type_from,
year(4) TYPE c,
ww(2) TYPE c,
site TYPE marc-werks,
demand TYPE i,
END OF type_from.
data : t_from type table of type_from,
t_display type table of type_display.
field-symbols : <fs_from> type type_from,
<fs_display> type type_display.
data : wa_from type type_From,
wa_display type type_display.
wa_from-year = '2005'.
wa_from-ww = '1'.
wa_from-site = 'OR1'.
wa_from-demand = '12.00'.
insert wa_from into table t_from.
wa_from-year = '2005'.
wa_from-ww = '2'.
wa_from-site = 'OR1'.
wa_from-demand = '13.00'.
insert wa_from into table t_from.
wa_from-year = '2005'.
wa_from-ww = '3'.
wa_from-site = 'OR1'.
wa_from-demand = '14.00'.
insert wa_from into table t_from.
data : variable(3) type c.
field-symbols : <fs_any> type any.
break-point.
Loop at t_from assigning <fs_from>.
variable = 'WW'.
wa_display-title = <fs_from>-site.
concatenate variable <fs_from>-ww into variable.
assign component variable of structure wa_display to <fs_any>.
<fs_any> = <fs_from>-demand.
endloop.
append wa_display to t_display.
clear wa_display.
loop at t_display assigning <Fs_display>.
write :/ <fs_display>.
endloop.
Note : Please award points if this helps you.
Regards,
Ravi -
How to get values from dynamically populated field symbol
Hi all,
I am having a field symbol <fs_table> type standard table, which is getting populated dynamically.
CALL METHOD cl_alv_table_create=>create_dynamic_table
EXPORTING
it_fieldcatalog = i_fieldcat[]
IMPORTING
ep_table = is_eptab.
ASSIGN is_eptab->* TO <fs_table> .
After the ALV display i am making some changes in the ALV and getting a new internal table <fst_table>,which is having changed values.
Now the problem is that i am not able to get the changed values from <fst_table> as it is not of any structure type and cant associate it with any field like we do in normal internal table and work areas like, wa-fieldname.
All the fields are dynamic.
Regards,
AnantHello Anant
You have to access to access the fields of your dynamic outtab dynamically as well.
DATA: ls_fcat TYPE lvc_s_fcat.
FIELD-SYMBOLS:
<ls_struc> TYPE any,
<ld_fld> TYPE any.
LOOP AT <fs_table> ASSIGNING <ls_struc>.
LOOP AT i_fieldcat INTO ls_fcat.
ASSIGN COMPONENT ls_fcat-fieldname OF STRUCTURE <ls_struc> TO <ld_fld>.
... " do processing
ENDLOOP.
ENDLOOP.
Regards
Uwe -
How to make slicer to remember selected values while moving from report to another
I have Power View on SharePoint 2013 and OLAP Cube on SQL Server 2014 solution.
1) I select slicer values and graphs are updated
2) I move to next page on same Power View file and use slicers.
3) I come back to original reports. My slicer valuers are empty.
Is it possible to make slicer to remember selected values while browsing from reports to another?
Ken
Kenny_IHi Kenny_I,
This seems to a by design issue. The selected values within a slicer will be stored in Memory. When we go to another report, the memory will be released.
Best Regards,
Black -
UTF issue when moving from cf5 to cfmx7
It's been long overdue so am moving from CF5 to cfmx7 on my hosting account.
The issue is that my hosting account has disabled cfcontent.
I am getting gibberish outputting utf data from my database. It works fine on cf5 but on cfmx7 I read someplace that you have to use cfcontent to output utf-8 correctly.
Is there any work around without having to use cfcontent?
I tried using cfprocessingdirective and cfheader tags to show utf but it didn't work. Any pointers or suggestions appreciated.
Best Regards
Sanmanok, since it's "N" you should be good to go with transferring the data (it's
actually pretty simple). in cf5, write a page that does a simple query against
the table(s) containing your data, i guess just select TOP 100 or so rows with
the PK & the nText columns. simply output that query using a delimiter that you
can parse easily (commas between columns & quotes for the nText would be my
default choices). have a look at the output to make sure it's readable. if all's
well, on the cf7 (or whatever) box do a cfhttp call to that cf5 page & dump out
the cfhttp.fileContent or result if you use that. if it's still readable, then
you can do the real xfer by:
- backing up the original table
- double checking that the backup is ok
- triple checking that the backup is ok
- adding another table w/just PK & nText columns
- filling that with the properly encoded data
- then do a join UPDATE against the old table -
Read Data from the dynamic Field Symbol with key ?
Dear All,
I've 2 dynamic internal tables in the form of field symbols.
Now,I want to loop the item field symbol, read the header field symbol content and then move the corresponding into a final field symbol.
How to read the field symbol with key ?
When I'm trying to give the key clause in the paranthesis it's giving a syntax error.
Any clues ?
FYI .....
* Get the Dynamic Field and Value for the Date/Year and convert it into Year value
LOOP AT <fs_t_son> ASSIGNING <wa_son>.
ASSIGN COMPONENT gwa_znrows_def-fieldname OF STRUCTURE <wa_son> TO <fs_year>.
IF sy-subrc = 0.
CLEAR gv_string.
MOVE <fs_year> TO gv_string.
CLEAR gv_year.
gv_year = gv_string.
<fs_year> = gv_year.
ELSE.
* When the Date/year Field is not in the Table then -->
* Get the Dynamic Field and Value
ASSIGN COMPONENT gwa_znrows_def-kfldname OF STRUCTURE <wa_rson> TO <fs_value>.
* Populate field for Dynamic Where condition
CLEAR gv_value.
CONCATENATE '''' <fs_value> '''' INTO gv_value.
CONCATENATE gwa_znrows_def-kfldname '=' gv_value INTO gt_where SEPARATED BY space.
APPEND gt_where.
CLEAR gt_where.
READ TABLE <fs_t_rson> ASSIGNING <wa_rson> ( gt_where ). "Key clause
ENDIF. " if sy-subrc = 0. "Assign
ENDLOOP.
Thanks & regards,
Deepu.KTYPES: BEGIN OF line,
col1 TYPE c,
col2 TYPE c,
END OF line.
DATA: wa TYPE line,
itab TYPE HASHED TABLE OF line WITH UNIQUE KEY col1,
key(4) TYPE c VALUE 'COL1'.
FIELD-SYMBOLS <fs> TYPE ANY TABLE.
ASSIGN itab TO <fs>.
READ TABLE <fs> WITH TABLE KEY (key) = 'X' INTO wa.
The internal table itab is assigned to the generic field symbol <fs>, after which it is possible to address the table key of the field symbol dynamically. However, the static address
READ TABLE <fs> WITH TABLE KEY col1 = 'X' INTO wa.
is not possible syntactically, since the field symbol does not adopt the key of table itab until runtime. In the program, the type specification ANY TABLE only indicates that <fs> is a table. If the type had been ANY (or no type had been specified at all), even the specific internal table statement READ TABLE <fs> would not have been possible from a syntax point of view. -
Performance issue when moving from 4.6c to 6.0
Looks like we took a performance hit when moving from 4.6c to 6.0 on the same hardware.
For example, our PGI on outbound deliveries now takes several seconds longer in 6.0 then it did in 4.6c. We've noticed other SAP area's are taking longer as well. With an ST05 sql trace on the PGI in 6.0, we see more tables being accessed, same tables being access differently taking longer. All leading to more time to do a PGI in 6.0.
Has anyone else noticed this increase in Response time when upgrading to 6.0 ?
Thanks,
DavidHello.
Yes, in our system we noticed the same thing at start. The general performance seemed to get worse after upgrading. In fact, database became bigger and more memory is consumed. However, it was tuned up by our system administrator and now seems ok.
Run the optimizer statistics and see if it get's better.
Regards.
Valter Oliveira. -
Field-symbol definition for a variable representing transparent tables
Hi Gurus
I'm trying to create a very simple report to display table descriptions and their DB number of records:
Ex:
MARA 50000
MARD 123000
I can't compile this piece of code:
field-symbols: <table>.
assign (DD02T-TABNAME) to <table>.
clear n.
*SELECT COUNT( * )*
INTO n
FROM <table>.
The problem here is that <table> is not defined in the ABAP dictionary as a a table , projection view or databse view.
1. Is there a way of defining <table> with a field-symbol data statement to make it work?
2. Alternatively, how can you produce a list of all table DB entry counts for a dynamic list of transparent tables?
Thanks
NunoWith the code you have field symbol will "point" to a table contained in DD02T-TABNAME , not its name.
What you need is to get the table name , not table itself
field-symbols: <table_name>.
assign DD02T-TABNAME to <table>. "get table name, not its content
clear n.
SELECT COUNT( * )
INTO n
FROM (<table>).
or simply without field symbol
SELECT COUNT( * )
INTO n
FROM (DD02T-TABNAME).
Regards
Marcin -
Using field-symbols with FOR ALL ENTRIES IN ...
Hi all of you,
Is it possible to use field symbol by the FOR ALL THE ENTRIES IN itab.
Normally, isn't possible.
So my problem is that I'm having duplicate code.
I've something like this.
IF ap_objcl EQ omaterial.
SELECT objectid
INTO TABLE i_cdpos
FROM cdpos
FOR ALL ENTRIES IN otf_materials
WHERE objectclas = ap_objcl AND
tabname = otf_materials-tablename AND
fname = otf_materials-fieldname.
ELSEIF ap_objcl EQ otf_documents...
And I'm looking to use otf_materials and otf_documents
So, instead to duplicate the code, I'm looking for a way to restrain the code by using maybe field symbols.
Ideal :
FIELD-SYMBOLS : <otf_mats_docs> LIKE OTF_TABLE.
IF ap_objcl EQ omaterial
ASSIGN local copy of otf_materials TO <otf_mats_docs> CASTING.
ELSEIF ap_objcl EQ odocuments
ASSIGN local copy of otf_documents TO <otf_mats_docs> CASTING.
ENDIF.
SELECT objectid
INTO TABLE i_cdpos
FROM cdpos
FOR ALL ENTRIES IN <otf_mats_docs>
WHERE objectclas = ap_objcl AND
tabname = <otf_mats_docs>-tablename AND
fname = <otf_mats_docs>-fieldname.
IF ap_objcl EQ omaterials.
*Do nothing
ELSEIF ap_objcl EQ odocuments.
*Do something with the date in otf_documents.
ENDIF.
Regards,
KaisHi,
Ok, using forms is great things to deal with it.
But, may be it'll slow down the program and I need a really rapid program.
I tried using form.
The problem by pushing the FOR ALL ENTRIES IN <structure>
didn't works.
It tells me that the structure that I pushed via "using" is not an internal table.
The same structure work find in the global program.
What should I do ?.
The structure is given by as a parameters in Function Module.
FORM data_search
USING
object_cl TYPE j_objnr
table_data LIKE ****structure****
CHANGING
global_lst TYPE ANY TABLE.
DATA : BEGIN OF otf_list OCCURS 0,
objectid TYPE cdpos-objectid,
END OF otf_list.
DATA : ii_cdpos LIKE TABLE OF otf_list WITH HEADER LINE.
IF table_data IS NOT INITIAL.
SELECT objectid
INTO TABLE ii_cdpos
FROM cdpos
FOR ALL ENTRIES IN table_data
WHERE objectclas = object_cl AND
tabname = table_data-tablename AND
fname = table_data-fieldname.
ELSE.
SELECT objectid
INTO TABLE i_cdpos
FROM cdpos
WHERE objectclas = ap_objcl.
ENDIF.
SELECT DISTINCT objectid
INTO TABLE global_lst
FROM cdhdr
FOR ALL ENTRIES IN ii_cdpos
WHERE ( ( udate GT from_date AND udate LT to_date ) OR
( udate EQ from_date AND udate NE to_date AND utime GE from_time ) OR
* ( udate NE from_date AND udate EQ to_date AND utime LE to_time ) OR
* ( udate EQ from_date AND udate EQ to_date AND utime GE from_time AND utime LE to_time )
( udate EQ to_date AND (
udate NE from_date OR
utime GE from_time
AND utime LE to_time )
) AND
objectclas = ap_objcl AND
objectid = ii_cdpos-objectid.
ENDFORM. -
Proper use of Field symbol .. please help
what is the proper use of field symbol in sap abap ?
Moderator Message: Please do a proper search for such basic questions.
Edited by: kishan P on Sep 13, 2010 4:01 PMhi Gopal,
The parameter is used to color a cell in ALV grid.
See this example how it is used
http://www.sap-img.com/abap/line-color-in-alv-example.htm
take a closer look at the code where the info is passed
MOVE 'MATNR' TO wa_color-fname.
MOVE '6' TO wa_color-color-col.
MOVE '1' TO wa_color-color-int.
MOVE '1' TO wa_color-color-inv.
APPEND wa_color TO it_color.
Cheers
VJ
If it helps dont forget to mark points -
Jumping from Z10 to Z30 or wait for Passport?
I'm thinking to swap my device from Z10 to Z30. Is it a good decision to jump to Z30 or shall I wait for Passport to get released.
P.S. Am afraid to buy a device as soon as it hit the market because of the less support forums and less known issues.tough choice to make but I am leaning to get one
Click here to Backup the data on your BlackBerry Device! It's important, and FREE!
Click "Accept as Solution" if your problem is solved. To give thanks, click thumbs up
Click to search the Knowledge Base at BTSC and click to Read The Fabulous Manuals
BESAdmin's, please make a signature with your BES environment info.
SIM Free BlackBerry Unlocking FAQ
Follow me on Twitter @knottyrope
Want to thank me? Buy my KnottyRope App here
BES 12 and BES 5.0.4 with Exchange 2010 and SQL 2012 Hyper V
Maybe you are looking for
-
Java will not work on the computer all of a sudden. Now when I go to open a Pogo game room up i get a Mozilla red lego piece in the corner saying "Some plug ins have been De-activated for your safety, in the box will be "Java (TM) platform SE 6 U". I
-
I am without a phone after restoring it. Apple told me in order to get rid of the previous owners link to this phone i had to put it in recovery mode and restore the phone. WellI've done that and now i get a message that says this iphone is currently
-
Kindle fire hd 8.9 and skype quality
How is the video quality for skype on kindle fire hd 8.9
-
Error: Query could not be saved due to problem in transport
Hi all, This is the error msg i'm getting when i'm trying to save a new query. what could be the possible problem? And how should i go about solving it. Thanks in Advance. Mav.
-
ColdFusion 11, hot fix 3 installed but did not help. There are no binds. This one has been driving me crazy and I have finally figured out that it is the first column in each grid where there is a select box via "valuesdisplay" that is the issue. Sel