s_resourcetype_trg.sql

来自「Java写的ERP系统」· SQL 代码 · 共 32 行

SQL
32
字号
CREATE OR REPLACE TRIGGER S_ResourceType_Trg
AFTER UPDATE
	ON S_ResourceType
FOR EACH ROW
DECLARE
/*************************************************************************
 * The contents of this file are subject to the Compiere License.  You may
 * obtain a copy of the License at    http://www.compiere.org/license.html
 * Software is on an  "AS IS" basis,  WITHOUT WARRANTY OF ANY KIND, either
 * express or implied. See the License for details. Code: Compiere ERP+CRM
 * Copyright (C) 1999-2002 Jorg Janke, ComPiere, Inc. All Rights Reserved.
 *************************************************************************
 * $Id: S_ResourceType_Trg.sql,v 1.1 2002/06/21 04:08:34 jjanke Exp $
 ***
 * Title:	Resource Type
 * Description:
 *			Syncronize Resource Type with Product
 ************************************************************************/
BEGIN

	UPDATE	M_Product
	  SET	C_UOM_ID = :new.C_UOM_ID,
	  		M_Product_Category_ID = :new.M_Product_Category_ID,
			C_TaxCategory_ID = :new.C_TaxCategory_ID
	WHERE S_Resource_ID IN
		(SELECT S_Resource_ID FROM S_Resource 
		WHERE S_ResourceType_ID = :new.S_ResourceType_ID);

END S_ResourceType_Trg;
/

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?