UDO...Adding records..grids problems...
Hi all,
i developed an UDO bounded to a custom B1 Form, which handles a couple of text fields bounded to user datafields.
In this form there is also a grid bounded to a DataSource which takes data from a query. The enabled property of the grid is off thus to only display tabular data.
The problem is that when i click on new button (to add a new record) the grid becomes automatically cleared.
The problem is the same if i use a matrix, always bounded to a DataSource , and also if it is bounded to userdatasources.
Why this ? Is there a workaround ?
Thanks in advance.
Best regards.
Hi Anoop,
the question i posted is that i don't understand why UDO needs to clear all data in the form, instead to clear only data related to UDO. The grid in the form shows results from a query in another tables, not related with UDO.
Plus the grid in readonly mode.
I think it' s only an UDO problem, and SAP should provide the solution.
Thanks for you answer.
F.
Similar Messages
-
Hi,
I create a UDO , how i get the last added record key after i add document ?
Please Advise. ThanksHi,
Or try oCompany.GetNewObjectCode().
Or if this dosent work try the following.... Before adding the record in the before action = True execute a simple query
select max(docentry) from OINV
And now store that in a variable and execute the same query after the record is added in the beforeaction = false and check if both are same, if not then u have a new record added.
Hope it helps,
Vasu Natari. -
Purchasing Cube -- 0PUR_C01.. "Added record" is showing zero in request
When i try to load the data to this cube, my trasfer record is showing values while Added Record is showing zero values. Whats the problem. Please advise !!
Hi,
Check whether do you have defined the industry sector in R/3. This has to be done before filling the setup table. search the forums with note no 353042.
This is done with the help of Transaction MCB_ which you can find in the OLTP IMG for BW (Transaction SBIW) in your attached R/3 source system.
Here you can choose your industry sector. 'Standard' and 'Consumer products' are for R/3 standard customers, whereas 'Retail' is intended for customers with R/3 Retail only.
You can display the characteristics of the process key (R/3 field BWVORG, BW field 0PROCESSKEY) by using Transaction MCB0.
If you have already set up historical data (for example for testing purposes) by using the setup transactions (Statistical Setup Programs) (for example: Purchasing: Tx OLI3BW, material movements: OLI1BW) into the provided setup tables (for example: MC02M_0SCLSETUP, MC03BF0SETUP), you unfortunately have to delete this data (Tx LBWG). After you have chosen the industry sector by using MCB_, perform the setup again, so that the system fills a valid transaction key for each data record generated. Then load this data into your connected BW by using 'Full update' or 'Initialization of the delta process'. Check, whether the system updates data into the involved InfoCubes now.
If all this is not successful, please see Note 315880, and set the application indicator 'BW' to active using Transaction 'BF11'.
Regards,
Anil Kumar Sharma .P -
I am getting the following error while adding record into the table CM_RECIPE_ITEM :
Error
ORA-20505: Error in DML: p_rowid=626, p_alt_rowid=CRI_ID, p_rowid2=, p_alt_rowid2=. ORA-01410: invalid ROWID ORA-06512: at "COSTMAN.CM_RECIPE_ITEM_T3_AFTER", line 11 ORA-04088: error during execution of trigger 'COSTMAN.CM_RECIPE_ITEM_T3_AFTER'
Error Unable to process row of table CM_RECIPE_ITEM.
Kindly suggest if the problem is because of the Global temporary table or the triggers given below. Also suggest the solution.
Thanking You,
Yogesh
CM_RECIPE_ITEM Table
CRI_ID------CRI_CR_ID--------CRI_BOM_CODE--------CRI_CIFG_CODE---------CRI_CIRM_CODE--------CRI_SEQ--------CRI_QTY--------CRI_RM_COST
625----------464-----------------PRODUCT3001----------FG003----------------------10---------------------------1-------------------60-----------------10
626----------464-----------------PRODUCT3001----------FG003----------------------12---------------------------2-------------------40------------------10
Global temporary table
DROP TABLE COSTMAN.INTERIM CASCADE CONSTRAINTS;
CREATE GLOBAL TEMPORARY TABLE COSTMAN.INTERIM
ROW_ID ROWID
ON COMMIT PRESERVE ROWS
NOCACHE;
CREATE OR REPLACE TRIGGER COSTMAN."CM_RECIPE_ITEM_T3"
BEFORE INSERT OR UPDATE ON "CM_RECIPE_ITEM" FOR EACH ROW
BEGIN
INSERT INTO interim VALUES (:new.rowid);
END;
Trigger to update data on CM_RECIPE table
CREATE OR REPLACE TRIGGER COSTMAN."CM_RECIPE_ITEM_T3_AFTER"
AFTER INSERT OR UPDATE ON "CM_RECIPE_ITEM"
BEGIN
FOR ds IN (SELECT row_id FROM interim) LOOP
UPDATE CM_RECIPE
SET CR_RMC = (
SELECT SUM(CRI_QTY * CRI_RM_COST)/SUM(CR_QUANTITY)
FROM CM_RECIPE_ITEM
WHERE CRI_BOM_CODE = CR_BOM_CODE
AND rowid = ds.row_id
UPDATE CM_RECIPE
SET CR_TOTAL_COST = (
SELECT CIFG_PACKING + CIFG_OVERHEAD +CIFG_OTHERS
FROM CM_ITEM_FG
WHERE CIFG_CODE = CR_CIFG_CODE
AND rowid = ds.row_id
) + CR_RMC;
UPDATE CM_RECIPE
SET CR_GROSS_MARGIN =
(SELECT CIFG_DP_RATE
FROM CM_ITEM_FG
WHERE CIFG_CODE = CR_CIFG_CODE
AND rowid = ds.row_id) - CR_TOTAL_COST) / CR_TOTAL_COST;
END LOOP;
END;
/yogeshyl wrote:
Error
ORA-20505: Error in DML: p_rowid=626, p_alt_rowid=CRI_ID, p_rowid2=, p_alt_rowid2=. ORA-01410: invalid ROWID ORA-06512: at "COSTMAN.CM_RECIPE_ITEM_T3_AFTER", line 11 ORA-04088: error during execution of trigger 'COSTMAN.CM_RECIPE_ITEM_T3_AFTER'
Error Unable to process row of table CM_RECIPE_ITEM.
Kindly suggest if the problem is because of the Global temporary table or the triggers given below. Also suggest the solution.The error message points to the trigger... -
Save required when adding record to avoid multiple record entries@same time
Hello, just wondering if anyone would be so kind as to help me out. I have a small problem that when a user is adding records to my form I want them to add one, then if they go on to add another at the same time (before commiting the first one) that they will be shown a prompt Which states something along the lines of "Before you add another record you must first save the first record, do you wish to do so" , yes will then commit the first record and allow the user to enter the second record, whilst cancel will not allow a second record to be entered.
If anyone would helpout i would be very grateful.Hi
Here is my suggestion, the idea is to use a global variable to memorize the fact that a record has been created :
KEY-CREREC
begin
if :GLOBAL.<BLOCK-NAME>RECORDCREATED = 'FALSE' then
create_record;
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'TRUE';
else
message('Commit or delete before inserting a new record');
message('Commit or delete before inserting a new record');
end if;
end;
=====================================================================
KEY-DELREC
begin
if :system.record_status in ('NEW','INSERT') then
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'FALSE';
end if;
delete_record;
end;
====================================================================
KEY-COMMIT
begin
commit_form;
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'FALSE';
end;
====================================================================
POST-SELECT
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'FALSE';
====================================================================
It's a bit more complicated if you allow the user to go beyond the last record for creating a new record, as KEY-CREREC and KEY-DELREC are not triggered.
In this case, my suggestion is the following :
KEY-CREREC
begin
if :GLOBAL.<BLOCK-NAME>RECORDCREATED = 'FALSE' then
if :system.last_record = 'TRUE'then
next_record;
else
create_record;
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'TRUE';
end if;
else
message('Commit or delete before inserting a new record');
message('Commit or delete before inserting a new record');
end if;
end;
===============================================================
WHEN-NEW-RECORD-INSTANCE
begin
if :system.mode = 'NORMAL' then
if :system.record_status = 'NEW' and :system.last_record = 'TRUE' then
if :GLOBAL.<BLOCK-NAME>RECORDCREATED = 'TRUE' then
message('Commit or delete before inserting a new record');
message('Commit or delete before inserting a new record');
delete_record;
end if;
end if;
end if;
end;
================================================================
KEY-DELREC
begin
if :system.record_status in ('NEW','INSERT') then
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'FALSE';
end if;
delete_record;
end;
=================================================================
KEY-COMMIT
begin
commit_form;
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'FALSE';
end;
===============================================================
WHEN-VALIDATE-RECORD
begin
if :system.record_status = 'INSERT' and :system.last_record = 'TRUE' then
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'TRUE';
end if;
end;
==================================================================
POST-SELECT
:GLOBAL.<BLOCK-NAME>RECORDCREATED := 'FALSE';
================================================================ -
-5002 error ("No Data ") when adding record to a UserTable
B1 2007A
Here's my code. I've stripped it about as far as I could to try and solve this problem... but I must be missing something. Basically, I referenced the UIDIBasicApp for the UserTables portion.
In the "PopulateUserTable" subroutine, where I attempt to add the record with:
lngRetCode = objUserTable.Add()
... lngRetCode comes back as "-5002". The error message is "No Data ".
I've added records with the same data into the table through B1 User-Defined Windows and it accepts the data without a problem. I've been re-checking the code, and searching the forums and the help file since last week, and I haven't found any reference to a problem like this.
Any ideas? Thanks!
Module Module1
Public WithEvents objSboApp As SAPbouiCOM.Application
Public WithEvents objSboCompanyDi As SAPbobsCOM.Company
Public Sub Main()
ConnectUI()
ConnectDI()
CreateUserTable("TP_WhereUsed")
PopulateUserTable("TP_WhereUsed")
End Sub
Public Function ConnectUI()
Dim objSboUiApi As SAPbouiCOM.SboGuiApi
objSboUiApi = New SAPbouiCOM.SboGuiApi
Dim sConnectionString As String
sConnectionString = "0030002C0030002C00530041005000420044005F00440061007400650076002C0050004C006F006D0056004900490056"
objSboUiApi.Connect(sConnectionString)
objSboApp = objSboUiApi.GetApplication
End Function
Public Function ConnectDI()
objSboCompanyDi = New SAPbobsCOM.Company
Try
objSboCompanyDi = objSboApp.Company.GetDICompany()
Catch
objSboApp.MessageBox(Err.Description)
Exit Function
End Try
End Function
Public Sub CreateUserTable(ByVal TableName As String)
Dim lngRetCode As Long
Dim lngErrCode As Long
Dim strErrMsg As String
Dim oUserTablesMD As SAPbobsCOM.UserTablesMD
oUserTablesMD = objSboCompanyDi.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserTables)
oUserTablesMD.TableName = TableName
oUserTablesMD.TableDescription = TableName
lngRetCode = oUserTablesMD.Add
If lngRetCode <> 0 Then
Select Case lngRetCode
Case Is = -2035
'Table already exists.
Exit Sub
Case Else
objSboCompanyDi.GetLastError(lngErrCode, strErrMsg)
objSboApp.MessageBox("Error - Table not created: " & strErrMsg)
End Select
Else
objSboApp.SetStatusBarMessage("Table: " & oUserTablesMD.TableName & " was added successfully", SAPbouiCOM.BoMessageTime.bmt_Short, False)
End If
End Sub
Private Sub PopulateUserTable(ByVal TableName As String)
Dim lngRetCode As Long, lngErrCode As Long, strErrMsg As String
Dim strCode As String, strName As String, intArrayCounter As Integer
Dim objUserTable As SAPbobsCOM.UserTable
objUserTable = objSboCompanyDi.UserTables.Item(TableName)
intArrayCounter = 0
Do Until intArrayCounter > 10
strCode = "Code" & CStr(intArrayCounter)
strName = "Name" & CStr(intArrayCounter)
lngRetCode = objUserTable.Code = strCode
lngRetCode = objUserTable.Name = strName
lngRetCode = objUserTable.Add()
intArrayCounter = intArrayCounter + 1
objSboCompanyDi.GetLastError(lngErrCode, strErrMsg)
Loop
End Sub
End ModuleHi
Try your code with the lines I've added to the code of your CreateUserTable function. Hope it works!
Public Sub CreateUserTable(ByVal TableName As String)
Dim lngRetCode As Long
Dim lngErrCode As Long
Dim strErrMsg As String
Dim oUserTablesMD As SAPbobsCOM.UserTablesMD
oUserTablesMD = objSboCompanyDi.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserTables)
oUserTablesMD.TableName = TableName
oUserTablesMD.TableDescription = TableName
lngRetCode = oUserTablesMD.Add
If lngRetCode <> 0 Then
Select Case lngRetCode
Case Is = -2035
'Table already exists.
Exit Sub
Case Else
objSboCompanyDi.GetLastError(lngErrCode, strErrMsg)
objSboApp.MessageBox("Error - Table not created: " & strErrMsg)
System.Runtime.InteropServices.Marshal.ReleaseComObject(oUserTablesMD)
oUserTablesMD = Nothing
GC.Collect() ' free occupied resource
End Select
Else
objSboApp.SetStatusBarMessage("Table: " & oUserTablesMD.TableName & " was added successfully", SAPbouiCOM.BoMessageTime.bmt_Short, False)
System.Runtime.InteropServices.Marshal.ReleaseComObject(oUserTablesMD)
oUserTablesMD = Nothing
GC.Collect() ' free occupied resource
End If
End Sub -
Hi friends,
I know that the added records can be less than the transfered records. A substantiated discussion was found in one of the earlier threads. But, I have a situation where added records are more than the transfered records. RSA3 shows me 1000 records but, added records in the cube shows 1032 records.
1. Under what circumstances can this happen?
2. How to check where the problem is in this case?
Thanks in advance
Subray HegdeHi,
Probably the records are split in your case in the update rules and hence more no. of added records.
Check this:
Re: transferred records and added records
Re: difference i transfered records and added records
Re: manage infocube
Bye
Dinesh -
What's the difference between Transferred Records and Added Records?
When right click an ODS or a cube to select Manage, then under the 3rd tab called Requests, there are two columns called Transferred Records and Added Records, what's the difference between these two?
ThanksHello KeLviN,
How r u ?
Consider a realtime example.
Assume a transfer of Transactional Data from R/3(with PSA) which is having Unit values in it.
Now, I found in RSA3 2844168 of records. In BW I saw one Data Packet with 306 error records(because of a UNIT value is not available in BW T006 table, Eg. YDD) which are automatically collected in PSA. Now in the Monitor screen you could see 2 Monitor status with GREEN Signals for 2 set of data.
1. with 2843862 records
2. with 306 records
Now, if u manage the Data Target you will get 2844168 in the Transferred Records & 2843862 in the Added Records. and the 306 error records are in the PSA.
Hope this is clear.
Best Regards....
Sankar Kumar
+91 98403 47141 -
Hello, dear all
Please help me!
Flex record webcam problem, how to setting Brightness,Contrast,Saturation and Sharpness?
nsOutGoing=new NetStream(nc);
nsOutGoing.attachCamera(m_camera);
nsOutGoing.publish(filename, "record");
I want to control the Brightness,Contrast,Saturation and Sharpness for the recorded flv file.
At present, I only can control the videodisplay object, but I can not able to control Camera.
Thanks very much!!
kimi
MSN: [email protected]Can I change a Video object to to Camera object, If yes, How do??
nsOutGoing.attachCamera(video as Camera);// it does not work rightly
thanks -
JavaScript error and CATW record locking problem
Hello,
We're having two problems with ESS (CATW and Personal Information (PZM3)) in EP 6. We have an ITS-R/3 landscape.
The JavaScript problem appears intermittently within Personal Data services (Address, Emergency Contact, ...). The actual error reads "object required" and originates from ITS. A user may be able to click through all the ESS services once fine, but on a second click receive the error. Sometimes they can't use the services at all.
The record locking problem happens in Time Sheet (CATW). Even though a user Saves and Releases the Time Sheet, it remains locked and cannot be approved. Alternatively, some users are experiencing locked records when they try to complete their own time sheets.
I'm not sure if these are related.
Has anyone here seen these problems? Any suggestions are most welcome!
Cheers,
ColleenThe best way to nail down the javascript error would be to use the firefox JavaScript debugger extension plugin and put the breakpoints where the problem occurs.
This will exactly tell you which object it is looking for which is not found. Moreover you might be able to find that when it is working fine as you said. So give that a try and I am sure you will be able to figure out the problem.
To me this mostly looks like at time some .js file is not coming through to the browser... but this is just a wild guess based on the symptoms. -
Hi Experts,
I am loading data to cube with full update, now I need to generate the report to get the changed and newly added records based on the date.
Is it possible????
If it's possible, how can I achieve this?????
Please help me.....
Thanks in advance,
Venakt.I am loading data to cube with full update, now I need to generate the report to get the changed and newly added records based on the date.
what you mean by based on date??
When ever the data is refereshed in targets that will be reflected in reports provided if you dont have any aggreagates...if you have then you need to do rollup activity.. -
Transferred Records 5463 but Added Records 0
Hi Experts,
My current project is CRM BI implementation. I am trying to load in 0BPARTNER Master data and DataSource 0BPARTNER_ATTR is enhanced by 44 customed attributes and it is 3.X DataSource. So, I created 44 InfoObjects, added those InfoObjects as an Attributes of 0BPARTNER. I created InfoSource, InfoPackage and Update Rule accordingly. I got data in PSA. But in DataTarget, I saw transferred records and no added records. Where should I troubleshoots and please tell me steps. Thank you.
MdMd,
The behaviour is perfectly fine. As its master data, 0BPARTNER already has the master data entries (primary keys in the P table). Only attributes to the same record have been added through the enhancement you have done.
Please check that the attributes are filled in as you'd expect.
In the scenario that BP was not loaded before and you load master data, you can see a > 0 figure for added records in manage screen as well.
Hope this helps.
Regards,
Ashu -
Any table to see Added Record amount
Hi All,
I am analyzing a DSO data loads and need to compare Added Records for each request. It is kind of inconvenient to look each request one by one in manage option. Does anyone know any table which I can find this information by date?
ThanksHi,
check this table u will get all required things
RSSTATMANPART
Bhaskar
Edited by: shanthi bhaskar on Feb 26, 2009 12:10 AM -
Hi Experts,
I am loading the data into cube from flat file, load is sucess but number of added records are 0. why it happend.
i checked it details tabs it shows Number of data records changed form 6 to 0 in start routine
can any one give me solutions.
Thanks
DavidHI,
Please check whether any 'Delete datapak' statement is there in the start routine. You can debug the code by putting a 'BREAK-POINT' statement. The only thing you have to do is to make PSA as an intermediate step while loading. Once the load is successful, then go to monitor -> Details -> Datapackage -> Right click and select 'simulate update'. In the next pop-up, select the checkbox 'activate debugging in update rule'. Once the debugger is on, press F8 and cursor will appear at your BREAK-POINT statement. Now you can check the value of the individual fields.
Hope this helps.
Regards,
Sourav -
Why can I have a difference between Transferred Records and Added Records
Hello gurus,
What could be the reason for the difference between the Transferred records and the added records in the request for an InfoObjects?
I have in RSA3 6452 Records and in the Manage-InfoObject 1002 Records.
thanks for your help- already existing master data (changed but not new)
- start routine with deletion
- duplicate records (with error handling activated)
- end routine
Maybe you are looking for
-
What kind of community is this...pls someone help
Please someone help me through the activation process....currently stuck on that since yesterday...
-
Hi Gurus, We are facing the below exception message in our PROD environment, please let me know if you have any visibility on the same, POS transaction for 08.03.2014, index 2,032 already exists for 08.03.2014 with index 1,968 Thanks and Regards, Ram
-
Authorization restirction at VL01N
Dear Experts We have 2 dist channels as exports and civil.At VL01N delivery creation level the User should not be able to process the deliveries that belong to Exports Dist channel but can process for civils. Is it possible ? If yes then how?
-
Can I load blackberry apps to my 8330 data phone without accessing the internet
I don't have the package that allows me internet access on my 8330. I only have the email access package. Is there any other way to load an app? I get the download link emailed to me but can't load it in the phone because I don't have the internet ac
-
Downloaded FireFox 14 and now a tiny lock sits to the left of the icon, I can't download the newer version - tells me there is already a version of FireFox running, but there isn't?