Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. Swapping the rows and columns

Swapping the rows and columns

Scheduled Pinned Locked Moved ASP.NET
questiondatabase
4 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    srikantha_nagaraj
    wrote on last edited by
    #1

    Hi. I have table in the database. I want to show the table row as column in the gridview. How can i do that?

    C A S 3 Replies Last reply
    0
    • S srikantha_nagaraj

      Hi. I have table in the database. I want to show the table row as column in the gridview. How can i do that?

      C Offline
      C Offline
      Coding C
      wrote on last edited by
      #2

      This link might help you http://www.tsqltutorials.com/pivot.php

      Coding C# www.excitetemplate.com

      1 Reply Last reply
      0
      • S srikantha_nagaraj

        Hi. I have table in the database. I want to show the table row as column in the gridview. How can i do that?

        A Offline
        A Offline
        Abhishek Sur
        wrote on last edited by
        #3

        I think you need to do it in database.. Use TSQL PIVOT function to convert row into columns and vice-versa. Check this http://msdn.microsoft.com/en-us/library/ms177410.aspx for more help.:thumbsup:

        Abhishek Sur


        My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB

        **Don't forget to click "Good Answer" if you like to.

        1 Reply Last reply
        0
        • S srikantha_nagaraj

          Hi. I have table in the database. I want to show the table row as column in the gridview. How can i do that?

          S Offline
          S Offline
          singhkiran
          wrote on last edited by
          #4

          Me too want to know, how to swap the rows and columns. Please help!! Thanks, Kiran _____________________ http://india-jobs-opening.blogspot.com/[^]

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups