在 Oracle Apex 中创建手动链接
我使用下面的代码创建了一个折线图。
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;
当单击折线图中的圆圈时,应重定向到链接。但我在上面的查询中遇到 LINK
问题。当我点击一个圆圈时,重定向到如下所示的网址。
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
但当我单击图表中的圆圈时,我需要将值分配给上面网址中的 s.from_id,s.to_id
。 我该怎么做?
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 ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您不需要只需要从查询中获取值并将它们连接到链接字符串吗?就像这样:
Don't you just need to take the values from the query and concatenate those to your link string?, like this: