Crystal Report

GKG

Member
Joined
Aug 11, 2005
Messages
18
Programming Experience
1-3
Hi All,

This is my problem ....

I am generating a report using Crystal reports for windows application.

This report displays details of many stores(Shopping Malls).

The details to be displayed in the report is stored in a table caleed "Temp".
This "Temp" has a column called "Category" which has predefined data Eg: Food,Beverages,Stationary.

The table "Temp" also has another column Called "StoreNo".Each storeNo belongs to all the above mentioned Categories.

The data stored in the table is as below:
-------------------------
Category | StoreNo
-------------------------
Food 1
Beverages 1
Stationary 1
Food 2
Beverages 2
Stationary 2

___________________________________________________


In the crystal report i want to display these fields in the following format :

_____________________________________________________
StoreNo Category Category Category
___________________________________________________
1 Food Beverages Stationary

2 Food Beverages Stationary

_________________________________________________

As the details in this report (Food ,Beverages,Stationary) are data in the field "Category"- How do i display it in the horizontal manner???? :confused:

I am able to display it vertically...but this is not how the client wants it to be.

So if any body knows the soln to this plzzzzzzzz help !!!!!!

Cheers,
GKG
 
You need to do a group by Category when running the report expert.

That will generate the report so that all categories appear under their relevant store number.

In terms of having more than one category on a line, I tried to do something similar and couldn't get it working, in the end I told our department that it couldn't be done, and they were then happy to have the "categories" vertically, but as long as they were under their relevant ID field.

Have you gone to Crystal's online knowledge base? I found a lot of good info on their for the reports I'm having to create.

Luke
 
Create a series of SubReports

Just thinking out loud here;
I would start by creating a series of SubReports and variables to pass values of already printed categories.
Im thinking:
Group by StoreNo sort by Category.
Set a variable (@currentCat) to the value of the minimum Category for that StoreNo.
Pass the variable to a SubReport that selects the minimum Category > @CurrentCat.
You would have as many subreports lined up in the detail band as you have Catagories.
You would supress any blank subreports.

There may be some obsticals to overcome here but this might give you an idea for something to try.

Let me know what you come up with.
 
Back
Top