nextjs-cms 0.8.7 → 0.8.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -38,10 +38,10 @@ export const fieldsRouter = router({
38
38
  }
39
39
  const { table, selectIdentifier } = field.destinationDb;
40
40
  const searchPattern = `%${input.query}%`;
41
- const [rows] = await db.execute(sql `SELECT DISTINCT \`${sql.raw(selectIdentifier)}\` as value
42
- FROM \`${sql.raw(table)}\`
43
- WHERE \`${sql.raw(selectIdentifier)}\` LIKE ${searchPattern}
44
- ORDER BY \`${sql.raw(selectIdentifier)}\` ASC
41
+ const [rows] = await db.execute(sql `SELECT DISTINCT \`${sql.raw(selectIdentifier)}\` as value
42
+ FROM \`${sql.raw(table)}\`
43
+ WHERE \`${sql.raw(selectIdentifier)}\` LIKE ${searchPattern}
44
+ ORDER BY \`${sql.raw(selectIdentifier)}\` ASC
45
45
  LIMIT 20`);
46
46
  return rows.map((row) => row.value);
47
47
  }),