I’m using the next SQLDataSource Select cmnd :
SelectCommand="SELECT [itemTitle]
FROM orders
INNER JOIN items
on orders.itemId = items.itemId
WHERE costumerId = @costumerId ">
The gridview code:
<asp:GridView ID="GridView1" runat="server" CellPadding="4"
DataSourceID="UserProfileOrder" ForeColor="#333333" GridLines="None">
<AlternatingRowStyle BackColor="White" ForeColor="#284775" />
<Columns>
</Columns>
As you see, the is empty, but it’s get the details from the SQLDataSource… so the outpot is:
itemTitle
bla bla bla
There is way to change the header title? for now, it’s display the name of the column from the SELECT command.
in your select query write like