Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Pivot data from sql 2000

Posted on 2015-02-16
3
Medium Priority
?
140 Views
Last Modified: 2015-02-16
We are trying to create a report that will pivot the output of a query.   The query have multipule fields, but they want it broken out by month/year.   We also use crystal reports 9.  The inv_datem is the month number while the datey is the year.  The goes back one year...Thanks

select       inv_Datem,
            inv_Datey,
            item,
            rollup,
               matlcode,
                cert_desc,
                size,
                type,
            whse,
                inv_amt,
            qty_openOrders,
            cur_sales,
               avg_pricelb            
from   rollupsales
0
Comment
Question by:steven
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 18

Accepted Solution

by:
vasto earned 2000 total points
ID: 40612632
Use CrossTab. This is the analog of pivot in Crystal reports and I believe Crystal 9 supports it.
0
 
LVL 16

Expert Comment

by:DcpKing
ID: 40612695
You might also consider upgrading to a newer version of SQL Server with the Pivot function in T-SQL. You need not even pay - get a copy of SQL Server Express and use it as a report server ...

Mike
0
 

Author Comment

by:steven
ID: 40612725
Thank you we are in the process of upgrading, now...but its a entire ERP system update, so we are looking at 6 months.  At least the managers are shooting for that.
0

Featured Post

Will your db performance match your db growth?

In Percona’s white paper “Performance at Scale: Keeping Your Database on Its Toes,” we take a high-level approach to what you need to think about when planning for database scalability.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
What if you have to shut down the entire Citrix infrastructure for hardware maintenance, software upgrades or "the unknown"? I developed this plan for "the unknown" and hope that it helps you as well. This article explains how to properly shut down …
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

704 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question