MS Access SQL Chart Issue / Chart Disappearing - sql

I have a query that works just fine as long as the Alarms form is opened properly with StartDate1 and EndDate1 populated:
Query: AllAlarms
SELECT Table1.FtStageCd, Table1.Date, Table1.OutAl
FROM Table1
WHERE (((Table1.Date) Between [Forms]![Alarms]![StartDate1] And [Forms]![Alarms]![EndDate1]))
ORDER BY Table1.Date;
When I create a chart in MS Access using the above query as its row source using the MS Access chart wizard it is fine until I select a legend. When I select legend in design mode and in Form/Report mode it goes blank white. Without a legend (series) it loads fine.
When I remove the "WHERE (((Table1.Date) Between [Forms]![Alarms]![StartDate1] And [Forms]![Alarms]![EndDate1]))" from the query above, the charts shows data normally (not sorted as I wanted, but data is shown).
I tried generating a separate report with that chart that is separate from the "Alarms" form then load the "Alarms" form first - populating the "StardDate1" and "EndDate1" and this separate isolated form still does not work (implying it doesn't sound like a timing issue).
For reference below is the row source for the chart:
TRANSFORM Sum([AllAlarms].[OutAl]) AS SumOfOutAl
SELECT [AllAlarms].[Date]
FROM [AllAlarms]
GROUP BY [AllAlarms].[Date]
ORDER BY [AllAlarms].[Date]
PIVOT [AllAlarms].[FtStageCd];
I've tried other things like creating the chart and altering it in VBA, but did not find any property useful to edit (tried applying the date range in a different manner - can't override access chart axes). I've tried not using the Access 2016 chart wizard and I simply could not get any chart to show - may be that I don't have the right reference loaded?

I am surprised CROSSTAB works at all. AFAIK, when dynamic criteria is involved in any query that contributes to a CROSSTAB or in the CROSSTAB itself, there must be a PARAMETERS clause or CROSSTAB must specify column headings. Review http://allenbrowne.com/ser-67.html#Param

Related

Can I build an Access chart including series with SQL?

I am trying to build an Access chart that involves the three fields: Days_Since on the x-axis, Rate on the y-axis, and for the points to be grouped together by Type in a series. I am wondering if this is possible using SQL code. I have tried the built-in Access formatting features and they are not seeming to give me what I want. Also, I would like to note that I do not want any of my data summarized. My current SQL code is below and it is displaying without error.
SELECT [Days_Since],[Rate] FROM [Change]
Try an XYScatter chart with RowSource like:
SELECT Days_Since, IIf([Type]="A",[Rate],Null) AS TA, IIf([Type]="B",[Rate],Null) AS TB, IIf([Type]="C",[Rate],Null) AS TC
FROM Change;
Calculate as many "TYPE" fields are there are type values, hopefully not many.

Qlikview Fast Change option is not working

I have created one QV report in which i have added one chart which shows result data.
In that chart properties i have tick fast change allowed type as: Pivot table and Straight table.
My QV desktop version is 12. While selecting one dimension and one measure and click on change the type,at that time it is not working.
I have created my another report in QV version 11 and fast change is working proper over there. Is this the issue of versioning?Or else some property issue?
After clicking on the red highlighted symbol, it still keeps as it is and does not converting to pivot data.
Straight Table:
Pivot Table:
Also below is the Screenshot of the report which i have created in QV version 11. For one dimension and measure,while click on fast change option, it is converting to pivot table as per below:
Can anyone help me out please?
I have already tried by deleting my existing chart and created another new chart with same properties but it is also not working for the new one.
Click on the title of the dimesion and drag it up and to the right. your cursor should go off of the object without releasing the mouse button. to about where my green arrow is.
Then it will look like this

Issue in creation a chart in pentaho

