I have created a line chart using below code.
select * from (
select
'f?p=&APP_ID.:41:&SESSION.:SUBMIT:&DEBUG.::P41_FROM_STOCK_ID,P41_TO_STOCK_ID:s.from_id,s.to_id' LINK,
s.from_id || '-' || s.to_id LABEL,
sum(util.find_usage_from_stock(MATERIAL_THIKNESS,s.from_id,s.to_id)) -
sum(util.find_sheets_sold(MATERIAL_THIKNESS,s.from_id,s.to_id)) diff
from material m, (select lag(stock_id, 1, stock_id) over (order by stock_date) from_id, stock_id to_id
from STOCK
where stock_time not like 'NEW_STOCK') s
where m.active like 'Y'
group by s.from_id,s.to_id
order by s.from_id desc
)
WHERE rownum <= 20
ORDER BY rownum DESC;
when click on a circle in line chart, should redirect to a link. but i have trouble with LINK in above query. when i click on a circle, redirect to url like below.
http://127.0.0.1:8080/apex/f?p=110:41:2026929503975702:SUBMIT:NO::P41_FROM_STOCK_ID,P41_TO_STOCK_ID:s.from_id,s.to_id
but i need to assign values into s.from_id,s.to_id in above url when i click on a circle in my chart.
how can i do that ?
Don’t you just need to take the values from the query and concatenate those to your link string?, like this: