Hydrahon icon indicating copy to clipboard operation
Hydrahon copied to clipboard

Using SQL UNION / UNION ALL operator

Open samiharju opened this issue 6 years ago • 1 comments

Is there a possibility to create queries with the UNION or UNION ALL operator?

Something like this would be useful:

$h->table('students')
  ->select('column_name')
  ->union()
  ->table('teachers')
  ->select('column_name')
  ->get();

Resulting in:

SELECT column_name FROM students
UNION
SELECT column_name FROM teachers;

samiharju avatar Feb 07 '19 08:02 samiharju

Good night,,

Why not merge fork https://github.com/lucasnodari/Hydrahon with unionall in oficial Hydrahon?

eurairapelli avatar Jul 21 '20 02:07 eurairapelli