title: How to convert rows into column in SQL Server 2000
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/312861/pivot-using-sql-server-2000">Pivot using SQL Server 2000</a>  </p>
  </blockquote>
  
  
  
  <p>I am using SQL Server 2000 and I need rows to be in columns...</p>
  
  <p>My result set is like this.. resultset can have maximum of 11 rows or less then 11 rows..</p>
  
  <pre><code>batsman
  -----------------
  sachin
  sahwag
  dhoni
  kohli
  ...
  ...
  ...
  </code></pre>
  
  <p>I want this:</p>
  
  <pre><code>batsman1      batsman2      batsman3    .....
  --------------------------------------------------------
  sachin        sahwag        dhoni       .....
  </code></pre>
  
  <p>Also, is there is a way to declare array in SQL Server 2000? If so, what is the syntax.</p>