Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7932811
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T21:07:50+00:00 2026-06-03T21:07:50+00:00

I have a simple question. Suppose I have a Stored Proceudre that returns a

  • 0

I have a simple question.

Suppose I have a Stored Proceudre that returns a table with the following columns: (Item, GreenColour, RedColour), corresponding to all the possible Items and how many of them are “Green” or “Red”. i.e, a possible output could be {(Apple, 4, 2), (Chair, 1, 2)}.

What I want to do in the report is the following:

In the header section, write four columns: “Item”, “Green”, “Red” and “Total”; where “Total” corresponds to the total per row. Then in the “Details” section adding the “GreenColour”, “RedColour” and some other “TotalColours” field (Which I don’t know well). And also adding an additional line at the bottom with the totals per column.

This sounds very similar to the “CrossTab” tool, but it can’t be done that way.
I know a possible answer is modifying the StoredProcedure by adding the “Total” column and compute it in the query. And adding the “Total” per column with a UNION after the query, where “Item” is “Total” and values of “Green” and “Sum” are “SUM” of another query. But I don’t want to do it this way, I want Crystal Reports to solve it.

Thanks and I apologize of writing so much for asking such a simple question.

Edit: The wanted output for my example would be:

Item      Green Colour    Red Colour    Total
Apple          4              2           6
Chair          1              2           3
Total          5              4           ¿9?

Also would like to know if it’s possible to make both ways with the ‘9’ and without it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T21:07:52+00:00Added an answer on June 3, 2026 at 9:07 pm

    You’re right, crosstabs are overkill for this. Just create a formula to sum the colors:

    {table.GreenCount} + {table.RedCount}

    To get the report totals (the 9 in your example), just insert a summation summary. (Right-click the formula field you just created -> “Insert” -> “Summary” -> “Calculate this summary” as Sum).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a simple question about a java map.Suppose I have a map that
Simple, probably dumb question: Suppose I have a Java server that stores in memory
I got a simple question here Let's suppose we have a codebase that employs
I have a simple question. Is there a way ( using reflections I suppose
One simple question.. Let's suppose in Matlab we have a variable: numEntries = 8
I have a simple question, but I'm about 80% sure that the answer to
I have a simple question that I am posing mostly for my curiousity. What
Suppose I have a MySQL table called MyTable, that looks like this: +----+------+-------+ |
I have a very simple regex question. Suppose I have 2 conditions: url =
I have a very simple question. Lets suppose there is C# project name Game

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.