I have a report that reads Sales orders and Invoices, but some orders are Drop Ships, I have created a sub report to retrieve some values and it was working fine until February, it seems this month has a more records than previously.
I was thinking on adding a duplicated detail section, one for Non Drop ships and other for the Drop ships, but the Visible expression i don't think will work. Even the condition is not satisfied, the processing of the subreport will happen.
Do you guys have a better idea how to handle this ?
Regards.
Related
Ideally this file will take an Order number and based on certain column aspects feed it into the respective tab. (For Reference we will be taking data from a car repair shop to determine if the car being worked on has been scheduled for drop off, at the shop, or completed and left the shop.
For Example we will have an Order number for every Car we work on, this car will have a Date Started & date Completed. Based on these criteria it will take the Order Number and drop it into the correct Tab and the rest of the data will populate with xlookup (or up for something better to try). So as the life of the product is updated it flows to the appropriate tabs.
Data Tab --> Comprehensive List of all Cars(including cars not scheduled) --> Cars being worked on --> Completed Cars
I figured 90% of this can be solved using xlookup and IF statements but where I get stumped is how do I pull the specific Order Numbers into the respective tabs from the Data tab.
I am aware that I need to create a formula to check if a car has been scheduled for drop off vs it being finish so it doesn't find it's way into the complete tab but that should be easy once I am able to pull Order number's into the file.
Not Necessarily looking for an answer but some topics/videos to point me in the right direction:)
I have tried just pasting the data and xlookup the details from the Order Number but that just brings back the manual aspect of the workbook.
the way i am thinking about this is java terms would be:
If(order # = In Shop)
RO# Populates into "cars being Worked on" Tab
but for each tab
Am I going to need to use VBA/Macro to get the desired result or is there something simpler I am missing?
Not Necessarily looking for an answer but some topics/videos to point me in the right direction:)
If you don't want to build a VBA implementation, I'd look into using Power Query. I find Power Query to be a pretty low barrier tool as it has quite an intuitive UI and loads of material on the web.
This implementation would most likely have an input table on one tab and then the other tabs (WIP, Completed, etc.) would be connected to this input table.
In our BI infrastructure we're using Excel's pivot tables to expose the data in an Analysis Service instance (the cube), and thus far we have nothing to complain about.
Excel "reports" can be defined containing pre-selected dimensions as rows, columns and filters, for example we can set the Time dimension as a column slicer, or the Country dimension as a filter slicer. This allows the users to access this pre-defined report with the slicers already in place where they just have to select there own values to slice with if needs be.
However, even tough this is working perfectly the issue emerges when we try to actually pre-define specific values in a filter slicer. These values are getting "randomly" changed after a few days without any particular pattern from what we can observe. (Note that the cube i.e. the data source is being updated daily)
For example, we want to create a report were the users would have the data already filtered by the countries Italy and France upon opening it. So we created a report where we have the Country as a filter slicer and the countries Italy and France set as specific slicers under the Country filter.
Now the problem is that this report would maintain it's structure and selected filter values for just a few days, after which Italy may get de-selected and Germany would now be selected, or only France is maintained as a slicer. And again, we can't seem to observe any particular pattern in these changes, neither the time it's taking to "lose its format", or the filter values being selected to filter with.
Furthermore, note that even tough the underlying data source is changing daily, the pre-selected values are always there and never deleted, i.e. Italy and France in this case, would always be available in the data source. In fact you could still select them in the report, even tough they are no longer selected by default.
Anyone can help us understand why this is occurring and what can be done to go around it?
EDIT
Just realized that the slicer which values keeps changing every once in a while, is a column in another table. For example the Country Italy is in reality a column in a table City and therefore can be found in multiple records such as Rome, Milan etc., and then is exposed as a dimension in SSAS.
In PivotTable Options/Data there is an option called: "Number of items to retain per field" which default is set to automatic.
I believe this might be what causes it to work at random, and then suddenly change. Try changing it to 'max'.
Install BIDS Helper and open Your source code in Visual Studio. Then run Dimension Health Check on the City dimension. I expect it will show some attribute relationship uniqueness issues. Fix the keys or attribute relationships and your problem should be fixed. If you need help knowing how to fix it post a screenshot of Dimension Health Check here.
I used the below line to get the no.of items from a Pivot Field in a "Report Filter": MsgBox pt.PageFields(5).PivotItems.Count
But it is returning 0 everytime. I'm not sure if this is the correct way. This field for sure has Pivot Items in it. Can someone help me?
Assuming you want to know the count of visible items and not just of all items, then iterating through each item to test the .visible status is by far the simplest method. But it might take a while: A per a post I wrote some time back at http://dailydoseofexcel.com/archives/2013/11/14/filtering-pivots-based-on-external-ranges/ it takes upwards of one minute and twenty seconds just to read the .visible status of a PivotField with 20,000 items in it. Many of the PivotTables I work with easily have that number of items in them, so when I write code that must work on any PivotField I don't use that approach.
So if your PivotField has many items, a less straightforward - but potentially much faster - way than Doug's fine approach above is to make a copy of the PivotTable, remove/unfilter every field but the one of interest, change the layout of that field to a PageField, and then count how many rows it occupies.
I usually make TWO copies of the PivotTable, and use one of them to determine what is currently visible in the field, and the other to determine
What (if anything) is filtered but NOT visible due to filters applied
on other PivotFields; and
What (if anything) is not filtered AND not visible
The code to accomplish this is pretty complicated, and part of a commercial add-in I'm building, so I can't share it I'm afraid.
On my userform I have couple of comboboxes: Contractor, Product, Category, Unit. All of them are filled with data from MS SQL database (2012) and then the userform executes a stored procedure and inserts new records. I would like to build a dynamic form where comboboxes update automatically based on the choice from previous combobox.
When a Contractor is chosen from the list I would like the Product list to narrow down and display only products linked with the contrator (using SELECT statment). Then I would like the category and unit to fill automatically based on product chosen.
Of course e.g when new product is typed in, full list in category and unit combobox would display so this will require if statements.
My problem is which event to use ? Before, after update or change event ? Or maybe there are other options to do this ?
I did some reading about these events and it seems that change event wouldn't be a good choice:
"Avoid creating two or more controls having Change events that affect each other — for example, two text boxes that update each other"
but I am not feeling the difference well enough as I haven't used before/after event yet. If any code of what I have done so far might be relevant, please let me know and I'll edit the post.
Thank you for any suggestions.
It sounds like the direction of the changes is only one way. From what you described, you wouldn't have the problem of having two comboboxes changing each other, because the contractor changes the product and the product changes the category and unit. As long as the product's _Change event doesn't change the contractor (which could fire its _Change event, causing a chain of _Change event calls) you are okay. Same thing with the product -- category and product -- unit relationships.
I'll use a blog as an analogy. Our main document type has active and inactive entries in the table. Think of it like blog posts that are set to be published on a pre defined date. They also disappear on a pre defined date.
Does Cassandra offer a way to cleanly query objects basted on if they are currently active, aka active on today's date? The only option I can see is having a second table that contains the active items, along with a regular scheduled job that scans the entire main table for items that are becoming active or inactive.
Is there a neater way?
To save having to scan the entire document table, you could have a second table which contains "buckets" for which items need to be added or removed from the active list. That way you only have to scan "todays bucket" for info on what items are becoming or ceasing to be active.