I try to make a little webshop with asp.net and c# webapplication. Therefor I already have one page done. If someone selects an item that value will be inserted in a cookie that i can use on a different page to show whats in the "shoppingcart". Iam putting that value in a string so I can read the value but it wont work.
I tried to use In cause and Like between "%value%".
roll1 = Request.Cookies["aStudentCookies"]["id"] + "<br>";
///(The value of roll1 will look like: roll1 = "1,2,34,45,123,56";)
sql = " SELECT Naam, Prijs, GerechtId from[1A-Gerecht] WHERE GerechtId IN roll1";
It keeps telling incorrect syntax for variable roll1.