Compact report

Getting your data onto paper - or the web - Discussing the reports features of Base
Post Reply
rpriddle
Posts: 8
Joined: Mon Jan 09, 2012 4:11 am

Compact report

Post by rpriddle »

I have a db with 100 records. Each record has 2 name fields, a 12 char. phone number field, a "year" field, and a "month" field (limited to 4 chars.) (There are other fields too, but these are all that are relevant to this report.)

I want to create a report that includes all 100 records, sorted by Month, sub sort by Last, with first and last in same field. July and August are not used.

The report (4 fields per record, 100 records grouped 10/month for 10 months) should fit on one page! So, once I can print the data (in one long report taking 2 pages but only the left half of 2 pages), I need to move half of it from the bottom of the report to the top on the right.

I'm sure this is not hard but I can't figure it out and I'm very frustrated!

TIA for any help

Roger Priddle
(PS - for "I", please read "my wife")...
OOo 3.3 on Win7. <sigh>
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Compact report

Post by Villeroy »

SELECT DISTINCT "this", "that" FROM "Somewhere" ORDER BY Year("date") DESC ,Month("Date") DESC, "name" ASC
selects "this" and "that" without duplicates from table "Somewhere", latest months on top, names sorted ascending within the months.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Arineckaig
Volunteer
Posts: 828
Joined: Fri Nov 30, 2007 10:58 am
Location: Scotland

Re: Compact report

Post by Arineckaig »

The report (4 fields per record, 100 records grouped 10/month for 10 months) should fit on one page! So, once I can print the data (in one long report taking 2 pages but only the left half of 2 pages), I need to move half of it from the bottom of the report to the top on the right.
If I understand correctly you are seeking a two column report. One method is described at:
http://user.services.openoffice.org/en/ ... 23#p206123

Greater flexibility in the layout of reports can be provided by the work-around of using an independent Writer (or Calc if applicable) document linked for example to Villeroy's suggested query in the Base file. This method is fully described at:
http://user.services.openoffice.org/en/ ... 44#p125944
and at:
http://user.services.openoffice.org/en/ ... 83&t=40493
When this issue has been resolved, it would help other users of the forum if you add the word - [Solved] - to the Subject line of your 1st post (edit button top right).
AOOo 4.1.5 & LO 6 on MS Windows 10 MySQL and HSQLDB
Post Reply