473,491 Members | 2,221 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Access Report Generation

190 New Member
I need to generate a report using crosstab query....
i want report as follows.....
main option1
sum of (opt1)
sum of (opt2)
sum of(opt3)
sub option 1
opt 1
opt 2
opt 3
Sub option 2
opt 1
opt 2
opt 3
main option2
sum of (opt1)
sum of (opt2)
sum of(opt3)
sub option 1
opt 1
opt 2
opt 3
Sub option 2
opt 1
opt 2
opt 3
can any body help me in getting way to get sum of(opt1) ........
Dec 29 '07 #1
8 1750
nico5038
3,080 Recognized Expert Specialist
The structure isn't quite clear.
What's the table structure you use for generating this report ?
Nic;o)
Dec 30 '07 #2
Shalini Bhalla
190 New Member
i have 3 tables

1) main_ind_mast (contains Main Industries)
main_ind_code main_ind_name
0 Chemicals
1 Transport

2) ind_mast (contains subindustries for main industries)
ind_code ind_name Main_ind_code
01 xyz 0
02 hij 0
03 abc 1
]3) data (contains detail info of individuals)
state name ind_code gender emp_code
AP mr.ram 01 m 1234
AP raKhee 02 F 1233
HP mr.rami 01 m 1235
HP mr.raheem 02 m 1236
HP mr.rami 01 f 1237
HP mr.raheem 02 m 1238

i m trying to put things formatted but things are getting unformated in this window why so ...?
Dec 30 '07 #3
nico5038
3,080 Recognized Expert Specialist
OK, your table structure looks like:

1) main_ind_mast (contains Main Industries)
main_ind_code (*)
main_ind_name

2) ind_mast (contains subindustries for main industries)
ind_code (*)
ind_name
Main_ind_code (FK)

3) data (contains detail info of individuals)
emp_code (*)
state
name
gender
ind_code (FK)

The (*) fields should be the unique identifier and (FK) stands for ForeignKey and point to another table.
First create a query that Joins these tables by Main_ind_code ("main_ind_mast" and "ind_mast" ) and ind_code ( "ind_mast" and "data" )
Run this query and make sure you have as many rows as there are in the "data" table. If not, then there's something wrong with the uniqueness of your key fields (those marked by (*) )

Now use this query to create a new query with the type "GroupBy" (use e.g. the "E" looking button) and place the ind_code and place the gender field twice.
Change the first Gender field into:
GenderM:IIF(Gender='m',1,0)
and the second into:
GenderF:IIF(Gender='F',1,0)
Finally change the "GroupBy" under these two fields into "Sum"
Run this query to see the count per gender per ind_code.

Nic;o)
Dec 30 '07 #4
Shalini Bhalla
190 New Member
ok, thanks a lot ..
but my problem is that i want to generate report , how to get these total in the begning of Ist grouping
Dec 30 '07 #5
Shalini Bhalla
190 New Member
one more thing that i forgot to tell you is that i want it state wise & Main_ind wise report i.e

if we make crosstab query main_ind_name , ind_name & gender will be rowheading , state will be column heading and sum of emp_no will be value

now at each change of Ist level grouping(i.e main_ind_name) i want the sum of each IIIrd level grouping(i.e gender wise Male & female).
Dec 30 '07 #6
nico5038
3,080 Recognized Expert Specialist
I was starting to generate a query to produce the results.
The totals (as indicated before) can be places in a report section's header or footer when needed by adding an unbound field with a:
=Sum(fieldname)
So first create the query(queries) to get the "basic" data and then use the Grouping levels (button looks like [= ) to add the header and/or footer for the totals.

Your description indicated that data was duplicated, thus start with making correct queries... :-)

Nic;o)
Dec 30 '07 #7
Shalini Bhalla
190 New Member
no i m not getting it ......


the main problem is that i want query to be in crrostab form to generate report
pls allow me to send u the sample of my report and data structure thrue mail ...
Dec 31 '07 #8
nico5038
3,080 Recognized Expert Specialist
You can post an attachment here. Just create a new message and after Submitting use the edit link (bottom right) to add an attachment.

Nic;o)
Dec 31 '07 #9

Sign in to post your reply or Sign up for a free account.

Similar topics

0
861
by: Abhi | last post by:
I am in process of designing a report generation application. Now here is breif background about my workplace ...... my system admin is a big microsoft hater .... so does not allow any microsoft...
4
1677
by: Nathaniel Price | last post by:
I'm new to this list, so I'm not sure if this is the right place to post this. If not, please direct me to where it would be better to post it. Anyway, I'm creating a report generation tool of...
0
2939
by: Frederick Noronha \(FN\) | last post by:
---------- Forwarded message ---------- Solutions to Everyday User Interface and Programming Problems O'Reilly Releases "Access Cookbook, Second Edition" Sebastopol, CA--Neither reference book...
49
14276
by: Yannick Turgeon | last post by:
Hello, We are in the process of examining our current main application. We have to do some major changes and, in the process, are questionning/validating the use of MS Access as front-end. The...
1
1670
by: vipindev.s | last post by:
hi all i am not much expert in asp.net. i am using crystal rpt for report generation. is any other report generation method is available??? i use push method to creat report, and it is working...
2
9332
by: amith.srinivas | last post by:
Hi all, From a word macro in VBA, I am trying to create a report in access DB. The report is based on a query with a parameter. I am using Set rpt = Application.CreateReport rpt.RecordSource =...
2
1828
by: chiefsitebuilder | last post by:
I have a question about saving an MS Access program to CD and verifyng that the program works after being saved. Here is my situation, I have a person who developed an application for me using...
2
2060
by: Jack | last post by:
Hello All, Can anyone here suggest me a solution to solve my follwoing problem? 1) I got a .aspx page and on that page i got a combo box and a command button. Combo box displays records from the...
1
1587
by: =?Utf-8?B?S3VtYXIuQS5QLlA=?= | last post by:
I am using Excel automation for a report. Dim objExcel As New Excel.Application objExcel.DisplayAlerts = False Dim objWorkbooks As Excel.Workbooks = objExcel.Workbooks Dim objWorkbook As...
7
8493
by: tman69 | last post by:
I apologize in advance for the length of this posting and will attempt to simplify as much as possible. I have an automation application in MS Access which generates reports in Excel and emails...
0
7115
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7154
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7190
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6858
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5451
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4881
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4578
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3086
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
1
633
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.