I have an SQL Datasource:
<asp:SqlDataSource ID="shownMovie" runat="server" ConnectionString="<%$ ConnectionStrings:MovieTix %>" SelectCommand="SELECT movie.title, movie.category FROM [movie],[session],[theatre],[cinema] WHERE cinema.cinemaLocation=theatre.cinemaLocation AND theatre.theatreNumber=session.theatreNumber AND session.movieID=movie.movieID AND ([movieID] = @movieID)"> <SelectParameters> <asp:ControlParameter ControlID="GridView1" Name="movieID" PropertyName="SelectedValue" Type="String" /> </SelectParameters> </asp:SqlDataSource>
However, i get the following error message:
Ambiguous column name 'movieID'.
Basically I am trying to join it up so whatever cinema the customer wishes to see pulls up a record of movies being shown at that chosen cinema from a previous gridview.
Any help would be appreciated.