Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsReportsReportsGenerating a Year In Review with Reports ModuleGenerating a Year In Review with Reports Module
Previous
 
Next
New Post
3/13/2011 6:23 PM
 
Hi,

I have a site where we post schedules (e.g. January on January.aspx, February on February.aspx), track and approve vacation requests (using FormAndList Module), and track various other things for the academic year using a comibination of Text/HTML modules and FormAndList modules

I'd like to create a "Year In Review" report that has all the schedules in a section, all the form and list data in a section (e.g. except the vacations marked "canceled"), etc.

I'd assume the Reports module is the way to go.

I need some help with the syntax, I think

SELECT content WHERE ModuleTitle="January"  ??

SELECT content WHERE ModuleTitle="Vacation Requests" and FNLColumn.Status does not equal "Canceled"  (This is a form and list module) 

I know that's way off... 

 
New Post
3/13/2011 7:44 PM
 
Been working on syntax with examples

SELECT dbo.HtmlText.Content 
FROM dbo.HtmlText 
INNER JOIN dbo.TabModules ON dbo.TabModules.ModuleID = dbo.HtmlText.ModuleID
WHERE dbo.TabModules.ModuleTitle='January'

---THIS RETURNS 5 records.  I can't figure out which record if visible... and which are stored.  In the SQL database, I assume I have to use 

MAX(dbo.HtmlText.LastModifiedOnDate)

To find the most recently updated version of the January schedule.


It'd also be nice to have an array of the values of Module Titles, but I don't really know how to implement that...

SELECT dbo.HtmlText.Content 
FROM dbo.HtmlText 
INNER JOIN dbo.TabModules ON dbo.TabModules.ModuleID = dbo.HtmlText.ModuleID
WHERE dbo.TabModules.ModuleTitle=ARRAY ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December']
 
New Post
3/14/2011 10:54 AM
 
Progress so far:

SELECT dbo.HtmlText.Content, dbo.HtmlText.ModuleID, dbo.HtmlText.LastModifiedOnDate
FROM dbo.HtmlText 
INNER JOIN dbo.TabModules ON dbo.TabModules.ModuleID = dbo.HtmlText.ModuleID
WHERE dbo.TabModules.ModuleTitle='January' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID)


Now need to figure out how to do an array, and how to get FnL data into the same report.
I installed the FnL Datasource at http://dnnreports.codeplex.com/releases/view/34332

I'm thinking I might have to do 2 separate reports... one with HTML modules, one with FnL datasource?
 
New Post
3/14/2011 11:39 AM
 
So I have this huge query, but  WHERE dbo.TabModules.ModuleTitle=ARRAY ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'] doesn't work --- and the query is too huge to put into the reports module -- it gets cut off even if uploading.  However, pieces of it work so I assume the whole thing would work if it fit.

Other pending issue is displaying the FnL data on the same report (using 2 different datasources in 1 report).





SELECT dbo.HtmlText.Content, dbo.HtmlText.ModuleID, dbo.HtmlText.LastModifiedOnDate
FROM dbo.HtmlText 
INNER JOIN dbo.TabModules ON dbo.TabModules.ModuleID = dbo.HtmlText.ModuleID
WHERE (dbo.TabModules.ModuleTitle='June' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='July' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))




OR


(dbo.TabModules.ModuleTitle='August' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='September' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='October' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='November' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))




OR


(dbo.TabModules.ModuleTitle='December' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='January' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='February' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='March' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='April' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='May' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))


OR


(dbo.TabModules.ModuleTitle='June' 
AND dbo.HtmlText.LastModifiedOnDate = (
SELECT MAX(last_mod_alias.LastModifiedOnDate) 
FROM dbo.HtmlText AS last_mod_alias
WHERE last_mod_alias.ModuleID = dbo.HtmlText.ModuleID))

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsReportsReportsGenerating a Year In Review with Reports ModuleGenerating a Year In Review with Reports Module


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out