Skip to content

Commit

Permalink
fix: project name computed column scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
RRanath committed Aug 7, 2024
1 parent 9b8b1ef commit 7cbfe49
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,7 @@
begin;

create or replace function ccbc_public.application_project_name(application ccbc_public.application) returns text as $$
select coalesce(asd.json_data ->>'projectTitle', afd.json_data -> 'projectInformation' ->> 'projectTitle') from ccbc_public.application_form_data(application) as afd
left join
ccbc_public.application_sow_data as asd on asd.application_id = application.id
order by asd.id desc
limit 1;
select json_data -> 'projectInformation' ->> 'projectTitle' from ccbc_public.application_form_data(application);
$$ language sql stable;

grant execute on function ccbc_public.application_project_name to ccbc_auth_user;
Expand Down

0 comments on commit 7cbfe49

Please sign in to comment.