Insert a column in the middle of existing columns

  • Hi, a user just asked me to edit a report and add a column in the middle of the existing columns... short of manully moving 15 columns one by one, is there any way to do this the simple way???

    Like in Excel, we can insert a column between column c and d, then add whatever formula we want there. That's what I'd like to be able to do here... especially that I need to do this twice on this report.

    TIA.

  • Hi,

    Are you using Report Builder (web app) or report Designer (visual studio basically)? If using Visual Studio Report Designer then right click on the column header area (brown area of grid) and there should be options inserting columns to the left/right or deleting columns. Not sure about Report Builder though - anyone else?

    Josh

    Mao Says RTFM

  • I'm using VS 2005. I'm right-clicking all over the place (from the bottom to the top) and I'm never given the option to add the column where I want it... it always goes at the end... or adds the wrong thing (grouping).

    See the screenshot of what I see when I right click on the matrix grey thing (don't get any other options wherever I right click anyways).

    That's what I have installed :

    Microsoft Visual Studio 2005

    Version 8.0.50727.42 (RTM.050727-4200)

    Microsoft .NET Framework

    Version 2.0.50727 SP1

    Édition installée : IDE Standard

    Dundas Map for Reporting Services 1.5

    Dundas Map for Reporting Services

    SQL Server Analysis Services

    Concepteur Microsoft SQL Server Analysis Services

    Version 9.00.3042.00

    SQL Server Integration Services

    Concepteur Microsoft SQL Server Integration Services

    Version 9.00.3042.00

    SQL Server Reporting Services

    Concepteurs Microsoft SQL Server Reporting Services

    Version 9.00.3042.00

    SQL Prompt 3.8

    For more information about SQL Prompt, see the Red Gate website at

    http://www.red-gate.com

    For customer support, call 1-866-733-4283.

    Copyright © 2006–2008 Red Gate Software Ltd

  • In SQL Server 2005 with the most expensive VS2005 edition Team Suites there is no way to make minor database based changes. I found it is easier for me to save the existing report and recreate it with the new column or stored procedure. I told the reporting services owners about this very crude behavior and was told no plans to change it. However I have not used SQL Server 2008 SSRS for serious development. So save your existing report make the database changes and recreate the report.

    Kind regards,
    Gift Peddie

  • That's the thing Gift... it's not even a database change. My customers wants to add a column in the middle of the report which basically shows (SUM(Cola) + SUM(ColB) ) / # of weeks in the date range of the report.

    All that data is already there... so as you say, might be easier to just rebuild from scratch.

    I'll see what I can do with 2008 as I have that installed as well on another machine.

    That raises another question and I guess I'll find out soon enough, but is it possible to edit a report in a 2008 solution to reimport it into a 2005 solution?

    I know you can't open a 2008 solution with 2005... heck you are even forced to upgrade a 2005 solution to 2008 when opening it, so that might be asking for much :-).

    Thanks you all for the great help.

  • I would just save the current report create a new one with the extra column, think I had to do this also in another report the reason the data is already there so it is not complicated.

    Kind regards,
    Gift Peddie

  • Ninja's_RGR'us (12/8/2008)


    That's the thing Gift... it's not even a database change. My customers wants to add a column in the middle of the report which basically shows (SUM(Cola) + SUM(ColB) ) / # of weeks in the date range of the report.

    All that data is already there... so as you say, might be easier to just rebuild from scratch.

    I'll see what I can do with 2008 as I have that installed as well on another machine.

    That raises another question and I guess I'll find out soon enough, but is it possible to edit a report in a 2008 solution to reimport it into a 2005 solution?

    I know you can't open a 2008 solution with 2005... heck you are even forced to upgrade a 2005 solution to 2008 when opening it, so that might be asking for much :-).

    Thanks you all for the great help.

    I think 2008 can read 2005 saved reports but I don't think you can go back after you have made changes in 2008. From what I have seen you can't even have a report server at 2005 and use the 2008 tools but I haven't done a full test yet.

    I assume you are using a matrix? Try looking at the properties of the matrix (select the top left corner and to right click properties) and select the groups tab. You should be able to edit the column group and add in a new column. Not sure if this is what you were looking for or not.

  • I still don't see anything in the matrix options to add a new DATA column (not another grouping).

    Again here's what I see in case I'm just missing something obvious :

    I'll just get on with it and rebuild the matrix... going to be much faster that way than investing more time in finding a workaround :hehe:.

    TIA for anyone who can find an alternative to that option, which seems like a big waste of time in my humble opinion.

  • Ninja's_RGR'us (12/9/2008)


    I still don't see anything in the matrix options to add a new DATA column (not another grouping).

    Again here's what I see in case I'm just missing something obvious :

    I'll just get on with it and rebuild the matrix... going to be much faster that way than investing more time in finding a workaround :hehe:.

    TIA for anyone who can find an alternative to that option, which seems like a big waste of time in my humble opinion.

    Although it is not the best option you could always modify the rdl by doing a view source and find the code for it and copy one of the existing ones. You could then modify it to show the proper values using the UI.

  • Thanks, sounds like a plan, let me test that on a backup copy of the rdl ;).

    Still no info on the 2008/2005 test, I haven't had time to perform it yet. I had to toy with formatting issues along with dynamic local sorts.

Viewing 10 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic. Login to reply