Revision 188696a4
Von Sven Schöling vor etwa 10 Jahren hinzugefügt
SL/DBUtils.pm | ||
---|---|---|
8 | 8 |
selectfirst_hashref_query selectfirst_array_query |
9 | 9 |
selectall_hashref_query selectall_array_query |
10 | 10 |
selectall_as_map |
11 |
selectall_ids |
|
11 | 12 |
prepare_execute_query prepare_query |
12 | 13 |
create_sort_spec does_table_exist |
13 | 14 |
add_token); |
... | ... | |
236 | 237 |
return %hash; |
237 | 238 |
} |
238 | 239 |
|
240 |
sub selectall_ids { |
|
241 |
$main::lxdebug->enter_sub(2); |
|
242 |
|
|
243 |
my ($form, $dbh, $query, $key_col) = splice(@_, 0, 4); |
|
244 |
|
|
245 |
my $sth = prepare_execute_query($form, $dbh, $query, @_); |
|
246 |
|
|
247 |
my @ids; |
|
248 |
while (my $ref = $sth->fetchrow_arrayref()) { |
|
249 |
push @ids, $ref->[$key_col]; |
|
250 |
} |
|
251 |
|
|
252 |
$sth->finish; |
|
253 |
|
|
254 |
$main::lxdebug->leave_sub(2); |
|
255 |
|
|
256 |
return @ids; |
|
257 |
} |
|
258 |
|
|
239 | 259 |
sub create_sort_spec { |
240 | 260 |
$main::lxdebug->enter_sub(2); |
241 | 261 |
|
Auch abrufbar als: Unified diff
DBUtils: selectall_ids