using string variable in sql query string having column name in select query

i'm trying to put column name in variable then i m using this string in sql query as:\[code\]string s="ID";string sql="select '"+s+"' from table_name where name='abhk'";cmd=new SqlCommand(sql_pics, con);cmd.ExecuteNonQuery();\[/code\]it says incorrect syntax error near ID\[code\]ID is column name.\[/code\]
 
Back
Top