line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Fey::SQL::Union; |
2
|
|
|
|
|
|
|
|
3
|
27
|
|
|
27
|
|
122
|
use strict; |
|
27
|
|
|
|
|
43
|
|
|
27
|
|
|
|
|
1082
|
|
4
|
27
|
|
|
27
|
|
111
|
use warnings; |
|
27
|
|
|
|
|
37
|
|
|
27
|
|
|
|
|
746
|
|
5
|
27
|
|
|
27
|
|
125
|
use namespace::autoclean; |
|
27
|
|
|
|
|
41
|
|
|
27
|
|
|
|
|
200
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
our $VERSION = '0.42'; |
8
|
|
|
|
|
|
|
|
9
|
27
|
|
|
27
|
|
2265
|
use Moose 0.90; |
|
27
|
|
|
|
|
632
|
|
|
27
|
|
|
|
|
176
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
with 'Fey::Role::SetOperation' => { keyword => 'UNION' }; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
with 'Fey::Role::SQL::Cloneable'; |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
1; |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
# ABSTRACT: Represents a UNION operation |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
__END__ |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
=pod |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
=head1 NAME |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
Fey::SQL::Union - Represents a UNION operation |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
=head1 VERSION |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
version 0.42 |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=head1 SYNOPSIS |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
my $union = Fey::SQL->new_union; |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
$union->union( Fey::SQL->new_select->select(...), |
36
|
|
|
|
|
|
|
Fey::SQL->new_select->select(...), |
37
|
|
|
|
|
|
|
Fey::SQL->new_select->select(...), |
38
|
|
|
|
|
|
|
... |
39
|
|
|
|
|
|
|
); |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
$union->order_by( $part_name, 'DESC' ); |
42
|
|
|
|
|
|
|
$union->limit(10); |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
print $union->sql($dbh); |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
=head1 DESCRIPTION |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
This class represents a UNION set operator. |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=head1 METHODS |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
See L<Fey::Role::SetOperation> for all methods. |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=head1 ROLES |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
=over 4 |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=item * L<Fey::Role::SetOperation> |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
=item * L<Fey::Role::SQL::Cloneable> |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
=back |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
=head1 BUGS |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
See L<Fey> for details on how to report bugs. |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
=head1 AUTHOR |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
Dave Rolsky <autarch@urth.org> |
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
This software is Copyright (c) 2011 - 2015 by Dave Rolsky. |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
This is free software, licensed under: |
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
The Artistic License 2.0 (GPL Compatible) |
79
|
|
|
|
|
|
|
|
80
|
|
|
|
|
|
|
=cut |