diff --git a/components/pagebody.tsx b/components/pagebody.tsx index 428f4be..1564a80 100644 --- a/components/pagebody.tsx +++ b/components/pagebody.tsx @@ -157,9 +157,11 @@ async function filterData(searchParams: { query?: string; filters?: string }) { }) .join(") AND ("); } - + + filterString.replace(/\W/g, '') const query = `SELECT FIRST_NAME, LAST_NAME, GRAD_YEAR, DORM, DORM_ROOM, \ - USER_ID FROM student_data WHERE (${filterString}) `; + USER_ID FROM student_data WHERE (${filterString})`; + // @ts-ignore const raw: any[] = await queryDb(query);