Skip to main content
Solved

Can a CF be both referenced and persistent

  • Jan 15, 2020 12:25 PM UTC
  • 5 replies
  • 675 views

Hello, 

 

We’re creating a custom page with a CF’s. 

 

With one attribute, we ideally would like to use implementation type ‘select’ from a read only field type, but also have the ability to use this as a persistent field type (so we can over type if necessary)

 

Any ideas whether this is possible, or any suggestions to workaround?

 

Thanks in advance

Rob

Best answer by Corc22

Thank you both for your time, I tried the first option, but this still doesn’t let enter a non-list item.

@NickPorter agree, but I thought I’d ask in case there was a clever workaround. 

Thanks and all the best

Rob

View original

5 replies

Banu Liyanapathirana
Hero (Employee)
Forum|alt.badge.img+13

@Corc22,

When creating a custom field, you have the ability to create persistent - reference type custom fields. Just create a persistent custom field and select the ‘reference’ as data type.

Under the reference window, you can provide logical unit information. Anyway, there is no option to write a select expression with this combination.

 


Is that what you want?


NickPorter
Superhero (Customer)
Forum|alt.badge.img+18
  • Superhero (Customer)
  • Jan 15, 2020 1:37 PM UTC

If I understand correctly the request is to have a Reference type field so that the user can select a value, but then also make that value/field so that it can be manually entered into with presumably a non-list value.

I don’t think this is possible since it generally defeats the purpose of a lookup field value, but I do understand why it might be wanted in some situations.

Nick

 

 


  • Author
  • Do Gooder (Customer)
  • Answer
  • Jan 15, 2020 1:41 PM UTC

Thank you both for your time, I tried the first option, but this still doesn’t let enter a non-list item.

@NickPorter agree, but I thought I’d ask in case there was a clever workaround. 

Thanks and all the best

Rob


durette
Superhero (Customer)
Forum|alt.badge.img+19
  • Superhero (Customer)
  • Mar 26, 2020 5:27 PM UTC

Try a Persistent field that defaults to a referenced value. You can do this by creating a “BEFORE INSERT” Oracle trigger.

 

CREATE OR REPLACE TRIGGER c_default_field_x_tib

BEFORE INSERT ON my_custom_logical_unit_clt FOR EACH ROW

DECLARE

BEGIN

   :NEW.cf$_field_x := ifsapp.some_api.some_function();

END c_default_field_x_tib;

 


Forum|alt.badge.img+7
  • Sidekick (Partner)
  • Mar 3, 2022 3:42 PM UTC

Hi @Corc22 

I know I am too late, but If I am understanding your requirement correctly, you need a persistent field with a default value set using a ‘SELECT...’ statement, am I right?

If this is the case, you can set Default Value when you create a persistent field. Select a ‘PLSQL Expression’ and type your SELECT statement -
 

 

Thanks.