Quote Originally Posted by kahfee View Post
the query:

addDefaultValue columnName="CONSTANT_EVENT_TYPE_REF" tableName="TB_INVOICE_CYCLE" defaultValueComputed="(SELECT autoid FROM tb_constants c WHERE c.id='1' AND c.constant_type_ref=(select autoid FROM tb_constant_types WHERE id ='EVENT_TYPE'))"
I would rewrite query as a join of TB_CONSTANTS and TB_CONSTANT_TYPES tables - don't see a reason for the inline view.