0
select 문에서 가져온 데이터를 가져 와서 드롭 다운 상자에 넣어야하지만 select를 수행 한 후에 어떻게해야할지 모르겠다. 성명서. 이것은 현재 코드입니다. 나는 C#과 ADO.net을 사용하고있다.ADO.net을 사용하여 Azure 데이터베이스에서 드롭 다운 목록에 데이터 추가 C#
protected void Possition1_SelectedIndexChanged(object sender, EventArgs e)
{
using (var connection = new QC.SqlConnection("Server=CONNECTIONINFO"))
{
connection.Open();
using (var command = new QC.SqlCommand())
{
command.Connection = connection;
command.CommandType = DT.CommandType.Text;
command.CommandText = @"SELECT * [firstName], [lastName]
FROM [dbo].[Players]
WHERE [position] = 'QB'
ORDER BY [firstName] ASC";
}
}
}
어떤 도움을 주시면 감사하겠습니다.
오류가 무엇인가 도움이 될 것이다? – Mairaj
'*'뒤에'쉼표 '를 추가하십시오. – Mairaj
이 응용 프로그램의 종류 : windows web 또는 wpf? –