我正在尝试选择参数为drop down
和From
以及to date
的记录。
我不知道下面的查询有什么问题,我没有得到任何记录。我知道,有条件的记录。
Submission.Submission Status} = "Submitted"
and {Submission.Status} = "Active"
and
(
if {?Type} = "Application Date" then
{
{Application.Edit Date} IN {?Date From} TO {?Date To}
}
else
if {?Type} = "Submission Date" then
(
{Submission.Edit Date} IN {?Date From} TO {?Date To}
)
else
if {?Type} = "Selection Date" then
(
{Committee_Member.Position Start Date} IN {?Date From} TO {?Date To}
)
)
)
我尝试下面的查询哪个工作完美,当我尝试使用日期不起作用。任何线索?
Submission.Submission Status} = "Submitted"
and
(
if {?Type} = "Application Date" then
{
{Submission.Status} = "Active"
}
....
....
....
)
答案 0 :(得分:0)
假设列数据类型正确并且没有拼写错误,那么您的公式没有任何问题。我唯一能建议的是简化语句,然后逐行调试,直到找到问题为止。从最简单的公式开始,运行报告,看看它是否有效。如果是,请添加下一行并重新测试。
例如,运行类型为“应用程序日期”的报告,并查看是否提供任何记录。如果没有,前两行有问题。如果您看到记录,则通过取消注释日期选择的行来再次尝试。
{Submission.Submission Status} = "Submitted"
and {Submission.Status} = "Active"
and
(
select {?Type}
case "Application Date" : true
//case "Application Date" : {Application.Edit Date} IN {?Date From} TO {?Date To}
//case "Submission Date" : {Submission.Edit Date} IN {?Date From} TO {?Date To}
//case "Selection Date" : {Committee_Member.Position Start Date} IN {?Date From} TO {?Date To}
default : false
)
那有用吗?如果是这样,请尝试下一步:
{Submission.Submission Status} = "Submitted"
and {Submission.Status} = "Active"
and
(
select {?Type}
case "Application Date" : {Application.Edit Date} IN {?Date From} TO {?Date To}
//case "Submission Date" : {Submission.Edit Date} IN {?Date From} TO {?Date To}
//case "Selection Date" : {Committee_Member.Position Start Date} IN {?Date From} TO {?Date To}
default : false
)
等等,直到找到罪魁祸首。