A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Ho do I shift empty cells up in an access report



 
 
Thread Tools Display Modes
  #1  
Old December 21st, 2009, 02:45 AM posted to microsoft.public.access.reports
GBA
external usenet poster
 
Posts: 174
Default Ho do I shift empty cells up in an access report

In my contact data base, I have an unequal number of data for each contact,
some have 3 phone numbers some have up to 8 etc. I would like to print out a
directory (phone book) in which records do only show fields that are
populated. In other words, one record may only include 3 lines others may
include 9 lines but I do not want to display and print a fixed number of
lines, only the ones that are populated.
  #2  
Old December 21st, 2009, 04:46 AM posted to microsoft.public.access.reports
Marshall Barton
external usenet poster
 
Posts: 5,361
Default Ho do I shift empty cells up in an access report

GBA wrote:

In my contact data base, I have an unequal number of data for each contact,
some have 3 phone numbers some have up to 8 etc. I would like to print out a
directory (phone book) in which records do only show fields that are
populated. In other words, one record may only include 3 lines others may
include 9 lines but I do not want to display and print a fixed number of
lines, only the ones that are populated.



Depends on what the report's record source records look
like. If you would post some sample records and how you
want their fields to appear in the report, most likely
someone can help figure out how.

--
Marsh
MVP [MS Access]
  #3  
Old December 21st, 2009, 09:08 PM posted to microsoft.public.access.reports
KARL DEWEY
external usenet poster
 
Posts: 10,767
Default Ho do I shift empty cells up in an access report

Sounds like you have a spreadsheet with up to 8 fields for phone numbers.
Normalize your data using a union query.
SELECT FName, LName, Phone1
FROM Yourtable
UNION ALL SELECT FName, LName, Phone2
FROM Yourtable
WHERE Phone2 Is Not Null
UNION ALL SELECT FName, LName, Phone3
FROM Yourtable
WHERE Phone3 Is Not Null
.........
UNION ALL SELECT FName, LName, Phone8
FROM Yourtable
WHERE Phone8 Is Not Null;

In your report group on FName and LName.

--
Build a little, test a little.


"GBA" wrote:

In my contact data base, I have an unequal number of data for each contact,
some have 3 phone numbers some have up to 8 etc. I would like to print out a
directory (phone book) in which records do only show fields that are
populated. In other words, one record may only include 3 lines others may
include 9 lines but I do not want to display and print a fixed number of
lines, only the ones that are populated.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:33 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.