View source | Discuss this page | Page history | Printable version   
Toolbox
Main Page
Upload file
What links here
Recent changes
Help

PDF Books
Show collection (0 pages)
Collections help

Search

ERP 2.50:Acceptance Testing/Attribute set script

Script for 2.40/2.3x

 
 DECLARE
 
 v_attributeset_id NUMBER(10);
 v_client_id NUMBER(10);
 
 BEGIN
 
 SELECT MAX(AD_CLIENT_ID) INTO v_client_id FROM AD_CLIENT;
 
 SELECT COALESCE(MAX(M_ATTRIBUTESET_ID),999999)+1 INTO v_attributeset_id FROM  M_ATTRIBUTESET;
 
 INSERT INTO M_ATTRIBUTESET (M_ATTRIBUTESET_ID, AD_CLIENT_ID, AD_ORG_ID, ISACTIVE, CREATED,CREATEDBY, UPDATED, UPDATEDBY, NAME, ISLOT, ISGUARANTEEDATE, ISSERNO)
 VALUES(v_attributeset_id, v_client_id, 0, 'Y', sysdate, 100,sysdate,100,'Lots','Y','Y','N'); 
 	  
 					   
 AD_UPDATE_SEQUENCE;
 
 COMMIT;
 
 END;

Script for 2.50

 
 DECLARE
 
 v_attributeset_id varchar2(32);
 v_client_id varchar2(32);
 
 BEGIN
 
 SELECT AD_CLIENT_ID INTO v_client_id FROM AD_CLIENT WHERE CREATED = (SELECT MAX(CREATED) FROM AD_CLIENT);
 
 AD_SEQUENCE_NEXT('M_Attributeset', v_client_id, v_attributeset_id);
 
 INSERT INTO M_ATTRIBUTESET (M_ATTRIBUTESET_ID, AD_CLIENT_ID, AD_ORG_ID, ISACTIVE, CREATED,CREATEDBY, UPDATED, UPDATEDBY, NAME, ISLOT, ISGUARANTEEDATE, ISSERNO)
 VALUES(v_attributeset_id, v_client_id, 0, 'Y', sysdate, 100,sysdate,100,'Lots','Y','Y','N'); 
       
 
 COMMIT;
 
 END;

Retrieved from "http://wiki.openbravo.com/wiki/ERP_2.50:Acceptance_Testing/Attribute_set_script"

This page has been accessed 4,739 times. This page was last modified on 3 April 2012, at 10:59. Content is available under Creative Commons Attribution-ShareAlike 2.5 Spain License.