I'm getting a syntax error from my SQL command shown in the code below. The error is happening on the ExecuteReader line, saying
Incorrect syntax near the keyword 'JOIN'.'
I have no idea why it's throwing a syntax error, the command works perfectly fine in SQL Server. Here's the code:
private void button1_Click(object sender, EventArgs e)
{
SqlCommand sqlcomViewSmashRoster;
SqlDataReader dataReader;
String strSql, strOutput ="";
strSql = "SELECT Roster.CharacterName, Roster.TotalTournamentsParticiaped, Roster.TotalWins, Roster.TotalLosses, Roster.Championships, Roster.InjuriesCaused, Roster.Injured" +
"FROM Roster" +
"INNER …Run Code Online (Sandbox Code Playgroud)