如何访问oracle-apex中的报告列值?

时间:2018-01-22 11:22:37

标签: oracle oracle11g oracle-apex

我需要" elabora prenotazione"按钮只有在列" stato prenotazione"是"在SOSPESO" 我尝试设置条件,但我不知道如何选择列值

enter image description here

3 个答案:

答案 0 :(得分:1)

如果我理解你的问题,这可能有所帮助:

报告来源:

SELECT
    CASE
        WHEN stato_prenotazione = 'in sospeso' THEN 'elabora prenotazione'
        ELSE ''
    END name_of_column,
prenotazione,
username,
nome,
cognome,
viaggio,
stato_viaggio,
data_prenota,
stato_prenotazione,
numero_ospiti
FROM your_table

然后设置列" name_of_column"输入:链接,并填写目标。

答案 1 :(得分:1)

在SQL中调用apex_page.get_url周围的条件,因此只会在相关时生成链接

正在使用的功能示例,sans条件: https://azureoutput.wordpress.com/2017/10/18/custom-hyperlink-in-interactive-report/

使用它可以使按钮看起来更漂亮,也许可以获得其他一些想法 https://www.grassroots-oracle.com/2015/12/tutorial-include-action-button-in-report.html

有关转义特殊字符的信息,请参阅此内容,否则您只会在报告中看到HTML https://www.grassroots-oracle.com/2017/01/escape-special-characters-apex-demo.html

答案 2 :(得分:0)

这可以通过@sara提到的简单案例陈述来解决。 类似的东西:

select (case stato_prenotazione when 'in sospeso' then 'elabora prenotazione' end) as your_column

我不会保留其他条件,以便在不满足条件时列只包含空值。