report filter problem???

krazy89
Member Posts: 30
Hi everyone,
i just tried to run a custom made report with a filter on the Salesperson Code field:
<>*DEMO|<>*STAFF
basically i don't want any salesperson code that ends with DEMO or STAFF... but this filter doesn't work... can anyone help me to find an easy solution to this?
Thanks,
KraZy
i just tried to run a custom made report with a filter on the Salesperson Code field:
<>*DEMO|<>*STAFF
basically i don't want any salesperson code that ends with DEMO or STAFF... but this filter doesn't work... can anyone help me to find an easy solution to this?
Thanks,
KraZy
KraZy
0
Comments
-
You want to do <>*DEMO & <>*STAFF
Yours didn't work because of this:
Say the salesperson is NAVDEMO. The first part of your filter, <>*DEMO returns false. The second part returns true.0 -
Hey there.. thx for the fast reply...
logically that makes sense... but i've even just tried:
<>*DEMO
and even that doesn't work.... it's like there's no filter at all...
KraZyKraZy0 -
Given that you are working with a custom built report - have you checked if there is any code in the report itself that applies filters to the Sales Person field? If so that could be overwriting your filter entered at run time.
Another issue I've seen in the past is that there are multiple data items used in a report and selectively some filters may get passed between them. Is there anything like this happening?0 -
hey,
no there's no other filtering that should be overriding the inputted filters...
i'm really confused about this one.. the logic is there... the syntax looks right... just doesn't do the filter properly....
KraZyKraZy0 -
I know I've had problems where sometimes when I set a filter it actually looks for the * as a literal * and not a wild card. I can't remember exactly what I did to make it do so or how I fixed it, but I know it was just playing with the syntax. Maybe that's what is going on.0
-
hey... under the properties of the Sales Invoice Line table, there's something in the DataItemTableView and it does do a filter of quantity = 1..
does that prevent all other filters that are applied to it????
i certainly hope it doesn't.. but that's the only other filter that i see anywhere...
KraZyKraZy0 -
how many different types of <something>Staff or <something>Demo do you have?
losing the wild card would help
<>MYSTAFF&<>MYDEMO&<>YOURSTAFF&<>YOURDEMO0 -
hey there...
well.. we have about 12 sales reps.. and each one has a DEMO and a STAFF account....
so it's only 24 in total... but it's such a hassle to do it that way...
<>*DEMO
<>*STAFF
i don't understand why those don't work... there must be something to it.... i'm just not seeing it...
KraZyKraZy0 -
If you want these salesperson accounts with DEMO & STAFF fitered out in more that just this instance..say they are not actually regular sales people then it might be easier to add a field to the salesperson/purchaser table.
Such as a boolean called DEMO-STAFF where you can have it checked off.
Then in your report or any future reports you can check the table the set the filter DEMO-STAFF = no.
I thought that filter did work with SQL but not on native. :-k0 -
so retarded... i don't believe i can't do this simple filter....
i'm not gonna be able to sleep tonite!
KraZyKraZy0 -
Yeah that <> & * don't get along too well0
-
I like the idea of adding a field. That is much easier to filter on.0
-
One of these has to work
SETFILTER(Code, '<>*DEMO')
SETFILTER(Code, '<>*%1', 'DEMO');
I think the second one is more likely. There's only so many ways to set a filter.0 -
hmm.. thx for the suggestion... but i'm trying to apply this filter at run time... and not in the code behind...
Any other suggestions??? anyone know if there's a problem with using the NOT and * together like that???
KraZyKraZy0 -
I have been able to set filters like the ones described on a built in Navision report. Specifically the item list report. I don't know why yours are not working.
You shouldn't have to do a work around, but you might have to. I guess you could try to set the filter in code in the onpredataitem trigger. I would do it on the first lines, that way you can tell if there might be any code that is changing the filters at run time.
If the report is always going to use this filter that's what you should do anyway. If it is not you could add a checkbox to the request form that tells the report to set this filter with code.
Best of luck.0 -
<>*DEMO&<>*STAFF. The or-operator doesn't work here0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions