?
Solved

Access report details

Posted on 2016-07-27
6
Medium Priority
?
51 Views
Last Modified: 2016-07-28
Dear Experts,

There is MS ACCESS report based on 2 tables: tbl_task (parent) and tbl_subtask)child.
Report presentation grouped by task.
Some tasks have subtasks, then its fine. Both task and subtasks visible on the report.
Some tasks do not have subtasks. Then group is not visible on report.
Is there a way to see the group title even if its empty?

BRGDS,
0
Comment
Question by:hotelguest
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
6 Comments
 
LVL 19

Expert Comment

by:Eric Sherman
ID: 41731372
The Report Object can only group on what's in you underlying table ... if the task is not there it would be impossible to group on it.  I've done this in the past by making a table with all the possible tasks in it and creating a relation to your subtask table.  Then group on the task field in that unique listing all possible task.

Just an idea.

ET
0
 
LVL 38

Expert Comment

by:PatHartman
ID: 41731405
Typically tasks would be the main report and subtasks would be a subreport.  If you are using only a main report make sure that the join between tasks and subtasks is a left join.  That will return tasks even if they don't have subtasks.
0
 

Author Comment

by:hotelguest
ID: 41731492
Good day,

What is "left join"? I did not catch:(
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 19

Expert Comment

by:Eric Sherman
ID: 41731538
Join you tables such that all records from the tasks table are included even if there is no matching subtasks.  That's what I was referring to in my original post.  You don't want to join where the join field i.e. TaskID has to be present in both tables.

ET
0
 
LVL 38

Accepted Solution

by:
PatHartman earned 2000 total points
ID: 41731558
The default join type is INNER.  With an inner join only rows from tableA that have a matching row in tableB are selected.  The other join type is OUTER which is broken into LEFT or RIGHT depending on your perspective.  A LEFT Join (outer is assumed), selects ALL rows from tableA and any matching rows from tableB.  So in your case you will get all tasks whether or not they have any subtasks whereas with an inner join, the query would return only tasks that have at least one subtask.  A RIGHT join is the same as a LEFT join but from the other direction.  It selects all rows in tableB and any matching rows in tableA.

I've attached a database I made that shows various join types.
SQLTraining.zip
0
 

Author Closing Comment

by:hotelguest
ID: 41732506
Thanks. Comprehensive. Clear. Works great.
0

Featured Post

What Is Blockchain Technology?

Blockchain is a technology that underpins the success of Bitcoin and other digital currencies, but it has uses far beyond finance. Learn how blockchain works and why it is proving disruptive to other areas of IT.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question