SSRS - Single page per row - reporting-services

Creating a report that is a display of a persons online application, so there are text boxes and multiple tables per person. I need each person to print on the same page, so a user can select either a particular application, or a date range, like all applications for today and yesterday. I currently have everything in a LIST object with a page break set on it, however the tables in the LIST would throw the "detail member with inner members" error. I found a a way around that using the solution here: http://blogs.lessthandot.com/index.php/datamgmt/dbprogramming/reporting-services-error-the-tablix/ , which got rid of the error, but any multiple row tables return a new row per page, so a person with 3 aliases, will have a 3 page report. So, I am looking for a new tutorial on how to keep everything on one page, but allow my tables to return all results on the same page. Thanks.

I don't know if you are writing the query out or using a stored procedure. If you are using a stored procedure if would make it a lot easier to use SSRS. But to get the grouping correct find a common record between the user and the aliases. Then be sure to pull that common identifier into the stored procedure. Then use the table wizard and pull in all the information you want to see and pull the common identifier into the row group box and it will format for you and group that person on the common identifier and hopefully give you the results you are looking for.

Related

ConcatRelated Returning Multiple Values

I am new to MS Access and am trying to build a database that includes a text roll up (effectively summarising staff feedback collectively to the manager). I have set it up using ConcatRelated (http://allenbrowne.com/func-concat.html) and this works as expected. The only issue is that I cannot seem to ensure that only the first instance of a value is returned, rather than every instance. For example:
The function is bringing back the top view, but I only want it to bring back the Distinct values - please note, as this is a manager view, the same value can appear multiple times in the data retrieved. As such, I almost need the text to de-dupe if it is already there.
Full disclosure - my SQL is not great, so I am using the Expression Builder from the design view
Any help will be appreciated
EDIT for more detail:
The image shows a sample of the data and the output. In this, Mary is the team leader and so is responsible for the areas of John, Steven, Erin, and Harriet. The UID refers to the responsibility area.
As you can see, the dataset has the "minimum target" referenced against the area of responsibility and the output I am getting is duplicating the comments (which I presume is because the value is returned twice), but I am trying to ensure that commentary is summarised, not duplicated.
Note, in the summary output, I am not interested in the areas of responsibility, just the commentary against the staff names.
I hope that makes sense
Build a query that retrieves distinct Comments values for each person:
SELECT DISTINCT Person, Comments FROM table;
or
SELECT Person, Comments FROM table GROUP BY Person, Comments;
Now reference that query in ConcatRelated function as source for Comments values.
Be aware that calling a function like this in query along with aggregating can cause slow performance with large dataset.

Report builder 3.0 Using Reportitems!TexboxXX.Value sometimes creates multiple boxes. Why?

I have 6 Datasets each one is the same query but has a different WHERE clause based on employee type. They generate 6 tables. At the top of the report there is a summary table which uses reportitems!textboxXX.value to grab the totals for 2 particular fields from all the tables. I'm also using a StartDate and EndDate parameter. Each reportitems! expression in the table comes from a different dataset in the report if that is relevant.
When I run the report using dates from yesterday back to the 9th of May I get the desired output.
But when I go to the 8th I get multiple rows all the same.
and as I go even further back I get even more rows of the same information. To my knowledge nothing interesting or different happened on the 8th of May and the tables further down the report look exactly the same. Any idea what might be causing this? The design view looks like this if that helps. There's no grouping or filters on the table.
Still not certain about the mechanics behind this but I found a 'solution' so I figured I'd post it. I just made a new dataset for my summary tables where the query was simply SELECT 1. Now I get a single row every time.

MS-Access Form for multiple queries

Ok here is my dilemma and I am sure more experienced Access users have an easy solution. I have been manually running a set of queries to pull data for business users, that I want to create a form for so they can just run it themselves. This would be easy if it was one query, but the way I have to pull the correct data is first have to run one query that creates a table. I then use that 'new' table in a secondary query to get the data I need.
That first make table query needs to take inputs like supplier number and date range. I then use that output table in another query that sums up total dollar value of purchase orders. I can not include these two steps in one query as it creates an ambiguous outer join.
Any ideas on how I would go about creating a form for something like this?
Well after re-thinking this I think I was OVER thinking it. Instead of creating a table in the first step, I can just save it as a query and join that query to the second query. Then make a form off the two queries.

Why are my records not being inserted in the same order they are being executed?

I'm using Microsoft Office Access as my DBMS and I'm using VBA to write my code for this project.
I'm doing data scraping for items on a website and I encountered something that appeared odd to me after I had inserted my data into a table.
In my code I use a loop to iterate through and collect all the items that the website has to offer. Once I have all the data for one item I insert it into my table and then move on to the next. There's 14,724 items that I need to insert into my table. If I iterate over all of them, they will be added to the table but they are out of order once I look at them in the table, even though all the items are there, however if I adjust the loop to only collect...let's say only the first 10 items then they will appear in the same order in which they were collected which is the same order they appear in the source code for the website.
It is important to note that my table does not have an id field because it is not required as there's one other field that serves as a unique identifier for an item in the table.
This does not seem like a big issue but I'm curious as to why this happens. Is there some kind of limitation when using MS-Access as your DBMS?
Any insight is greatly appreciated.
Thank you.
A table is not a spreadsheet.
This is by design of any relational database engine. Records in a table have no order other than what you eventually assign or apply.
If you want to sort the data (ascending or descending) use a Query. The Table doesn't have any order. Even the Fields don't have any relevant order.

Microsoft Access 2010: Update a field in another table on button click

Basics about the database
I am working on a (relatively) simple database that stores inventory data. I am using Microsoft Access 2010 in order to do this. I have six tables with the following relationships:
Relationships of Database
I have created forms which combine the Transaction table with Ordered, Received, Allocated, or Dispensed. Each form requests an amount which will then be used to update On Hand, On Order, or Allocated (from the Material table) respectively.
The Problem
For example, my form to update Transaction and Order should be able to take in the Amount ordered, save all the data from the fields to the Transaction and Order tables as well as add the amount from Amount to On Order in the Materials table.
I have been working on this database for the past two days. I have searched several times for possible ways to perform a similar function, but have come up with nothing. All the tutorials I have found which seem remotely close to what I need to accomplish are for versions of Access which are much older than 2010. Unfortunately I have had little experience with the actual coding within Access, so I am stuck clicking around within the buttons on its menus.
What I have tried
Currently, the program is set to run the following Update query:
Screenshot of update query
This query works if I have one Material stored in the database but adds all the Amount values from Ordered to On Order every time it is ran, which is unfortunately not what I need it to do. I only need each Amount value added to On Order once.
You need to relate the Ordered and Material tables by adding a foreign key field to the Material table, ex. OrderedFK (Long Integer). This new field must be updated whenever a row is inserted into the Ordered table (assuming the "No" Field is AutoNumber). This is typically performed by using a Form (Ordered) and Sub-Form (Material) and setting the sub-form' Link Master (No) and Link Child fields (OrderedFK).
You can then join the Ordered and Material tables on the Update Query to achieve the desired result.