CaolanBarron / boat-discord

0 stars 0 forks source link

Create a sql placeholder creator function #46

Closed CaolanBarron closed 3 months ago

CaolanBarron commented 3 months ago

There are a few places where the following code is needed to create placeholders in sql for an array:

  `SELECT * FROM active_tags  WHERE player_id = ? AND key IN (${this.activityKeys
                    .map(() => '?')
                    .join(',')})`

It would be nice to have a util function that can do this