I recently use pentaho BA 8 and I have a problem in the creation of a new chart with sql query in Pentaho.
I've made a query and assign that in the chart, but in the moment to see the preview view, the view appear in blank. FYI, the chart is correctly associated to a row in the layout structure.
My question is, the result of query must be assigned manually in the chart's axis?
The sql query is:
select sum(cantidad) as cantidad, id_cliente from viewdetallecaja where ptl_id = ${ptl}
and the values in the chart properties is attached
Pentaho's chart properties area
can you please add details as to what kind of chart you assigned to. Also check catalina.out which is the log file for Pentaho's BI and paste any errors here if any.
You have assigned the results of the query (Query3) to the chart in the Datasource property. Double check that the query is actually returning results.

Dynamic SSRS report

I had a problem in creating the Dynamic report in SSRS. My problem is:
In a table I have stored SQL scripts with the column SQLScripts. If you execute these SQL scripts you get different number of columns for each script.
My problem is, I have one report with buttons of these scripts, for example test1, test2...like that. If you press test1 button this should take the test one SQL script and should display the report with appropiate columns in that sqlscripts.
I can't create individual reports for each test report, they are plenty. Are there any options for me to solve this problem...
The only way I've been able to get this to work sofar is:
Each report has 2 datasets.
ReportData
DataHeaders
The "DataHeaders" need to have the proper name of the datafields in "ReportData". Be careful since SSRS replaces blanks and special characters with "_"
Now, create a table (or matrix) and drag the DataHeaders as the Columns of your report. (This should be a grouped column). If you run it at this point, you'll see all your columns without any data. Now comes the magic:
Create another report that takes a "DataField" parameter. Create another table or matrix within this report and set it's dataset property to be "ReportData". In the DATA cell for the table, set it to the expression =Fields(Parameters!DataField.Value).Value
Now go back to your first report. Right click and insert a subreport. Right click on the subreport and select "Subreport Properties". Under general, select the second report you created to be used as the subreport. Under parameters, select the DataField parameter and set its value to something like =Fields!DataField.Value
In my case I did some formatting in this expression to fix the above mentioned issue with spaces and special characters, since my stored procedure was initially used in ASP.NET and this was just a proof of concept.
Also in my experience the performance isn't great. In fact it was kinda slow, though I haven't had a chance to switch it to use a shared dataset, which I suspect would help a bit. Please let me know if you find a better solution.
I have not found a way to do this completely dynamically. Here is a similar question with some possible solutions:
How do i represent an unknown number of columns in SSRS?
You basically need to create a 'master dataset' from the other Datasets that are based on your multitude of SQL scripts first.The master dataset should contain the data to be presented in it's most simplistic form, i.e. in a simple list format.
Finally, go to the toolbar in SSRS and drag a 'Matrix' into the report. A Matrix table acts similar to a pivot table in Excel or a CrossTab query in Access that will display whatever's in the Dataset.

SQL Server Reporting Services 2005 - How do you hide the legend label for a chart?

I am reporting on data that lets say has 10 columns. Now some of my clients have data in all 10 of the columns whereas some may only use 7 or 5... you get the idea. Of course I dont want to have to build a new rdl for each possibiliy. Well in the tabular report I can hide the columns fine if no data exists by using the IsMissing property.
Well in the charts, let's say a bar graph, if there is no data for a column it will not show a bar on the graph (which is great) but all of the potential columns still show up in the series legend.
I've read that 2008 gives you that level of chart customization, but 2005 does not. Any other ideas?
I think I actually answered my own question (well, it will work for my scenario). I used the UNPIVOT function available in SQL Server 2005 to put the column data into rows. This gives me a dataset of two columns (Field and Result) with multiple rows now. Now in the SSRS chart, I just drop the Result into the data and the Field into the series and this works out great.
I'm using 2005, but I think for the bar chart that you might be able to do something like this.
Chart properties -> Data Tab -> Series Groups (edit) -> Filters -> Add the appropriate filter to remove series that you don't care about.