1DBIx::Class::Helper::ReUssuelrtSCeotn:tD:rBRiIebxmu:ot:veCedlCaoPslesur:ml:nHsDe(ol3cp)uemre:n:tRaetsiuolntSet::RemoveColumns(3)
2
3
4
6 DBIx::Class::Helper::ResultSet::RemoveColumns - Remove columns from a
7 ResultSet
8
10 package MySchema::ResultSet::Bar;
11
12 use strict;
13 use warnings;
14
15 use parent 'DBIx::Class::ResultSet';
16
17 __PACKAGE__->load_components('Helper::ResultSet::RemoveColumns');
18
19 # in code using resultset:
20 my $rs = $schema->resultset('Bar')->search(undef, {
21 remove_columns => ['giant_text_col', 'password'],
22 });
23
25 This component allows convenient removal of columns from a select.
26 Normally to do this you would do this by listing all of the columns
27 except the ones you want to remove. This does that part for you. See
28 "NOTE" in DBIx::Class::Helper::ResultSet for a nice way to apply it to
29 your entire schema.
30
31 It doesn't get a lot more complicated than the synopsis. If you are
32 interested in having more control, check out
33 DBIx::Class::Helper::ResultSet::AutoRemoveColumns.
34
35 • Load the component
36
37 • Put an "ArrayRef" of columns to remove in the "remove_columns"
38 search attribute.
39
40 • Profit.
41
43 Arthur Axel "fREW" Schmidt <frioux+cpan@gmail.com>
44
46 This software is copyright (c) 2020 by Arthur Axel "fREW" Schmidt.
47
48 This is free software; you can redistribute it and/or modify it under
49 the same terms as the Perl 5 programming language system itself.
50
51
52
53perl v5.38.0 DBIx2:0:2C3l-a0s7s-:2:0Helper::ResultSet::RemoveColumns(3)