sqlx icon indicating copy to clipboard operation
sqlx copied to clipboard

fix: bindArray on SELECT from VALUES list

Open xyz1hang opened this issue 2 years ago • 4 comments

  • fixBound currently assumes named var in VALUES is only from INSERT
  • bindArray is not populating the right number of placeholders

Ideally the regex should be something like: (?<!(?i)into)\W+(?i)VALUES\s*\( but Golang regex doesn't support look around

xyz1hang avatar May 13 '22 20:05 xyz1hang

WDYT about merging this? @jmoiron Together, this issue seems to be solved.https://github.com/jmoiron/sqlx/issues/796

haton14 avatar May 23 '22 05:05 haton14

@jmoiron We are suffering a lot from this bug, please merge.

masv87 avatar Jul 26 '22 10:07 masv87

@jmoiron +1 Our destiny depends on this fix. Please review and merge if possible. Thanks.

amirhood avatar Oct 11 '22 02:10 amirhood

I'd also love to see this merged so #796 could be solved.

tylerstillwater avatar Oct 14 '22 17:10 tylerstillwater