Resolving data-reference at runtime ( cl_abap_typedescr)
Hi all,
At runtime, I need to find out if a data-reference of created data
refers to a data-element or not.
In will give you an example of what I mean:
data: dummy TYPE bukrs,
descr_ref TYPE REF TO cl_abap_typedescr,
descr_datael TYPE REF TO cl_abap_elemdescr,
p_datael type string value ''.
descr_ref = cl_abap_typedescr=>describe_by_data( dummy ).
MOVE descr_ref ?TO descr_datael.
p_datael = descr_datael->help_id. "p_datael has now value BUKRS
How is this done, if we work with a datareferences?
I'm pretty sure it should be feasible - but I'm stuck here...
Task: same as above - find out data-element of dummy.
data: dummy TYPE ref to data,
descr_ref TYPE REF TO cl_abap_typedescr,
descr_datael TYPE REF TO cl_abap_elemdescr,
p_datael type string value ''.
create dummy type bukrs.
descr_ref = cl_abap_typedescr=>describe_by_data( dummy ).
"descr_ref->type_kind this time indicates, that we work with referenced data.
"How to progress from here on?
Thanks in advance. Points will be granted if issue can be solved!
Hello Edwin
The sample report ZUS_SDN_RTTI_DATA_ELEMENT shows how to address your question.
*& Report ZUS_SDN_RTTI_DATA_ELEMENT
*& Thread: resolving data-reference at runtime ( cl_abap_typedescr)
*& <a class="jive_macro jive_macro_thread" href="" __jive_macro_name="thread" modifiedtitle="true" __default_attr="770681"></a>
REPORT zus_sdn_rtti_data_element.
DATA: gdo_dummy TYPE REF TO data,
go_typedescr TYPE REF TO cl_abap_typedescr,
go_elemdescr TYPE REF TO cl_abap_elemdescr,
p_datael TYPE string VALUE ''.
PARAMETERS:
p_rolln TYPE rollname DEFAULT 'BUKRS'.
START-OF-SELECTION.
CREATE DATA gdo_dummy TYPE (p_rolln).
go_typedescr = cl_abap_typedescr=>describe_by_data_ref( gdo_dummy ).
go_elemdescr ?= go_typedescr.
IF ( go_elemdescr->kind = cl_abap_elemdescr=>kind_elem AND
go_elemdescr->help_id = 'BUKRS' ).
MESSAGE 'Is of TYPE BUKRS' TYPE 'S'.
ELSE.
MESSAGE 'Is not of TYPE BUKRS' TYPE 'S'.
ENDIF.
END-OF-SELECTION.
Regards
Uwe
Similar Messages
-
Create data reference to a table that is known at runtime
Hi,
I am trying to create a data reference to a table that is known only at runtime. In system 4.6C, I am not able to insert this coding
data: lr_data type ref to data.
CREATE DATA lr_data type table of (structure_name).
In hihger releases, I am able to do so.
Could you please tell me how to solve this problem in 4.6C?
Best regards,
FabianHi fabian,
If i understood,
u want to create a dynamic internal table.
1.
For this purpose,
in my program,
there is an INDEPENDENT FORM
whose inputs are
TABLE NAME / STRUCTURE NAME
and from those, it consructs dynamic table.
2. Here is the program.
the dynamic table name will be
<DYNTABLE>.
3. U can use this program (FORM in this program)
to generate any kind of internal table
by specifying TABLE NAME .
4.
REPORT abc.
COMPULSORY
FIELD-SYMBOLS: <dyntable> TYPE ANY TABLE.
FIELD-SYMBOLS: <dynline> TYPE ANY.
DATA: lt TYPE lvc_t_fcat.
DATA: ls TYPE lvc_s_fcat.
FIELD-SYMBOLS: <fld> TYPE ANY.
DATA : fldname(50) TYPE c.
parameters : iname LIKE dd02l-tabname.
START-OF-SELECTION.
PERFORM
PERFORM mydyntable USING lt.
BREAK-POINT.
INDEPENDENT FORM
FORM mydyntable USING ptabname.
Create Dyn Table From FC
FIELD-SYMBOLS: <fs_data> TYPE REF TO data.
FIELD-SYMBOLS: <fs_1>.
FIELD-SYMBOLS: <fs_2> TYPE ANY TABLE.
DATA: lt_data TYPE REF TO data.
data : lt TYPE lvc_t_fcat .
DATA : ddfields LIKE ddfield OCCURS 0 WITH HEADER LINE.
CALL FUNCTION 'DD_NAMETAB_TO_DDFIELDS'
EXPORTING
tabname = iname
TABLES
ddfields = ddfields.
CONSTRUCT FIELD LIST
LOOP AT ddfields.
ls-fieldname = ddfields-fieldname.
APPEND ls TO lt.
ENDLOOP.
ASSIGN lt_data TO <fs_data>.
CALL METHOD cl_alv_table_create=>create_dynamic_table
EXPORTING
it_fieldcatalog = lt
IMPORTING
ep_table = <fs_data>
EXCEPTIONS
generate_subpool_dir_full = 1
OTHERS = 2.
IF sy-subrc <> 0.
ENDIF.
Assign Dyn Table To Field Sumbol
ASSIGN <fs_data>->* TO <fs_1>.
ASSIGN <fs_1> TO <fs_2>.
ASSIGN <fs_1> TO <dyntable>.
ENDFORM. "MYDYNTABLE
regards,
amit m. -
TS5168 some of my pictures say that the necessary data reference could not be resolved. help
some of my pictures say that the necessary data reference could not be resolved. help
It means iPhoto can't find the file.
There are 9 different versions of iPhoto and they run on 9 different versions of the Operating System. The tricks and tips for dealing with issues vary depending on the version of iPhoto and the version of the OS. So to get help you need to give as much information as you can. Include things like:
- What version of iPhoto.
- What version of the Operating System.
- Details. As full a description of the problem as you can. For example, if you have a problem with exporting, then explain by describing how you are trying to export, and so on.
- History: Is this going on long? Has anything been installed or deleted? - Are there error messages?
- What steps have you tried already to solve the issue.
- Anything unusual about your set up? Or how you use iPhoto?
Anything else you can think of that might help someone understand the problem you have. -
As the title states, I used the app "Duplicate Cleaner for iPhoto" to get rid of 6 GB of duplicate pictures. However, now when I go to view a video in iPhoto, I get the error message "A necessary data reference could not be resolved." I am able to view the video clips (with sound, etc.) in Finder. However, I want to know if there is a way to restore them in iPhoto?????
Thanks,
Leslie
I see that the suggested solution is to restore from back-up... is there anyway to do that without bringing in ALL of the duplicate photos I just deleted?Try going back to QuickTime 7.4, we've seen the same problem occur with the 7.5 update. How did you make the .mov file that plays all of the files? For us, the problem shows up with reference movies (such as that .mov) made on a Mac, but works fine if it is created on Windows.
-
When I want to scroll through My pictures why do I get this Error message (A necessary data reference could not be resolved)
Before anyone can help, they need information to work with. Basic stuff:
- What version of iPhoto.
- What version of the Operating System.
- Details. What were you doing when the problem arose?
- Did it ever work properly?
- Are there error messages?
- What steps have you tried already to solve the issue.
Anything else you can think of that might allow someone else to understand your issue.
With this kind of information somebody can develop a starting point for troubleshooting the issue.
Posts that consist of "iPhoto doesn't work. Help" or "iPhoto won't print" or "Suddenly I have no photos!!!!!!!!!!" mean that any helper is simply guessing. With information, s/he may be able to get your issue resolved sooner. -
I have recently perchaced a brand new Mac Book Pro. The apple store very kindly tranfered everything from my old Mac Book to my new Mac Book Pro. I keep my iphoto library on and external hardrive, which seems to be working fine since I moved everything. BUT..."some' movies won't play from my iphoto library and a window appears saying "a necessary data reference could not be resolved". I can find these videos when I search for them in finder manually (I backed everything up before I transfered everything into a file called TEMP VIDEOS), but why can't my iphoto application find them, like it used to...it still still should right!? Very frustrating.
Please help..
ThanksActually this happened to me today and although it would not let me play the file it allowed me to use that same file i had exported from iphotos but could not play and then it allowed me to open it in imovie (you can go to import and then get it from the desktop or wherever) although I made a couple of changes to it the main thing is once you drag it into the space to begin a new project you can then right click and select open in finder and that file actually plays......if its cause i made some changes to it i.e trimmed it slightly then its worth doing so.
-
Hi, I can no longer access the videos in my iphoto library. It still shows the screenshot and the duration of the video, but when i open, i get the following message ' A necessary data reference could not be resolved'. What can i do ?
Tried also to export, but to no avail.
Thx for suggestions,
OscarWith the amount of information you've provided it's impossible to offer a solution. We can't see your computer so we need to know the details of your problem and setup, i.e.:
what version of iPhoto are you using?
what system version are you running?
Did you apply any updates or upgrades to iPhoto or the system between the time you last were able to view the video files and now?
what fixes have you tried?
where is your library located?
did you apply any updates or upgrades just prior to the problem occurring?
are you running a "managed" or "referenced" library?
what type of Mac?
how much free space on your boot drive? -
Error -2000 necessary data reference could not be resolved-- HELP!!!
So, I work in a nurse's office at a medical school editing video on an iMac 2.33 GHx Intel Core 2 Duo with 3GB 667 MHz DDR2 SDRAM. Mine is the only mac in the office, the rest of the secretaries, nurses, and grad students are on windows XP.
My job is basically to edit videos (color correct, blur faces of patients' relatives, etc) from a study they did, and export the videos to a DVD (as a data disk, not a DVD with menus) so they can show them to each other and various committees on their windows machines.
For the longest time, this went off without a hitch, but most recently, I tried burning some .mov files to disk, and whenever they play on any machine (windows xp) we get "Error -2000 necessary data reference could not be resolved." I re-burned the disks, and now, they are selective! They play on some of the office computers, but not all... including the target machine where they will ultimately be screened for a committee... even on the 2nd batch of disks, that error is still present...
I know about video editing, and to some degree disk burning (I used the "New-->burn folder" option to create the data disk, burning them at 2x speed for reliability). But I don't know enough about computers to figure out what this error means, or why these disks won't work!! Somebody please help!
(and you can save the sales pitch... I'm a mac user through and through, and there is no way in heck my office will ever have enough money or motivation to switch over)
Thanks for your help!!I wont address the problem but that you should have your videos. Dont you still have them on your camera? If not, just get it from your friend. Btw, do this the next tíme around ... Whenever you plug in the camera and your iPhoto/pic Application opens up, BEFORE you have iPhoto import them, use Finder to copy the photos over to your HDD or an external drive. This is so that YOU always have the originals BEFORE your pic Application does.
-
Resolve self-reference table by alias tables in detail
Hello Gurus,
can you tell me how to resolve self-reference table by alias tables in detail?
Many thanks.Hello, for the following step 3, I don't understand, will you please give me some explanation for step 3?
Save your Staff universe, and test the results in Web Intelligence Rich Client as follows:
1. Run a query using Manager and Employee. Add a count on both columns.
2. Add a query with only the Manager object. Add a count. Is this the correct value?
3. Open your Staff universe in Universe Designer and edit the Manager object. To ensure
that the data is restricted to only manager data, use the Tables button. Select the
EMPLOYEE table, to force the object to use the join between the table and restrict the
data.
4. Test the result, creating a new query with only the Manager object. It returns the correct
number of managers.
5. Edit the query and add Employee. Run and display the count. There are 26 rows. Why?
The join restricts the data to look only for employees that have managers. However, there
is a manager that does not have a manager, and is now excluded.
6. Open your Staff universe in Universe Designer and add an outer join on the MANAGER
table side.
7. Save the changes and test the results in Web Intelligence Rich Client. -
error message: a neccessary data reference could not be resolved
already have Perian Installed (http://www.perian.org/)
already have Quicktime X natively installed
installed Quicktime 7.66 from the Mac OS X v10.6 Snow Leopard install DVD:
Insert your Mac OS X 10.6 Snow Leopard Install DVD.
Open the Optional Installs folder and double-click "Optional Installs.mpkg".
Select the QuickTime 7 option and click Continue.
QuickTime Player 7 will be installed in your Utilities folder.
then activated Quicktime 7.66 to PRO.
Safari preferences in security are set to allow for plug ins and extensions
Safari Menu Bar/click Help/Installed Plug-ins. (Quicktime PlugIn is NOT there)
Safari folders NOT showing quicktime PlugIn for quicktime
in MacIntosh HD/Library/Internet Plugins (Quicktime not there)
in USER/Library/Internet Plugins (NONE AT ALL)
with Pacifist (http://www.charlessoft.com) reinstalled Quicktime X
(1) Dowload and install Pacifist
(2) Insert your Snow Leopard install DVD
(3) Run Pacifist and choose "Open Apple Install Disks" (takes a bit)
(4) Search for "Quicktime Player.app"
(5) Select "Quicktime Player.app" (in Essentials.pkg/Applications)
and choose "Install to Default Location". - thank you Roy Levien
HOWEVER, i noticed during that process above the "Quicktime Player.app" i saw the Plugins" and quicktime plug in was there. i extracted that to the default location and IT DID NOT tell me it was already there. So i installed it.
also,
i went to the quicktime 7 app, command i, set to open in 32 bit.
i went to the safari app, command i, set to open in 32 bit.
Message was edited by: NikaBrady* also i saw this comment on another forum but no comments after it.
(I had the same problem and managed to fix it as follows: I found that I had two Library folders, one in Macintosh HD, one in my User folder. Each Library folder contained a folder for Internet Plug-Ins. I moved the files QuickTime Plugin.plugin and QuickTime Plugin.webplugin from the Macointosh HD/Library/Internet Plug-Ins to User folder/Library/Internet Plug-Ins, and that fixed it.
Not sure why there are two Library folders, but QuickTime installation seems to have put the plug-ins into the wrong one, and that was the problem)
has anyone else encountered this problem or have any ideas on the cause or the fix?
i have done all that can with my limited capabilities and any advice would be greatly appreciated.
thank you
Message was edited by: NikaBrady -
Unable to resolve a reference to a variable
I am having an error message telling me that it is unable to a resolve a reference to a variable when I try to query a certain data block. I have debugged the form and have made certain that the correct variables are in the form. Why am I getting this error? Here is my code:
Declare
n_proj_id t_assignment.proj_id%TYPE := NULL;
n_con_id t_consultant.con_id%TYPE;
begin
n_con_id := :t_consultant.con_id;
SELECT proj_id
INTO n_proj_id
FROM t_consultant
WHERE t_consultant.con_id = n_con_id;
IF n_proj_id IS NOT NULL THEN
Set_Block_Property('t_assignment', ONETIME_WHERE, 'proj_id = :n_proj_id');
go_block('t_assignment');
execute_query;
END IF;
end;it's the n_proj_id variable that can't be reference. Just wanted to clarify.
-
Reg: Field Symbol and Data Reference
Hi,
What is the difference Between a FieldSymbol and Data Reference.
could anyone explain with an example the difference.
The Link I am Going Through ---> [SAP HELP|http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3860358411d1829f0000e829fbfe/frameset.htm]
I couldnt get a clear idea
regardsHi,
In ABAP/4 programs, field symbols are placeholders for existing fields. A field symbol does not physically reserve space for a field, but points to a field, which is not known until runtime of the program. Field symbols are comparable to the concept of pointers as used in the programming language C. In ABAP/4, however, there is no real equivalent to pointers in the sense of variables, which contain a memory address and can be used without the content operator. You can only work with the data object to which a field symbol points.
uF076 Concept of Field Symbols
Sometimes you only know which field you want to process, and how you want to process it, at runtime.
For this purpose, you can create field symbols in your program. At runtime, you can assign real fields to such field symbols. All operations, which you have programmed with the field symbol, are then carried out with the assigned field. After successful assignment, there is no difference in ABAP/4 whether you reference the field symbol or the field itself.
Field symbols can point to any data object in ABAP/4 and to structures defined in the ABAP/4 Dictionary.
You can create field symbols either without or with type specifications. In the first case, the field symbol adopts all the attributes of the assigned field. In the second case, the system checks during the assignment process whether the assigned field matches the type of the field symbol. Whichever applies, you must first assign a field to your field symbol before you can work with it in your program.
Field symbols provide some features that make them very flexible:
uF071 You can specify the offset and length of the assigned field as variables.
uF071 You can assign field symbols to other field symbols and even specify offset and length there.
uF071 Assignments to field symbols may extend beyond field boundaries. This allows effective access to regularly stored data.
uF071 You can force a field symbol to be of a different type and to have a different number of decimal places than the assigned field.
uF071 Field symbols may have a structure that you can use to point to individual components of structures.
Since you can assign data objects to field symbols which may not be known until runtime, the effectiveness of syntax and security checks is very limited for operations involving field symbols. This can lead to runtime errors or incorrect data assignments.
While runtime errors indicate an obvious problem, incorrect data assignments are dangerous because they can be very difficult to detect. Therefore, you should use field symbols only in cases where you are absolutely sure of what you are doing, or if there are no other ABAP/4 statements you can use to solve your problem. The advantage of field symbols is that they can improve response times in some cases.
uF076 Defining Field Symbols
uF0D8 Defining Field Symbols for Internal Fields
To define a field symbol for an internal data object, use the FIELD-SYMBOLS statement as follows:
Syntax-
FIELD-SYMBOLS <FS> [<type>].
This statement defines a field symbol <FS>.
for data reference follow this link
http://help.sap.com/saphelp_nw04s/helpdata/en/14/11e70b0c5c11d3b9350000e8353423/frameset.htm
Regards,
Flavya -
"Couldn't resolve the reference' when opening file
I am trying to open a WB file that I have copied from another drive. As it looks through the new drive searching for all the media, it keeps giving me this message about not being able to 'resolve the reference' when trying to relink with the media. What causes this and how can I fix it?
If the file doesn't contain Audio data, but merely refers to it (as is quite common & an option you can choose if you don't want to duplicate Audio files), then it needs to know where those Audio data files are. And if you've moved them or deleted them, it won't be able to find them… hence the message. If you know where those files are, you can put them back where they were previously, & that might fix things. Or — simply make a new file.
You may prefer in future to save the files with the audio data included. Of course, you will get a much bigger file, but it will be self-contained & you won't get this problem again.
P.S.: of course, you said it yourself (& I didn't notice at first) — you copied this WB file from another drive. So of course the audio files you want are still on that other drive! Hooray! -
Dynamic Data Binding at runtime
For future applications, flexibility will be an important feature. One of the biggest drawbacks of forms is/was, on my opinion, not being able to create new items at runtime.
JClient will easily overcome this restriction. But how about data binding ?
Imagine the following situation: We've got a VO "order" with the "custname" incorporated as lookup data. At runtime, the user decides that she needs to see the "custloc" as well (put an additional JTextField into some whitespace on his panel). As I understand it is possible to build a view link to tie an instance of the VO "customer" to the "order" (I'd prefer that over adapting the query statement of "order" at runtime). But how can I create the new iterator binding and control binding needed to populate the dynamically created attributes with the data from "customer"? And, further on, how will I be able to make the changed configuration of my panel persistent, let's say into the DB ? Or does the data binding concept of 10g just not cover this requirement?Hi pascal
It is not possible to send you email at your address. All come back with a permanent error
Your document: test
was not delivered to: <[email protected]>
because: Error transferring to smtp.solnet.CH; SMTP Protocol Returned a Permanent Error 550 Service unavailable; Client host [81.62.5.7] blocked using dul.dnsbl.sorbs.net; Dynamic IP Address See: http://www.dnsbl.sorbs.net/cgi-bin/lookup?IP=81.62.5.7 -
I have a slide show (project) that will not export. The error triangle appears with the message: "This movie contains an invalid data reference" What is the issue, and what is the solution?
jhI found that the issue was with the title side, it had too many characters in the slide. When the number of characters was diminished, the show loaded without issue.
Maybe you are looking for
-
Backing up iTunes Purchases to External Hard Drive
I tried to download the 2.0 upgrade for my touch last week. It completely crashed my system. Corrupted my user log in on Windows. I was able to transfer my purchases from my touch back to my computer, but I'm wanting to back up my purchases to an ext
-
ISE 1.2 EAP-TLS and AD authentication
Hi, I am sure I have had this working but Just cant get it to now. So I have a Computer that has a Certificate on it with the SAN - princible name = to [email protected] This is an auo enroled Cert from my AD. My Authentication profile says IF the SS
-
ITunes sync iPhone 4 application, the computer crashes
Will the iTunes "restore"function, you can synchronize the application failed to iPhone 4 repair? because my computer (Windows7) and then iTunes crashes when sync the iPhone 4. I'm from Taiwan, may not translate well Huang.JyunSiang
-
Can you block private phone calls?
Im being harassed by a private number, if i change my number he finds it again. Can you block private phone calls
-
Debugging using Eclipse and non-standalone 10g
Hey - is it possible to perform remote debugging using Eclipse against the non-standalone version of the 10g App Server? I've tried some of the hints listed in this forum (the most promising seemed to be starting oc4j using this command-line command: