Error while Adding Dynamic Rows To Flex DataGrid
Hi friends
I want to add interger for in next next rows while clicking tab button,one i enter all the values in one row if i press tab means next row will be editable.for making that i added the following code.i have some error shows like this
[Bindable]
private static const ADD_TASK:int = 0;
private function editEnd(e:DataGridEvent):void
// Adding a new task
if(e.rowIndex == tasks.length - 1)
var txtIn:TextInput =TextInput(e.currentTarget.itemEditorInstance);
var dt:Object = e.itemRenderer.data;
// Add new task
if(txtIn.text != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(txtIn.text, 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
// Destroy item editor
commPlanDetGrid.destroyItemEditor();
// Stop default behavior
e.preventDefault();
Please if any suggession welcome.
Thanks in advance.
B.venktesan
Venktesan,
You are trying compare String and int..! which is not possible try to case the txtIn.text to int using parseInt(txtIn.text).
ORIGINAL:
if(txtIn.text != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(txtIn.text, 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
EDITED:
if(parseInt(txtIn.text) != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(parseInt(txtIn.text), 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
Thanks
Pradeep
Similar Messages
-
Implicit coercion Error while Adding Dynamic Rows To Flex DataGrid
Hi friends
I want to add interger for in next next rows while clicking tab button,one i enter all the values in one row if i press tab means next row will be editable.for making that i added the following code.i have some error shows like this
[Bindable]
private var tasks:ArrayCollection;
private static const ADD_TASK:int= "";
private function init():void
tasks = new ArrayCollection();
tasks.addItem(new Task(0.01,100000,0));
tasks.addItem({frmAmount:ADD_TASK});
private function checkEdit(e:DataGridEvent):void
// Do not allow editing of Add Task row except for
// "Click to Add" column
if(e.rowIndex == tasks.length - 1 && e.columnIndex != 0)
e.preventDefault();
private function editEnd(e:DataGridEvent):void
// Adding a new task
if(e.rowIndex == tasks.length - 1)
var txtIn:TextInput =TextInput(e.currentTarget.itemEditorInstance);
var dt:Object = e.itemRenderer.data;
// Add new task
if(parseInt(txtIn.text) != ADD_TASK)
tasks.addItemAt(new Task(parseInt(txtIn.text), 0, ""), e.rowIndex);----->Multiple markers at this line:
-1067: Implicit coercion of a value of type String to an unrelated type int.
-txtIn
// Destroy item editor
commPlanDetGrid.destroyItemEditor();
// Stop default behavior
e.preventDefault();
]]>
Please help if any suggession
Thanks in advance
B.VenkatesanVenktesan,
You are trying compare String and int..! which is not possible try to case the txtIn.text to int using parseInt(txtIn.text).
ORIGINAL:
if(txtIn.text != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(txtIn.text, 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
EDITED:
if(parseInt(txtIn.text) != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(parseInt(txtIn.text), 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
Thanks
Pradeep -
Implicit coercion of a value of type String to an unError while Adding Dynamic Rows To Flex DataGrid
Hi friends
I want to add interger for in next next rows while clicking tab button,one i enter all the values in one row if i press tab means next row will be editable.for making that i added the following code.i have some error shows like this
[Bindable]
private var tasks:ArrayCollection;
private static const ADD_TASK:int= "";
private function init():void
tasks = new ArrayCollection();
tasks.addItem(new Task(0.01,100000,0));
tasks.addItem({frmAmount:ADD_TASK});
private function checkEdit(e:DataGridEvent):void
// Do not allow editing of Add Task row except for
// "Click to Add" column
if(e.rowIndex == tasks.length - 1 && e.columnIndex != 0)
e.preventDefault();
private function editEnd(e:DataGridEvent):void
// Adding a new task
if(e.rowIndex == tasks.length - 1)
var txtIn:TextInput =TextInput(e.currentTarget.itemEditorInstance);
var dt:Object = e.itemRenderer.data;
// Add new task
if(parseInt(txtIn.text) != ADD_TASK)
tasks.addItemAt(new Task(parseInt(txtIn.text), 0, ""), e.rowIndex);----->Multiple markers at this line:
-1067: Implicit coercion of a value of type String to an unrelated type int.
-txtIn
// Destroy item editor
commPlanDetGrid.destroyItemEditor();
// Stop default behavior
e.preventDefault();
]]>
Please help if any suggession
Thanks in advance
B.VenkatesanThe error message indicates the problem fairly clearly. _feed_list is defined as a ComboBox in your first line of code. You are passing that as an argument in your populate(_feed_list) line of code. However, the populate function is expecting an XMLList object to be passed, not a ComboBox.
You probably really mean to be using...
populate(feed_items);
since that is the only XMLList to be found -
Error while saving dynamic row values of datagrid with record.
hi friends,
i am trying to add dynamic row in datagrid and save that value with record.i succeeded in first part while i am saving the record the error show like this.
errro:Property fromAmount not found on com.ci.view.Task and there is no default value.
how i resolve this error.
any suggession welcom
thanks in advance.
B.venkatesan
code:
package:
package com.ci.view
[Bindable]
public class Task
public function Task(frmAmount:String,toAmount:String,commissionPercentage:String)
this.frmAmount=frmAmount;
this.toAmount=toAmount;
this.commissionPercentage=commissionPercentage;
public var frmAmount:String;
public var toAmount:String;
public var commissionPercentage:String;
main mxml:
[Bindable]
private var tasks:ArrayCollection;
private static const ADD_TASK:String= "";
private function init():void
tasks = new ArrayCollection();
tasks.addItem(new Task("0","1000","0"));
tasks.addItem({frmAmount:ADD_TASK});
private function checkEdit(e:DataGridEvent):void
// Do not allow editing of Add Task row except for
// "Click to Add" column
if(e.rowIndex == tasks.length - 1 && e.columnIndex != 0)
e.preventDefault();
private function editEnd(e:DataGridEvent):void
// Adding a new task
if(e.rowIndex == tasks.length - 1)
var txtIn:TextInput =TextInput(e.currentTarget.itemEditorInstance);
var txtIn1:TextInput =TextInput(e.currentTarget.itemEditorInstance);
var txtIn2:TextInput =TextInput(e.currentTarget.itemEditorInstance);
var dt:Object = e.itemRenderer.data;
// Add new task
if((txtIn.text) != ADD_TASK)
var x:String=String(txtIn.text);
tasks.addItemAt(new Task("", "", ""), e.rowIndex);
// Destroy item editor
commPlanDetGrid.destroyItemEditor();
// Stop default behavior
e.preventDefault();Venktesan,
You are trying compare String and int..! which is not possible try to case the txtIn.text to int using parseInt(txtIn.text).
ORIGINAL:
if(txtIn.text != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(txtIn.text, 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
EDITED:
if(parseInt(txtIn.text) != ADD_TASK).---->error : Comparison between a value with static type String and a possibly unrelated type int
tasks.addItemAt(new Task(parseInt(txtIn.text), 0, ""), e.rowIndex);----> error:Implicit coercion of a value of type String to an unrelated type int.
Thanks
Pradeep -
Bind variable error while adding dynamic where clause to VO query
hi
i have extended a VO and in the VOImpl i have written the following code
public class HzPuiClassificationListVOExImpl extends HzPuiClassificationListVOImpl
public void initQuery(String partyId, String s1, String classCode)
/* Logging Code*/
if(this.isLoggingEnabled(OAFwkConstants.PROCEDURE))
{this.writeDiagnostics(this," > initQuery() , partyId ="+partyId+" , s1 ="+s1+", classCode="+classCode,OAFwkConstants.PROCEDURE);}
setWhereClauseParams(null);
setWhereClauseParam(0, classCode);
setWhereClauseParam(1, classCode);
setWhereClauseParam(2, partyId);
String query = super.getQuery();
* Check if the whereClause is already present
if(query!=null && query.toUpperCase().indexOf("AAAAA") == -1)
OAApplicationModule am = (OAApplicationModule)this.getApplicationModule();
OADBTransaction oadbTxn = am.getOADBTransaction();
String whereClause = " class_category IN ("+
*" SELECT flv.lookup_code"+*
*" FROM fnd_lookup_values flv, fnd_lookup_values_dfv dfv"+*
*" WHERE flv.rowid = dfv.row_id"+*
*" AND flv.lookup_type = 'XXXXX'"+*
*" AND dfv.context_value = flv.lookup_type"+*
*" AND dfv.oco_enabled = 'Y' "+*
this.addWhereClause(whereClause);
this.executeQuery();
* This is the default constructor (do not remove)
public HzPuiClassificationListVOExImpl()
when i run the page i get this error
java.sql.SQLException: Missing IN or OUT parameter at index:: 2
the original vo query below has 3 bind variables
SELECT *
FROM (SELECT *
FROM (SELECT cc.class_category
,l.meaning
FROM hz_class_categories cc
,fnd_lookup_types_vl l
WHERE cc.class_category = l.lookup_type
AND l.view_application_id = 222
AND EXISTS (
SELECT NULL
FROM hz_code_assignments ca
WHERE ca.owner_table_name = 'HZ_CLASS_CATEGORIES'
AND ca.owner_table_id IS NULL
AND ca.owner_table_key_1 = cc.class_category
AND ca.class_category = 'CLASS_CATEGORY_GROUP'
AND ca.class_code = :1
AND NVL (ca.status, 'A') = 'A'
AND SYSDATE BETWEEN ca.start_date_active AND NVL (ca.end_date_active, SYSDATE + 1))
UNION ALL
SELECT cc.class_category
,l.meaning
FROM hz_class_categories cc
,fnd_lookup_types_vl l
WHERE cc.class_category = l.lookup_type
AND l.view_application_id = 222
AND 'INDUSTRIAL_GROUP' <> :2
AND NOT EXISTS (
SELECT NULL
FROM hz_code_assignments ca
WHERE ca.owner_table_name = 'HZ_CLASS_CATEGORIES'
AND ca.owner_table_id IS NULL
AND ca.owner_table_key_1 = cc.class_category
AND ca.class_category = 'CLASS_CATEGORY_GROUP'
AND NVL (ca.status, 'A') = 'A'
AND SYSDATE BETWEEN ca.start_date_active AND NVL (ca.end_date_active, SYSDATE + 1))
AND hz_classification_v2pub.is_valid_category ('HZ_PARTIES'
,cc.class_category
,:3) = 'T') a
WHERE EXISTS (
SELECT NULL
FROM hz_class_code_denorm
WHERE class_category = a.class_category
AND TRUNC (SYSDATE) BETWEEN NVL (start_date_active, TRUNC (SYSDATE)) AND NVL (end_date_active, TRUNC (SYSDATE))
AND enabled_flag = 'Y'
AND LANGUAGE = USERENV ('LANG'))) qrslt
A similar error was discussed at this link but it did not give final solution
[http://kr.forums.oracle.com/forums/thread.jspa?threadID=618451]
help me to solve this issue..
Thanks,
Varun
Edited by: user10707840 on May 19, 2009 7:18 AMits not the AM code .. its the code in VOImpl...
the same code is working in 11i but when its migrated to R12 its giving this error..
The original seeded VO query in 11i contains the same bind variable :1 at three places
SELECT * FROM (select class_category, meaning from hz_class_categories, fnd_lookup_types_vl l where hz_class_categories.class_category = l.lookup_type and l.view_application_id = 222 and class_category in (select owner_table_key_1 from hz_code_assignments ca where ca.owner_table_name = 'HZ_CLASS_CATEGORIES' and ca.owner_table_id is null and ca.class_category = 'CLASS_CATEGORY_GROUP' and ca.class_code = :1 and nvl(ca.status, 'A') = 'A' and sysdate between ca.start_date_active and nvl(ca.end_date_active, sysdate+1)) union all select cc.class_category , meaning from hz_class_categories cc, fnd_lookup_types_vl l, hz_class_category_uses cu where cc.CLASS_CATEGORY = cu.class_category AND ( UPPER(CU.ADDITIONAL_WHERE_CLAUSE) LIKE decode(:1, 'ORG_GROUP','%PARTY_TYPE%ORGANIZATION%', 'PERSON_GROUP', '%PARTY_TYPE%PERSON%', '%') or CU.ADDITIONAL_WHERE_CLAUSE IS NULL or UPPER(CU.ADDITIONAL_WHERE_CLAUSE) LIKE '%WHERE 1=1%' ) and cu.owner_table = 'HZ_PARTIES' and cc.class_category = l.lookup_type and l.view_application_id = 222 and cc.class_category not in (select owner_table_key_1 from hz_code_assignments hca where hca.owner_table_name = 'HZ_CLASS_CATEGORIES' and hca.owner_table_id is null and hca.class_category = 'CLASS_CATEGORY_GROUP' and nvl(hca.status, 'A') = 'A' and sysdate between hca.start_date_active and nvl(hca.end_date_active, sysdate+1)) and cc.class_category not in ( 'RELATIONSHIP_TYPE_GROUP', 'CLASS_CATEGORY_GROUP') and 'INDUSTRIAL_GROUP' <> :1) QRSLT ORDER BY meaning
the code working in 11i had only one setWhereClauseParam line i.e. setWhereClauseParam(0, classCode);
when i ran the same code in R12 it errd out..
I checked the original R12 query... it has 3 bind variables :1 , :2 and :3 ... so i added 2 more setWhereClauseParam statements
setWhereClauseParam(1, classCode);
setWhereClauseParam(2, partyId);
but still its giving the same error
ORIGINAL R12 query already posted above... -
I am getting the following error while adding record into the table CM_RECIPE_ITEM :
<h4> Error </h4>
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
<h4> CM_RECIPE_ITEM Table </h4>
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
<h4>Global temporary table</h4>
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;
<h4>Trigger to update data on CM_RECIPE table </h4>
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;
/The scripts of the tables CM_ITEM_FG, CM_RECIPE, CM_RECIPE_ITEM are as follows :
<h4>CM_ITEM_FG</h4>
ALTER TABLE COSTMAN.CM_ITEM_FG
DROP PRIMARY KEY CASCADE;
DROP TABLE COSTMAN.CM_ITEM_FG CASCADE CONSTRAINTS;
CREATE TABLE COSTMAN.CM_ITEM_FG
CIFG_CODE VARCHAR2(13 BYTE) NOT NULL,
CIFG_CCG_ID NUMBER NOT NULL,
CIFG_NAME VARCHAR2(50 BYTE) NOT NULL,
CIFG_PACKING NUMBER NOT NULL,
CIFG_OVERHEAD NUMBER NOT NULL,
CIFG_OTHERS NUMBER NOT NULL,
CIFG_DP_RATE NUMBER NOT NULL,
CIFG_CR_BY VARCHAR2(32 BYTE),
CIFG_CR_ON DATE,
CIFG_UPD_BY VARCHAR2(32 BYTE),
CIFG_UPD_ON DATE
TABLESPACE COST_MANAGER
PCTUSED 0
PCTFREE 10
INITRANS 1
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
LOGGING
NOCOMPRESS
NOCACHE
NOPARALLEL
MONITORING;
CREATE UNIQUE INDEX COSTMAN.CM_ITEM_FG_PK_001 ON COSTMAN.CM_ITEM_FG
(CIFG_CODE, CIFG_CCG_ID)
LOGGING
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE UNIQUE INDEX COSTMAN.CM_ITEM_FG_UK_001 ON COSTMAN.CM_ITEM_FG
(CIFG_CODE)
LOGGING
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE OR REPLACE TRIGGER COSTMAN."CM_ITEM_FG_T1"
BEFORE UPDATE ON "CM_ITEM_FG"
FOR EACH ROW
BEGIN
BEGIN
UPDATE CM_RECIPE
SET CR_TOTAL_COST = (CR_RMC + :NEW.CIFG_PACKING + :NEW.CIFG_OVERHEAD + :NEW.CIFG_OTHERS);
END;
BEGIN
UPDATE CM_RECIPE
SET CR_GROSS_MARGIN = (:NEW.CIFG_DP_RATE - CR_TOTAL_COST) / CR_TOTAL_COST;
END;
END;
ALTER TABLE COSTMAN.CM_ITEM_FG ADD (
CONSTRAINT CM_ITEM_FG_PK_001
PRIMARY KEY
(CIFG_CODE, CIFG_CCG_ID)
USING INDEX
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
CONSTRAINT CM_ITEM_FG_UK_001
UNIQUE (CIFG_CODE)
USING INDEX
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
ALTER TABLE COSTMAN.CM_ITEM_FG ADD (
CONSTRAINT CM_ITEM_FG_FK_001
FOREIGN KEY (CIFG_CCG_ID)
REFERENCES COSTMAN.CM_COST_GROUP (CCG_ID));
<h4>CM_RECIPE</H4>
ALTER TABLE COSTMAN.CM_RECIPE
DROP PRIMARY KEY CASCADE;
DROP TABLE COSTMAN.CM_RECIPE CASCADE CONSTRAINTS;
CREATE TABLE COSTMAN.CM_RECIPE
CR_ID NUMBER NOT NULL,
CR_CCG_ID NUMBER,
CR_EFF_FROM DATE,
CR_CIFG_CODE VARCHAR2(10 BYTE) NOT NULL,
CR_BOM_CODE VARCHAR2(50 BYTE),
CR_QUANTITY NUMBER,
CR_RMC NUMBER,
CR_TOTAL_COST NUMBER,
CR_GROSS_MARGIN NUMBER,
CR_CR_BY VARCHAR2(32 BYTE),
CR_CR_ON DATE,
CR_UPD_BY VARCHAR2(32 BYTE),
CR_UPD_ON DATE
TABLESPACE COST_MANAGER
PCTUSED 0
PCTFREE 10
INITRANS 1
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
LOGGING
NOCOMPRESS
NOCACHE
NOPARALLEL
MONITORING;
CREATE UNIQUE INDEX COSTMAN.CM_RECIPE_PK_001 ON COSTMAN.CM_RECIPE
(CR_CCG_ID, CR_ID, CR_CIFG_CODE)
LOGGING
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE UNIQUE INDEX COSTMAN.CM_RECIPE_UK_001 ON COSTMAN.CM_RECIPE
(CR_ID)
LOGGING
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE UNIQUE INDEX COSTMAN.CM_RECIPE_UK_002 ON COSTMAN.CM_RECIPE
(CR_BOM_CODE)
LOGGING
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE OR REPLACE TRIGGER COSTMAN."CM_RECIPE_T1"
BEFORE INSERT ON "CM_RECIPE"
FOR EACH ROW
DECLARE
L_ID NUMBER;
BEGIN
IF INSERTING THEN
IF :NEW.CR_ID IS NULL THEN
--SELECT CM_RECIPE_SEQ.NEXTVAL INTO L_ID FROM DUAL;
:NEW.CR_ID := CM_RECIPE_SEQ.NEXTVAL; --L_ID;
END IF;
:NEW.CR_CR_ON := SYSDATE;
:NEW.CR_CR_BY := nvl(v('APP_USER'),USER);
END IF;
IF UPDATING THEN
:NEW.CR_UPD_ON := SYSDATE;
:NEW.CR_UPD_BY := nvl(v('APP_USER'),USER);
END IF;
END;
ALTER TABLE COSTMAN.CM_RECIPE ADD (
CHECK ("CR_EFF_FROM" IS NOT NULL) DISABLE,
CHECK ("CR_CCG_ID" IS NOT NULL) DISABLE,
CHECK ("CR_QUANTITY" IS NOT NULL) DISABLE,
CHECK ("CR_QUANTITY" IS NOT NULL) DISABLE,
CHECK ("CR_QUANTITY" IS NOT NULL) DISABLE,
CHECK ("CR_QUANTITY" IS NOT NULL) DISABLE,
CHECK ("CR_QUANTITY" IS NOT NULL) DISABLE,
CHECK ("CR_QUANTITY" IS NOT NULL) DISABLE,
CONSTRAINT CM_RECIPE_PK_001
PRIMARY KEY
(CR_ID)
USING INDEX
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
CONSTRAINT CM_RECIPE_UK_002
UNIQUE (CR_BOM_CODE)
USING INDEX
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
<h4>CM_RECIPE_ITEM</H4>
ALTER TABLE COSTMAN.CM_RECIPE_ITEM
DROP PRIMARY KEY CASCADE;
DROP TABLE COSTMAN.CM_RECIPE_ITEM CASCADE CONSTRAINTS;
CREATE TABLE COSTMAN.CM_RECIPE_ITEM
CRI_ID NUMBER NOT NULL,
CRI_CR_ID NUMBER NOT NULL,
CRI_BOM_CODE VARCHAR2(50 BYTE) NOT NULL,
CRI_CIFG_CODE VARCHAR2(10 BYTE) NOT NULL,
CRI_CIRM_CODE VARCHAR2(10 BYTE) NOT NULL,
CRI_SEQ NUMBER,
CRI_QTY NUMBER,
CRI_RM_COST NUMBER,
CRI_CR_BY VARCHAR2(32 BYTE),
CRI_CR_ON DATE,
CRI_UPD_BY VARCHAR2(32 BYTE),
CRI_UPD_ON DATE
TABLESPACE COST_MANAGER
PCTUSED 0
PCTFREE 10
INITRANS 1
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
LOGGING
NOCOMPRESS
NOCACHE
NOPARALLEL
MONITORING;
CREATE UNIQUE INDEX COSTMAN.CM_RECIPE_ITEM_PK_001 ON COSTMAN.CM_RECIPE_ITEM
(CRI_ID)
LOGGING
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE OR REPLACE TRIGGER COSTMAN."CM_RECIPE_ITEM_T2"
BEFORE INSERT OR UPDATE ON "CM_RECIPE_ITEM"
FOR EACH ROW
BEGIN
IF :NEW.CRI_CR_ID IS NULL THEN
SELECT CR_ID INTO :NEW.CRI_CR_ID
FROM CM_RECIPE
WHERE CR_BOM_CODE = :NEW.CRI_BOM_CODE;
END IF;
END;
CREATE OR REPLACE TRIGGER COSTMAN."CM_RECIPE_ITEM_T1" BEFORE
INSERT OR UPDATE ON "CM_RECIPE_ITEM" FOR EACH ROW
DECLARE
L_ID NUMBER;
SEQ NUMBER;
BEGIN
IF INSERTING THEN
IF :NEW.CRI_ID IS NULL THEN
SELECT CM_RECIPE_ITEM_SEQ.NEXTVAL
INTO :NEW.CRI_ID
FROM dual;
END IF;
:NEW.CRI_CR_ON := SYSDATE;
:NEW.CRI_CR_BY := NVL(v('APP_USER'),USER);
SELECT (NVL(MAX(CRI_SEQ),0)+1)
INTO SEQ
FROM CM_RECIPE_ITEM
WHERE CRI_BOM_CODE = :NEW.CRI_BOM_CODE;
:NEW.CRI_SEQ := SEQ;
END IF;
IF UPDATING THEN
:NEW.CRI_UPD_ON := SYSDATE;
:NEW.CRI_UPD_BY := NVL(v('APP_USER'),USER);
END IF;
END;
ALTER TABLE COSTMAN.CM_RECIPE_ITEM ADD (
CHECK ("CRI_RM_COST" IS NOT NULL) DISABLE,
CHECK ("CRI_QTY" IS NOT NULL) DISABLE,
CHECK ("CRI_SEQ" IS NOT NULL) DISABLE,
CONSTRAINT CM_RECIPE_ITEM_PK_001
PRIMARY KEY
(CRI_ID)
USING INDEX
TABLESPACE COST_MANAGER
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
ALTER TABLE COSTMAN.CM_RECIPE_ITEM ADD (
CONSTRAINT CM_RECIPE_FK_002
FOREIGN KEY (CRI_CIRM_CODE)
REFERENCES COSTMAN.CM_ITEM_RM (CIRM_CODE),
CONSTRAINT CM_RECIPE_ITEM_FK_001
FOREIGN KEY (CRI_CR_ID)
REFERENCES COSTMAN.CM_RECIPE (CR_ID));
Yogesh -
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... -
Problem w/: Error while getting estimated row count for view
JDev 10.1.3 - Steps
1. created a ADF VO w/ one bind variable vNAME.
2. Created a basic jspx page, use the data control pal. to drop in VO w/ executeparam option. Use the data control pal to drop in VO w/ ADF Read-Only Table w/ select and sort option. Selected all VO columns in table.
3. Following Error msg occurs when running jspx page -
oracle.jbo.DMLException: Error while getting estimated row count for view object CategoryView, statement SELECT count(1) FROM (SELECT
CATEGORY.CATID CATID,
CATEGORY.NAME NAME,
CATEGORY.PICTURE PICTURE,
CATEGORY.ACTIVE ACTIVE
FROM
CATEGORY
WHERE
(CATEGORY.NAME LIKE UPPER(:vName)||'%')) .
Tested SQL Statement in SQL Worksheet works ok (with a Value replacing ':vName').
Can anyone advise - seems to be a straight forward process that is returning this error msg. I have tried variations of the SQL stmt with no luck. The jspx page errors when the ADF Read-Only Table is added.I seem 2 have the same error, in a slightly different situation.
I have a view which subclasses a Entity with a history column 'CreatedOn'. When performing a quick search/filter on this column I get the same error. The ADF app is build on a DB2 database, so no named parameters here. Instead invalid SQL is created when executing the estimated row count. The WHERE clause contains 'CreatedOn = null', should be 'CreatedOn is null'. Furthermore the input of my quick search is not filled in this clause.
Any help would be appreciated -
Error while adding A/P Credit Memo!
Error while adding A/P Credit Memo..........
'G/L Accounts' (OACT) (ODBC-2028) Message - 131-183
Please advice me .....
Thanks...Hi
Check this thread this may help you.
[Re: AP Invoice - No Matching Account Error]
Regards
Balaji -
Error while adding a connector for SSL..help!!!
i'm getting this error when i added a connector for SSL and restarted tomcat
my connector tag is
<Connector keystorePass="kalima" scheme="https" port="8443" sslProtocol="TLS" redirectPort="-1" enableLookups="true" keystoreFile="Mykeystore" protocol="TLS" keystore="C:\Documents and Settings\santhoshyma\Mykeystore" clientauth="false" algorithm="SunX509" keypass="changeit" secure="true" keytype="JKS">
<Factory className="org.apache.coyote.tomcat5.CoyoteServerSocketFactory" keystorePass="kalima" keystoreFile="C:\SSLTest\Mykeystore"/>
</Connector>
LifecycleException: Protocol handler instantiation failed: java.lang.NullPointe
rException
at org.apache.coyote.tomcat5.CoyoteConnector.initialize(CoyoteConnector.
java:1368)
at org.apache.catalina.core.StandardService.initialize(StandardService.j
ava:609)
at org.apache.catalina.core.StandardServer.initialize(StandardServer.jav
a:2384)
at org.apache.catalina.startup.Catalina.load(Catalina.java:507)
at org.apache.catalina.startup.Catalina.load(Catalina.java:528)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:250)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:424)The question is answered in CRM 7.0 forum:
Getting error while adding a custom field (with input help) through AET -
Error while adding a custom field with Input help via AET
Hi All,
I need to add two custom field under Service orders at Item level in component BT140I_SRVP.
One field is required to have the input search help f4 and autopopulates the second field
I am able to add one field(not requiring help) successfully through AET .
I have created one Zsearch_help in se11 and its successfully running and Autopopulating seocnd field while I am testing it
While adding second field through AET,I need to enter following details as -
field label,search relevant ,serach help etc.
When I type the name of my 'Zsearch_help' against field search help it gives me following error
'Search help is not compatible'.
Secondly,not getting getter and setter methods for the attrributes in BTAdminI.
Last,please tell me if i create zhelp and activate it,would it automatically appear in the list on AETwhile assiging it to input field?
Please help me out.Kindly be detailed as I am new to SAP CRM.
Thanks,
ShivaniThe question is answered in CRM 7.0 forum:
Getting error while adding a custom field (with input help) through AET -
Error while adding a job to scheduler
Hello,
I have a batch job that is running fine in both DEV and QA environment. In DEV, I am able to schedule and run it daily. I created a similar schedule in QA environment using BODS Mgmt Console/Administrator. However, upon Activating the schedule, I am getting the following error message. Would someone know why would this error be thrown and steps to troubleshoot this error?
Thanks.
[Repository:AECON_DW_REPOSITORY Schedule:Daily_Run_QA Error:Error while adding a job to scheduler]
When contacting the server above exception was encountered, so it will be assumed the schedule is not active anymore.Hi Rizwan Tahir ,
Delete the job server associated with the current batch job and recreate it.
Then try creating a new schedule using the new job server.
And take care that job server is created in QA environment.
Hope this should work.
Regards, -
Error while adding Image: ORA-00001: unique constraint
Dear all,
I have an error while adding images to MDM I can´t explain. I want to add 7231 images. About 6983 run fine. The rest throws this error.
Error: Service 'SRM_MDM_CATALOG', Schema 'SRMMDMCATALOG2_m000', ERROR CODE=1 ||| ORA-00001: unique constraint (SRMMDMCATALOG2_M000.IDATA_6_DATAID) violated
Last CMD: INSERT INTO A2i_Data_6 (PermanentId, DataId, DataGroupId, Description_L3, CodeName, Name_L3) VALUES (:1, :2, :3, :4, :5, :6)
Name=PermanentId; Type=9; Value=1641157; ArraySize=0; NullInd=0;
Name=DataId; Type=5; Value=426458; ArraySize=0; NullInd=0;
Name=DataGroupId; Type=4; Value=9; ArraySize=0; NullInd=0;
Name=Description_L3; Type=2; Value=; ArraySize=0; NullInd=0;
Name=CodeName; Type=2; Value=207603_Img8078_gif; ArraySize=0; NullInd=0;
Name=Name_L3; Type=2; Value=207603_Img8078.gif; ArraySize=0; NullInd=0;
Error: Service 'SRM_MDM_CATALOG', Schema 'SRMMDMCATALOG2_m000', ERROR CODE=1 ||| ORA-00001: unique constraint (SRMMDMCATALOG2_M000.IDATA_6_DATAID) violated
Last CMD: INSERT INTO A2i_Data_6 (PermanentId, DataId, DataGroupId, Description_L3, CodeName, Name_L3) VALUES (:1, :2, :3, :4, :5, :6)
Name=PermanentId; Type=9; Value=1641157; ArraySize=0; NullInd=0;
Name=DataId; Type=5; Value=426458; ArraySize=0; NullInd=0;
Name=DataGroupId; Type=4; Value=9; ArraySize=0; NullInd=0;
Name=Description_L3; Type=2; Value=; ArraySize=0; NullInd=0;
Name=CodeName; Type=2; Value=207603_Img8085_gif; ArraySize=0; NullInd=0;
Name=Name_L3; Type=2; Value=207603_Img8085.gif; ArraySize=0; NullInd=0;
I checked all data. There is no such dataset in the database. Can anybody give me a hint how to avoid this error.
One thing I wonder: The PermanentId is allways the same but I can´t do anything here.
BR
Roman
Edited by: Roman Becker on Jan 13, 2009 12:59 AMHi Ritam,
For such issues, can you please create a new thread or directly email the author rather than dragging back up a very old thread, it is unlikely that the resolution would be the same as the database/application/etc releases would most probably be very different.
For now I will close this thread as unanswered.
SAP SRM Moderators. -
We are getting this error while adding entries to SSO database. Its working in other environments and failing in only environment. Please advice.
error MSB4018: The "BizTalk.BuildGenerator.Tasks.SSO.PopulateApplicationProperty" task fa
iled unexpectedly.\r
: error MSB4018: System.Runtime.InteropServices.COMException (0xC0002A40): The external cre
dentials in the SSO database are more recent.\r
error MSB4018: \r
error MSB4018: at Microsoft.BizTalk.SSOClient.Interop.ISSOConfigStore.SetConfigInfo(St
ring applicationName, String identifier, IPropertyBag properties)\r
error MSB4
018: at BizTalk.BuildGenerator.Tasks.SSO.SSOConfiguration.Write(String appNa
me, String propName, String propValue)\r
error MSB4018: at BizTalk.BuildGenerator.Tasks.SSO.PopulateApplicationProperty.Execute
()\r
error MSB4018: at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.IT
askExecutionHost.Execute()\r
error MSB4018: at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExe
cutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost t
askHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask, Boolean& taskRe
sult)
Thanks, Pavan MCTS-Microsoft Biztalk Windows Server 2010Hi,
This error generally arises when your system datetime is not in sync with the Domain Controller datetime. Try following steps:
1. Check if the Windows Time Service is running on your machine or not. Try restarting this service and then restart host instances. Then run your script.
2. If this does not works, have a look at this
link
Hope this will help.
HTH,
Sumit
Sumit Verma - MCTS BizTalk 2006/2010 - Please indicate "Mark as Answer" or "Mark as Helpful" if this post has answered the question -
Getting an error while adding the user in Sharepoint foundation 2010 environment.
Hi,
I am having full control access to SharePoint site. Then i tried add user for that site.
But i am getting following error while adding the user to the site.
An unexpected error has occurred.
Troubleshoot issues with microsoft SharePoint Foundation.
Correlation ID:3035B777-1B7C-4463-B35E-06657B72C2E4
Can you please help me anyone on this.
Thanks,
AshokThis could be any one of a number of things. You need to lookup the Correlation ID in the ULS logs on the SharePoint server. That should provide the additional information necessary to diagnose and solve the problem. Here's a blog post
on how to find the error.
http://habaneroconsulting.com/Blog/Posts/Get_the_Real_SharePoint_Error_using_the_ULS_Logs.aspx#.UvEuffldWik
Paul Stork SharePoint Server MVP
Principal Architect: Blue Chip Consulting Group
Blog: http://dontpapanic.com/blog
Twitter: Follow @pstork
Please remember to mark your question as "answered" if this solves your problem.
Maybe you are looking for
-
Why I didn't invest in the AE ecosystem today
Hi! So today I noticed that Video Copilot has 25% off from their products during a 5 day period. I have been drooling for the Element 3D plugin and I was pretty much sold. I actually put the product in the shopping cart and came very close to finaliz
-
I have gotten linux running in a virtual box. However, it wants as user name/password. I don't know what it is or how to set it up. I did not see any opportunity to set up an account when I was installing it. I tried various reasonable guess (like my
-
Hi, when I want foward an email - I like to use the address tab in email and it ussually brings up an abbreviated address book window which I can then double click on my contact then hit send - great. Now when I click the address tab nothing happens.
-
Any mid size companies for SAP HR to help to get a job as a fresher
hi all, any mid size companies to get a job in sap hr
-
"Create Report" OR ONLY "edit report" with java?
Dear all Is it possible to create a new crystal report with java? Do you have some classnames, methodenames, etc that bring me back on the right track? I found: "With the latest versions of Crystal, there is no way to actually allow your users to cre