Solved

Creating a read only attribute in a custom logical unit

  • 20 February 2023
  • 2 replies
  • 197 views

Badge +2

 

Hi,

I’m just trying to create a simple Read only attribute on a Custom Logical Unit that fetch’s a field from JT_TASK. Could someone please assist, I am not sure what I am doing wrong? Any help would be much appreciated. 

 

Using the SQL Query Tool I can get the SQL to work.

 

 

icon

Best answer by Tomas Ruderfelt 20 February 2023, 14:33

View original

2 replies

Userlevel 7
Badge +19

In a custom logical unit you can not reference the view, so instead of v.objid you need to prefix with t. But objid is not present in the table.

Instead you can change it to t.ROWKEY

Then you have to change “A.OBJID = :OBJID” to “B.OBJID= :ROWKEY”

You also need to remove some columns in the SQL statement since it may only return one column.

 

Arguments:

t.rowkey

 

Select Statement:

SELECT a.reference_no
FROM jt_task a, a_m_e_n_d_m_e_n_t_s_clv b
WHERE b.cf$_task_seq = a.task_seq
AND b.objid = :ROWKEY

Badge +2

Brilliant, Thankyou !

Reply