Skip to main content
Solved

Change Request auto create default value

  • January 27, 2020
  • 2 replies
  • 747 views

Forum|alt.badge.img+7

When I create a new Change Request Record I would like to Auto Populate the “CR No:” with text like the following.

ABC-0001

Where the 0001 would increment up as a sequence.

 

So after creating 5 Change Request I would have the following “CR No:” in the system.

 

CR No:

ABC-0001

ABC-0002

ABC-0003

ABC-0004

ABC-0005

Any help would be greatly appreciated.

 

Best answer by Himasha Abeywickrama

 Hi @clint1028,

 

I don’t believe there’s a way of doing this through the application. You will have to create a oracle sequence for the Request No in the database and a BEFORE INSERT trigger which you can concatenate the string (‘ABC’) and the sequence number (‘001’). The trigger will look like this,

 

CREATE OR REPLACE TRIGGER eco_req_trig

BEFORE INSERT ON ECO_REQUEST_TAB 

FOR EACH ROW

BEGIN

  SELECT CONCAT('ABC-',eco_sequence.NEXTVAL)

  INTO   :new.request_no

  FROM   dual;

END;

/

 

However, it’s better to create a case and dispatch to IFS In order to get this done through a customization.

 

Hope this helps!

View original
Did this topic help you find an answer to your question?

Himasha Abeywickrama
Superhero (Customer)
Forum|alt.badge.img+18

 Hi @clint1028,

 

I don’t believe there’s a way of doing this through the application. You will have to create a oracle sequence for the Request No in the database and a BEFORE INSERT trigger which you can concatenate the string (‘ABC’) and the sequence number (‘001’). The trigger will look like this,

 

CREATE OR REPLACE TRIGGER eco_req_trig

BEFORE INSERT ON ECO_REQUEST_TAB 

FOR EACH ROW

BEGIN

  SELECT CONCAT('ABC-',eco_sequence.NEXTVAL)

  INTO   :new.request_no

  FROM   dual;

END;

/

 

However, it’s better to create a case and dispatch to IFS In order to get this done through a customization.

 

Hope this helps!


  • Sidekick (Partner)
  • January 28, 2020

One option
Create new custom LU
When change request is created launch event what add line to this LU, change request id and your own id what you combine in sql event action.
Then custom field to original change request view to show value from this new custom LU

Hopefully you got my point what I try to explain ;)


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings