AL0186 erroneous message
Nobody has claimed this yet.
- Dominant language
- PowerShell
- Stars
- 881
- Forks
- 285
- Avg merge
- 3d 36m
- Merged PRs (30d)
- 1
Description
1. Describe the bug
A clear and concise description of what the bug is.
Error that a standard field does not exist (it does), when linking a flowfilter using "filter()" instead of "field()".
src\tableext\TeamMemberCue.TableExt.al(13,127): error AL0186: Reference 'Starting Date' in application object 'Time Sheet Header' does not exist
2. To Reproduce
Steps to reproduce the behavior:
field(73901; "Active Time Sheets ASDF"; Integer)
{
CalcFormula = count("Time Sheet Header" where("Owner User ID" = field("User ID Filter"), "Starting Date" = filter("Active Date Filter ASDF")));
Caption = 'Active Time Sheets';
FieldClass = FlowField;
Editable = false;
}
3. Expected behavior
Should give the real error.
4. Actual behavior
Gives a nonsense error.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by compiling the provided AL snippet and compare the AL0186 diagnostic when the FlowFilter uses filter() instead of field(). Trace the compiler path that resolves the referenced field and reproduce the case with the Time Sheet Header and Starting Date references. Done means the diagnostic reports the actual invalid reference or misuse rather than claiming that Starting Date does not exist.
Written by the indexing model from the issue text.
Assessment
- Domain
- compilers, devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100