Attach native data to an object
Hi to all of you! I have the following problem: I want to create a class where each instance uses a corresponding native data block (for example, a C++ object). The problem is, can I somehow "attach" that native data to the java object so I have it ready in the native methods? Currently I'm storing the address of the object in an integer field of the java class, but that seems like a quick hack to me. I couldn't find anything in the forum or in the tutorial I used. Am I missing something?
No, you are not missing something.
Similar Messages
-
Urgent Help Req.: Exception=ORABPEL-11162 Error while reading native data
Hi All,
I am getting below error: Exception=ORABPEL-11162
Error while reading native data.
[Line=6, Col=7|http://forums.oracle.com/forums/] Not enough data available in the input, when trying to read data of length "22" for "element with name PurOrderNum" from the specified position, using "style" as "fixedLength" and "length" as "22".
Ensure that there is enough data from the specified position in the input.
Let me also give you the brief scenario of what I am trying to achieve.
INTERFACE FUNCTIONING:_
I have an interface which reads the records in a file in a chunk through ChunkRead adapter and and after one successful reading if chunk it calls the DB adapter to insert the records in the table.
Now these records are committed and next chunk is read and the process goes on till all the records are read.
After this the API is called which does the processing of these records.
Inserting records in the DB is a XA transaction which means if anything goes wrong while inserting the data, the records which are added earlier are rolled back.
ISSUE:_
Now the issue comes when I do the negative testing. Since my file is based on fixed length schema., I change the length of last record from 15 to 13. (say total are 10 records)
Now what happens is when chunkread tries to read the record of 15 length it gets only 13 characters and hence ignores the records.
But the chunkread reads all other 9 records correctly and sends this to DB adapter which now inserts them correctly in the DB.
But being a global transaction I want that if any record is missing from DB in comparison to those in file then whole transaction should roll back.
So I am unable to make this whole process as global transaction. This is because the ChunkRead adapter inspite of detecting the error doesn’t throw it back.
Moreover if this problem occurs in say next chunk then also I am unable to find out how to rollback the whole transaction. Because the first chunk was correct.
So basically two concerns are there:+
How to detect that chunkread adapter has missed one record?+
Secondly, If it’s detected then how should I rollback the transaction that caused earlier records to enter into database?+
Please let me know if anyone has faced this issue earlyer and how it got resolved. Any pointers regarding this would be of great help.
Also attached is the chunkread log for reference.
<MESSAGE>
<HEADER>
<TSTZ_ORIGINATING>2008-10-06T09:23:58.466-04:00</TSTZ_ORIGINATING>
<COMPONENT_ID>tip</COMPONENT_ID>
<MSG_TYPE TYPE="TRACE"></MSG_TYPE>
<MSG_LEVEL>16</MSG_LEVEL>
<HOST_ID>usmlrh01.xyz.com</HOST_ID>
<HOST_NWADDR>192.168.245.39</HOST_NWADDR>
<MODULE_ID>esb.server.service.impl.inadapter</MODULE_ID>
<THREAD_ID>57</THREAD_ID>
<USER_ID>orasoa</USER_ID>
</HEADER>
<CORRELATION_DATA>
<EXEC_CONTEXT_ID><UNIQUE_ID>192.168.245.39:29832:1223297491683:44</UNIQUE_ID><SEQ>130</SEQ></EXEC_CONTEXT_ID>
</CORRELATION_DATA>
<PAYLOAD>
<MSG_TEXT>JCA: FileRejector::rejectTextualMessage errList=[oracle.tip.pc.services.translation.xlators.nxsd.ErrorList@a5213b]</MSG_TEXT>
</PAYLOAD>
</MESSAGE>
<MESSAGE>
<HEADER>
<TSTZ_ORIGINATING>2008-10-06T09:23:58.466-04:00</TSTZ_ORIGINATING>
<COMPONENT_ID>tip</COMPONENT_ID>
<MSG_TYPE TYPE="TRACE"></MSG_TYPE>
<MSG_LEVEL>16</MSG_LEVEL>
<HOST_ID>usmlrh01.xyz.com</HOST_ID>
<HOST_NWADDR>192.168.245.39</HOST_NWADDR>
<MODULE_ID>esb.server.service.impl.inadapter</MODULE_ID>
<THREAD_ID>57</THREAD_ID>
<USER_ID>orasoa</USER_ID>
</HEADER>
<CORRELATION_DATA>
<EXEC_CONTEXT_ID><UNIQUE_ID>192.168.245.39:29832:1223297491683:44</UNIQUE_ID><SEQ>130</SEQ></EXEC_CONTEXT_ID>
</CORRELATION_DATA>
<PAYLOAD>
<MSG_TEXT>JCA: FileRejector::rejectTextualMessage badCount=[1]</MSG_TEXT>
</PAYLOAD>
</MESSAGE>
<MESSAGE>
<HEADER>
<TSTZ_ORIGINATING>2008-10-06T09:23:58.467-04:00</TSTZ_ORIGINATING>
<COMPONENT_ID>tip</COMPONENT_ID>
<MSG_TYPE TYPE="TRACE"></MSG_TYPE>
<MSG_LEVEL>1</MSG_LEVEL>
<HOST_ID>usmlrh01.xyz.com</HOST_ID>
<HOST_NWADDR>192.168.245.39</HOST_NWADDR>
<MODULE_ID>esb.server.service.impl.inadapter</MODULE_ID>
<THREAD_ID>57</THREAD_ID>
<USER_ID>orasoa</USER_ID>
</HEADER>
<CORRELATION_DATA>
<EXEC_CONTEXT_ID><UNIQUE_ID>192.168.245.39:29832:1223297491683:44</UNIQUE_ID><SEQ>130</SEQ></EXEC_CONTEXT_ID>
</CORRELATION_DATA>
<PAYLOAD>
<MSG_TEXT>JCA: Rejecting message fileName=/rh01/s01/n01/Distributions/B2B/Gentran/In/855/Test.txt, startLine=4, startColumn=1, endLine=-1, endCol=-1, Exception=ORABPEL-11162
Error while reading native data.
[Line=6, Col=7] Not enough data available in the input, when trying to read data of length "22" for "element with name PurOrderNum" from the specified position, using "style" as "fixedLength" and "length" as "22".
Ensure that there is enough data from the specified position in the input.
}</MSG_TEXT>
</PAYLOAD>
</MESSAGE>
PFB the version details :
SOA suite version : 10.1.3.3.1 and JDEV : 10.1.3.3
Edited by: SOA Team on Oct 6, 2008 10:48 PMJust a thought, you could set the terminator for the last field as {eol} instead of length, this means that it should read the last field regardless of the length.
Depending on the logic of Db adapter the error could be traped due to incorrect length.
If the file starts each row with a constant(s), e.g. 01 then you can terminate the previous line on that, this is the better option but relys on the file format.
The other option is a little thing call compensation, ouch. Basically this allows you to back out commited rows but you have to provide all the logic, it is generally something people avoid because of the complexity.
cheers
James -
Hierarchical Data Loading: XSD design for Native data
We are working on native data received in the form of flat file (attaching a few lines below)
FWDREF VXA04_X001_GC
FWDREF VXA04_X010_GC
FWDREF VXA04_X050_GC
FWDREF VXA04_X051_GC
FWDREF VXA04_X075_GC
FWDREF VXA04_X100_GC
FWDREF VXA04_X101_GC
FWDREF VXA04_X150_GC
SECTIDAVXBOSY SHELL AND PANELS
SECTIDAGBBOSY SHELL AND PANELS
SECTIDABKº¾À¿ÃÁ ½° º°À¾ÁµÀ¸Ï° ¸ ¿°½µ»¸
SECTIDACZDKELET KAROSERIE A PANELY
ILLREFBA1 A05_A1_B
ILLREFBA1-1 A05_A1-1_B
ILLREFBA1-2 A05_A1-2_B
FWDREF VXB04_X101_GC
FWDREF VXB04_X150_GC
SECTIDBVXBOSY SHELL AND PANELS
SECTIDBGBBOSY SHELL AND PANELS
SECTIDACZDKELET KAROSERIE A PANELY
ILLREFBA1 B05_A1_B
ILLREFBA1-1 B05_A1-1_B
This data is hierarchical.
-FWDREF
--SECTID
---ILLREF
The challenge is that the number of occurrences of parent and child are not fixed and they might not occur at all
for eg there might be a set of rows like this (in the example below, there is no SECTID)
FWDREF VXB04_X150_GC
ILLREFBA1 B05_A1_B
How can the schema be designed in this case?
Thanks in advance@rp0428
Thanks for taking out the time to reply to this. If we talk in terms of a tree structure, in the normal scenario we would the hierarchy as described before.
-FWDREF
--SECTID
---ILLREF
If we don't talk in terms of xml and xsd and just talk in terms of database and keys, FWDREF would be parent, SECTID would be child and ILLREF would be grandchild. Now, in case, SECTID does not appear, we would still want a key to be generated but have a default value corresponding to it so that the parent, child and grandchild relationship is mentioned.
The whole purpose of this XSD design is to use it in ODI where this feed file will be automatically loaded into tables from the XML generated with the parent, child and grandchild relationship maintained.
Also, I have taken a sample data set. In the actual case, the hierarchy goes upto a maximum of 20 levels.
Thanks to everyone and anyone who takes out time for this! -
Can we change data in string object.
Can we change data in string object.
Saw this hack to access the char[]'s in a String in another thread. Beware that the effects of doing this is possible errors, like incorrect hashCode etc.
import java.lang.reflect.*;
public class SharedString {
public static Constructor stringWrap = null;
public static String wrap(char[] value, int offset, int length) {
try {
if (stringWrap == null) {
stringWrap = String.class.getDeclaredConstructor(new Class[] { Integer.TYPE, Integer.TYPE, char[].class });
stringWrap.setAccessible(true);
return (String)stringWrap.newInstance(new Object[] { new Integer(offset), new Integer(length), value });
catch (java.lang.NoSuchMethodException e) {
System.err.println ("NoMethod exception caught: " + e);
catch (java.lang.IllegalAccessException e) {
System.err.println ("Access exception caught: " + e);
catch (java.lang.InstantiationException e) {
System.err.println ("Instantiation exception caught: " + e);
catch (java.lang.reflect.InvocationTargetException e) {
System.err.println ("Invocation exception caught: " + e);
return null;
public static void main(String[] args) {
char[] chars = new char[] { 'l', 'e', 'v', 'i', '_', 'h' };
String test = SharedString.wrap(chars, 0, chars.length);
System.out.println("String test = " + test);
chars[0] = 'k';
chars[1] = 'a';
chars[2] = 'l';
chars[3] = 'l';
chars[4] = 'a';
chars[5] = 'n';
System.out.println("String test = " + test);
} Gil -
Error trying to extract data via HFM objects
I've written a program to extract selected data from HFM (version 11.1.1.3.500) using the API objects. The program (shown at the bottom of this post) is failing on the 2nd of the following 2 lines:
oOption = oOptions.Item(HSV_DATAEXTRACT_OPT_SCENARIO_SUBSET)
oOption.CurrentValue = lBudgetScenario
where oOption is a data load/extract object previously initialized and lBudgetScenario is the long internal ID for our budget scenario.
The error is usually "COM Exception was unhandled" with a result code of "0x800456c7", but, mysteriously, even with no code changes, it sometimes throws the error "FileNotFoundException was not handled", where it says that it could not load "interop.HSXServerlib or one of its dependencies". The second error occurs even though HSXServer was previously initialized in the program and used in conjunction with the login.
I've carefully traced through the VB.NET 2010 code and find that all relevant objects are instantiated and variables correctly assigned. It also occurred to me that the data load DLLs might have been updated when the 11.1.1.3.50 and 500 patches were applied. For that reason, I removed the references to those DLLs, deleted the interop files in the debug and release folders and copied the server versions of those DLLs to my PC. I then restored the DLL references in Visual Studio which recreated the interops. However, the error still occurs.
The ID I'm using (changed to generic names in the code below) has appropriate security and, for example, can be used to manually extract data for the same POV via the HFM client.
I've removed irrelevant lines from the code and substituted a phony ID, password, server name and application name. The line with the error is preceded by the comment "THE LINE BELOW IS THE ONE THAT FAILS".
Imports HSVCDATALOADLib.HSV_DATAEXTRACT_OPTION
Module Module1
Public lActualScenario, lBudgetScenario As Long
Public oClient As HSXCLIENTLib.HsxClient
Public oDataLoad As HSVCDATALOADLib.HsvcDataLoad
Public oOptions As HSVCDATALOADLib.IHsvLoadExtractOptions
Public oOption As HSVCDATALOADLib.IHsvLoadExtractOption
Public oSession As HSVSESSIONLib.HsvSession
Public oServer As HSXSERVERLib.HsxServer
Sub Main()
'Create a client object instance, giving access to
'the methods to logon and create an HFM session
oClient = New HSXCLIENTLib.HsxClient
'Create a server object instance, giving access to
'all server-based methods and properties
oServer = oClient.GetServerOnCluster("SERVERNAME")
'Establish login credentials
oClient.SetLogonInfoSSO("", "MYID", "", "MYPASSWORD")
'Open the application, which will initialize the server
'and session instances as well.
oClient.OpenApplication("SERVERNAME", "Financial Management", "APPLICATION", oServer, oSession)
'Instantiate a data load object instance, which will be used to extract data from
'FRS.
oDataLoad = New HSVCDATALOADLib.HsvcDataLoad
oDataLoad.SetSession(oSession)
'Initialize the data load options interface.
oOptions = oDataLoad.ExtractOptions
'Find the internal ID numbers for various scenarios and years.
'These are required for HFM API function calls.
lActualScenario = GetMemberID(DIMENSIONSCENARIO, "Actual")
lBudgetScenario = GetMemberID(DIMENSIONSCENARIO, "Budget")
'Construct file names for open data.
strFileName = "c:\Temp\FEWND_BudgetData.dat"
strLogFileName = "c:\Temp\FEWND_BudgetData.log"
'Extract data for the current open cycle.
ExtractData("Budget", BudgetYear, "Dec", strFileName, strLogFileName)
End Sub
Sub ExtractData(ByVal strScenario As String, ByVal strYear As String, ByVal strPeriod As String, _
ByVal strFileName As String, ByVal strLogFileName As String)
'Populate the Scenario element.
oOption = oOptions.Item(HSV_DATAEXTRACT_OPT_SCENARIO_SUBSET)
If strScenario = "Actual" Then
oOption.CurrentValue = lActualScenario
Else
'THE LINE BELOW IS THE ONE THAT FAILS
oOption.CurrentValue = lBudgetScenario
End If
End Sub
Function GetMemberID(ByVal lDimID As Long, ByVal strMemLabel As String) As Long
Dim oMetaData As HSVMETADATALib.HsvMetadata
oMetaData = oSession.Metadata
oEntityTreeInfo = oMetaData.Dimension(lDimID)
GetMemberID = oEntityTreeInfo.GetItemID(strMemLabel)
End Function
End ModuleI stumbled upon the solution to my problem. The documentation for extracting data via objects defines member ID variables as Longs. In fact, I've always defined such variables as longs in previous object programs and had no problems. It appears that the datal load/extract "option" property of "Currentvalue" is defined as integer. When I changed all of my member ID items (such as the "lBudgetScenario" variable that was the right-side of the failing assignment statement) to be integers, the program worked.
-
Is there a way to export the coord data of AE objects in 3D space? (for programmers)
Hey guys, we're making a video that will mostly be a fixed camera view but have objects animate around this view. The priority is the audio; the objects that animate will sound like they are flying around the camera's point of view (the user when they're using headphone). Since I will be animating the objects inside After Effects and already be assigning them X,Y, & Z coordinates during the animation, is there any way to take the data of the objects location through time to give to the programmers so they can assign the audio/attributes to the objects moving around in the scene? Sort of like how if I made a null object in AE, I can have it be the parent to another layer(s), I need to find a way to make this same concept work but for audio and other assigned attributes. It seems it would save us a lot of time if this is possible instead of figuring out where the sound is coming from later on by scratch and guessing. If there are other programs that can do this please let me know, I do use Maya and other 3D apps. Thanks!
~ DaveThere is this reference:
http://help.adobe.com/en_US/AfterEffects/9.0/WS3878526689cb91655866c1103906c6dea-7a38a.htm l
Perhaps there is a way to export the javascript as a text file or some format useful to your programmers.
Can you give more details as to your end result and starting point? You mentioned you use other 3D programs. Maya used to have in Maya 4.0 a way to dynamically animate according to audio. Other 3D programs still offer this functionality through their scripting and/or interface.
Flash Pro has 3D layers and if your animations are short enough you might be able to do the project in Flash and access the SoundChannel aspects of ActionScript 3.0 . AE uses a version of Javascript. There might be a way in the AE Scripting reference to read objects within the file and a method in the scripting to export these objects. I'm only guessing since I don't know how to script in AE but I see no one has replied to this thread and I was curious myself. -
Problem in activating data in datastore object
Hello,
I have an issue while activating the data in Datastore Object.
I have been trying to load the data to cube 0FIAP_C02. I am going to write down all the process I am doing, so you will have a clear picture and advice me accordingly.
1.)Installing Business content (Cube, Datastore objects, Infosources,
Transfer strcuture and Transfer and update rules) ( 0FIAP_C02, 0FIAP_O06, 0FI_AP_1 and 0FI_AP_6 (infosources)
2.)Replicate the datasources from the R/3 side to BW side (the
datasources are replicated as 3.x)
3.) Create transfer rules and transfer structure.
4.) Create Infopackage for loading data to PSA.
Datasource 0FI_AP_1 -> Full Upload.
Datasource 0FI_AP_6 -> Init. Delta Load.
Load data for both the datasources.
5.)Migrate the 3.x datasources to "Emulated datasources". Create
Transformation between Datasource 0FI_AP_1 and cube 0FIAP_C02, also
create transformation 0FI_AP_6 to Datastore Object 0FIAP_O06.
Create DTP's to load the data from PSA to data targets.
Now is my problem,
1.)I am having errors while activating the data in ODS. (It says that errors occured during the activation of data but I cannot see an error log or anything of that kind.) I can load the data and it gives me green light but when i try to activate it gives errors.
2.)A follow up question of the activation of data is does this data goes and sits in PSA of the data mart 80FIAP_O06.And then do we have to create transformation/DTP from Datastore Object to cube (0FIAP_C02) or we are going to use the Business content transfer rules and Load the data by Infopackage.
Thanks,
Kiran Mehendale.Hi Kiran,
ad 1.) You most likely have to open a customer problem message. Maybe you try to elaborate on your issue (problem message, etc.) and we can try to assist you.
ad 2.) You can create a DTP from one persistent storage object (PSA, DataStore Object, InfoCube, etc.) to another one. Hence you can also create a DTP for DataStore Object --> InfoCube.
Cheers
SAP NetWeaver 2004s Ramp-Up BI Back Office Team -
Error while updating data from DataStore object
Hi,
Currently we are upgrading BW3.5 to BI7.0 for technical only,
we found and errors during process chain run in further processing step. This step is basically a delta loading from DSO to Cube.
The error message are:
Error while updating data from DataStore object 0GLS_INV
Message no. RSMPC146
Job terminated in source system --> Request set to red
Message no. RSM078
That's all no further errors message can be explained clearly here from system.
I have applied SAP note 1152453 and reactivate the datasource, infosource, and data target.
Still no help here!?
Please advise if you encountered these errors before.
Thanks in advance.
Regards,
David
Edited by: David Tai Wai Tan on Oct 31, 2008 2:46 PM
Edited by: David Tai Wai Tan on Oct 31, 2008 2:50 PM
Edited by: David Tai Wai Tan on Oct 31, 2008 2:52 PMHi Vijay,
I got this error:
Runtime Errors MESSAGE_TYPE_X
Date and Time 04.11.2008 11:43:08
To process the problem further, contact you SAP system
administrator.
Using Transaction ST22 for ABAP Dump Analysis, you can look
at and manage termination messages, and you can also
keep them for a long time.
Short text of error message:
No start information on process LOADING
Long text of error message:
Diagnosis
For process LOADING, variant ZPAK_0SKIJ58741F4ASCSIYNV1PI9U, the
end should be logged for instance REQU_D4FIDCEKO82JUCJ8RWK6HZ9KX
under the log ID D4FIDCBHXPLZMP5T71JZQVUWX. However, no start has
been logged for this process.
System Response
No log has been written. The process (and consequently the chain)
has been terminated.
Procedure
If possible, restart the process.
Procedure for System Administration
Technical information about the message:
Message class....... "RSPC"
Number.............. 004
Variable 1.......... "D4FIDCBHXPLZMP5T71JZQVUWX"
Variable 2.......... "LOADING"
Variable 3.......... "ZPAK_0SKIJ58741F4ASCSIYNV1PI9U"
Variable 4.......... "REQU_D4FIDCEKO82JUCJ8RWK6HZ9KX"
Any idea? -
I sent out a mail, composed by outlook 2007 in HTML format this afternoon which contained graphics, to several of my friends and copied myself. All of them had duly received the mail and were able to see the graphics in the mail in their iphones or ipads. However, the copy that was extended to myself had only the unviewable graphic filename and also an attachment winmail.dat(which cannot be opened) from both my iphone and ipad (both updated with IOS 5.0.1). Prior to this update, I had no problem of seeing graphics or photos in the mails received in both my ipad or iphone. I ran couple of test mails and they all ended up the same.
Any ideas??Turned out, it's the Microsoft SP3 update that caused the problem.
-
How to select data for nested object (Object based on another objects)
Hi,
I have written the following code, but I am not able to fetch data as I fetch from normal table, Plz help.
Following is the sample code -
CREATE TYPE A_OBJ IS OBJECT (
A_NAME VARCHAR2 (100),
A_DESC VARCHAR2 (100)
CREATE TYPE A_TAB IS
TABLE OF A_OBJ
CREATE TYPE B_OBJ IS OBJECT (
B_NAME VARCHAR2 (100),
B_DESC VARCHAR2 (100)
CREATE TYPE B_TAB IS
TABLE OF B_OBJ
CREATE TYPE H_OBJ IS OBJECT (
A A_TAB,
B B_TAB
create type H_TAB is table of H_OBJ
-- Created the function to fill the data into my objects.
Create or Replace Function ABC RETURN H_TAB IS
l_data H_TAB := H_TAB();
v_loop_count BINARY_INTEGER := 1;
obj1 A_TAB;
obj2 B_TAB;
begin
for i in(SELECT AG_PROD_MOD_NR, COMM_NM FROM BV_PRODUCT WHERE AG_PROD_MOD_NR = 'E4440A') loop
obj1 := A_TAB();
obj1.extend;
obj1(obj1.last) := A_OBJ(i.AG_PROD_MOD_NR, i.COMM_NM);
obj2 := B_TAB();
obj2.extend;
obj2(obj2.last) := B_OBJ(i.AG_PROD_MOD_NR, i.COMM_NM);
l_data.extend;
l_data(l_data.last) := H_OBJ(obj1,obj2);
end loop;
Return l_data ;
end;
-- used this SQL for fetching the data using the function -
select *
FROM the ( SELECT cast(ABC ()
as H_TAB) FROM dual )
the above SQL not gives me the data in the as a normal table returns, plz suggest me how to write SQL for above case.
Thanks in Advance,
DeepakFirst try to move your obj1 and obj2 initialization outside of the for loop. Not sure if this is even the issue, but it can't be helping.
obj1 := A_TAB();
obj2 := B_TAB();
for i in(SELECT AG_PROD_MOD_NR, COMM_NM FROM BV_PRODUCT WHERE AG_PROD_MOD_NR = 'E4440A')
loop
obj1.extend;
obj1(obj1.last) := A_OBJ(i.AG_PROD_MOD_NR, i.COMM_NM);
obj2.extend;
obj2(obj2.last) := B_OBJ(i.AG_PROD_MOD_NR, i.COMM_NM);
l_data.extend;
l_data(l_data.last) := H_OBJ(obj1,obj2);
end loop; -
Attachment list in Services for Object toolbar
Does anybody know if there is any user exit or BADI that I can use to filter certain file attachments in Attachment list of Services for Object toolbar.
For example, in transaction XK03 (Vendor display), Services for Object toolbar, you can see the Attachment list and it will display list of pc file attachments, however, we have a requirement to display only those that met certain criteria, is there any BADI or user exit for this?
Thanks in advance for your help.you can use BADI
GOS_SRV_SELECT
for this.
Regards
Raja -
ABAP OO: Duplication of selected data in created objects?
I am new to ABAP OO and I have a conceptual question/concern that I cannot resolve. Can someone explain what I am missing?
I would think that selecting and storing (in internal tables) a large amount of data from many related database tables and, at the same time, creating and storing objects from this same data would unnecessarily consume a huge amount of memory. To avoid this problem, it seems that the selected data and created objects should not be stored in internal tables simultaneously.
Does this concern make sense? If so, how is this problem best handled?
Does it make sense to delete the corresponding data once the objects are created (to free memory)?
Or does it make sense to keep the data and only temporarily create objects as needed?
Thanks.Hello Matt
The approach you describe is to select data first and the feed the object instances with them. <b>Why not let the object instances do the data selection themselves?</b>
I will give you an example what I mean.
(1) Lets assume I want to write an application that allows to deal with cost center hierarchies. On the selection screen you can choose one or many cost center hierarchies.
(2) Using the selection criteria I would select all cost center hierarchies but without any details (just the key values).
(3) Next I would loop over the cost center hierarchies and create a cost center hierarchy instance (a class you have to define yourself) for each key value. The CONSTRUCTOR of this class will have an IMPORTING parameter like <i>id_kostl_hier</i>.
(4) In the CONSTRUCTOR method I first check if the cost center hierarchy exists (if not raise an exception-class based exception) and then do the selection of the hierarchy details (e.g. the cost centers).
(5) The instances are collected in an itab of the "frame" application.
Using this approach you will have little duplication of data within your application. Furthermore, if you really have to deal with huge amounts of data then you could read them only on demand (like in tree controls where the sub-nodes usually are read when the parent node is expanded).
Hope I could give you some fresh insights into this exciting topic.
Regards
Uwe -
I have a primary database that need to import large amount of data and database objects. 1.) Do I shutdown the standby? 2.) Turn off archive log mode? 3.) Perform the import? 4.) Rebuild the standby? or is there a better way or best practice?
Instead of rebuilding the (whole) standby, you take an incremental (from SCN) backup from the Primary and restore it on the Standby. That way, if, for example
a. Only two out of 12 tablespaces are affected by the import, the incremental backup would effectively be only the blocks changed in those two tablespaces (and some other changes in system and undo) {provided that there are no other changes in the other ten tablespaces}
b. if the size of the import is only 15% of the database, the incremental backup to restore to the standby is small
Hemant K Chitale -
How to populate data into view object
Hi all,
I am quite new with ViewObject.
I have one data table which is binding with view object.
I want to populate data into view object from my managed bean.
how can i achieve this kind of scenario?
actually i try to get view object as in the following. but i get only null.
ViewObject viewobject = DCIteratorBinding.getViewObject();
With Regards,
Wai PhyoHi,
You could use the following code snippet to get handle to view object from the iterator.
FacesContext fc = FacesContext.getCurrentInstance();
BindingContainer bindings =
(BindingContainer)fc.getApplication().evaluateExpressionGet(fc,
"#{bindings}",
BindingContainer.class);
DCBindingContainer bc = (DCBindingContainer)bindings;
DCIteratorBinding iterator =
bc.findIteratorBinding("<ITERATOR_ID>");
ViewObject viewObject = iterator.getViewObject();
// Perform operations on the view objectThanks,
Navaneeth -
How to load data from info object to ODS
Hello BW Gurus,
Is their any way to load data from info object to ODS and I am unable to fine the Info source for that particulate info object master data.
For ex: we have 0PROFITCENTER as info object which is getting loaded everyday. We want same data in ODS too but I don't find any info source related to this info object to create update ruled.
Please advise me how to proceed with this,
Thanks,
Swathi.hi Swathi,
as mentioned, if you just need the master data text or attribute update, then it's sufficient to load 0PROFITCENTER master data. (don't forget to 'apply hierarchy/attribute change' - rsa1->tools)
if you are going to update attribute in ods with attribute from 0PROFITCENTER, you can choose look up master data attribute method in update rules.
if the requirement is really need 0PROFITCENTER to assign to update rules, then first you have to 'generate export datasource' for infoobject 0PROFITCENTER, right click the infoobject and 'generate export datasource', then do 'replicate datasource' from bw myself, after that it will available. to display it you may go to rsa1->infosource, and menu settings->display generated objects.
hope this helps.
Maybe you are looking for
-
DVD drive not recognising DVD's
Hi, I've a fairly basic iMac G4 which had a standard drive CD-RW fitted. I've swapped this for a CD/DVD drive out of another redundant iMac but cannot get it to recognise DVD's. It spins up & mounts CD's fine. I've done a system re-install (10.3.x as
-
I've been doing this manually for hundreds of images, and it seems like i could create an action that would reference the folder of images and also reference a text file and merge the two. Is this possible?
-
I want to use extarnal display in i mac
dear sir madam i have imac desktop i want to connet normal desktop throu hdmi cabal i have mini display port to hdmi adapter but i m not abel to connect pls help me
-
HT1937 How can i changen the phone number on ipad2
How can i change the phone number on my ipad?
-
Putting HTML around APEX items
Gday, I am trying to convert the following HTML to APEX. I am trying to put the html around the APEX items but I cannot get them to sit properly in the tables. Can I put html around the APEX items? Or can I put in the HTML and access the objects via