DBItest icon indicating copy to clipboard operation
DBItest copied to clipboard

Support vector broadcasting for parameterized query

Open psychelzh opened this issue 2 years ago • 1 comments

When specifying multiple parameters, if one of the parameters is a scalar and the others have the same length, it will be reasonable to expand that scalar to the same length as the other parameters.

psychelzh avatar Nov 05 '23 01:11 psychelzh

Thanks, makes sense. As a workaround, you could now use as.data.frame(...) or as.list(as.data.frame(...)) :

as.data.frame(list(a = 1, b = 2:4))
#>   a b
#> 1 1 2
#> 2 1 3
#> 3 1 4

Created on 2023-11-05 with reprex v2.0.2

krlmlr avatar Nov 05 '23 09:11 krlmlr