Skip to content

Commit 8c9a5ae

Browse files
committed
lint
1 parent 6bbbf11 commit 8c9a5ae

File tree

2 files changed

+90
-90
lines changed

2 files changed

+90
-90
lines changed

packages/cubejs-schema-compiler/src/adapter/BaseQuery.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4214,16 +4214,16 @@ export class BaseQuery {
42144214
'{{ min_expr }} as {{ quoted_min_name }}\n' +
42154215
'FROM {{ from_prepared }}\n' +
42164216
'{% if filter %}WHERE {{ filter }}{% endif %}',
4217-
calc_groups_join: 'SELECT \"{{ original_cube }}\".*, \"{{ groups | map(attribute=\'name\') | join(\'\", \"\') }}\"\n' +
4217+
calc_groups_join: 'SELECT "{{ original_cube }}".*, "{{ groups | map(attribute=\'name\') | join(\'", "\') }}"\n' +
42184218
'FROM {{ original_cube_sql }} {{ original_cube }}\n' +
42194219
'{% for group in groups %}' +
42204220
'CROSS JOIN\n' +
42214221
'(\n' +
42224222
'{% for value in group.values %}' +
4223-
'SELECT \'{{ value }}\' as \"{{ group.name }}\"' +
4223+
'SELECT \'{{ value }}\' as "{{ group.name }}"' +
42244224
'{% if not loop.last %} UNION ALL\n{% endif %}' +
42254225
'{% endfor %}' +
4226-
') \"{{ group.name }}_values\"\n' +
4226+
') "{{ group.name }}_values"\n' +
42274227
'{% endfor %}'
42284228
},
42294229
expressions: {

packages/cubejs-schema-compiler/test/integration/postgres/calc-groups.test.ts

Lines changed: 87 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -503,43 +503,43 @@ views:
503503
},
504504
],
505505
}, [
506-
{
507-
orders__currency: 'EUR',
508-
orders__currency_full_name: 'euros',
509-
orders__date_year: '2024-01-01T00:00:00.000Z',
510-
orders__revenue: '30'
511-
},
512-
{
513-
orders__currency: 'GBP',
514-
orders__currency_full_name: 'unknown',
515-
orders__date_year: '2024-01-01T00:00:00.000Z',
516-
orders__revenue: '30'
517-
},
518-
{
519-
orders__currency: 'USD',
520-
orders__currency_full_name: 'dollars',
521-
orders__date_year: '2024-01-01T00:00:00.000Z',
522-
orders__revenue: '30'
523-
},
524-
{
525-
orders__currency: 'EUR',
526-
orders__currency_full_name: 'euros',
527-
orders__date_year: '2025-01-01T00:00:00.000Z',
528-
orders__revenue: '5'
529-
},
530-
{
531-
orders__currency: 'GBP',
532-
orders__currency_full_name: 'unknown',
533-
orders__date_year: '2025-01-01T00:00:00.000Z',
534-
orders__revenue: '5'
535-
},
536-
{
537-
orders__currency: 'USD',
538-
orders__currency_full_name: 'dollars',
539-
orders__date_year: '2025-01-01T00:00:00.000Z',
540-
orders__revenue: '5'
541-
}
542-
],
506+
{
507+
orders__currency: 'EUR',
508+
orders__currency_full_name: 'euros',
509+
orders__date_year: '2024-01-01T00:00:00.000Z',
510+
orders__revenue: '30'
511+
},
512+
{
513+
orders__currency: 'GBP',
514+
orders__currency_full_name: 'unknown',
515+
orders__date_year: '2024-01-01T00:00:00.000Z',
516+
orders__revenue: '30'
517+
},
518+
{
519+
orders__currency: 'USD',
520+
orders__currency_full_name: 'dollars',
521+
orders__date_year: '2024-01-01T00:00:00.000Z',
522+
orders__revenue: '30'
523+
},
524+
{
525+
orders__currency: 'EUR',
526+
orders__currency_full_name: 'euros',
527+
orders__date_year: '2025-01-01T00:00:00.000Z',
528+
orders__revenue: '5'
529+
},
530+
{
531+
orders__currency: 'GBP',
532+
orders__currency_full_name: 'unknown',
533+
orders__date_year: '2025-01-01T00:00:00.000Z',
534+
orders__revenue: '5'
535+
},
536+
{
537+
orders__currency: 'USD',
538+
orders__currency_full_name: 'dollars',
539+
orders__date_year: '2025-01-01T00:00:00.000Z',
540+
orders__revenue: '5'
541+
}
542+
],
543543
{ joinGraph, cubeEvaluator, compiler }));
544544

545545
it('measure switch cross join', async () => dbRunner.runQueryTest({
@@ -560,43 +560,43 @@ views:
560560
},
561561
],
562562
}, [
563-
{
564-
orders__currency: 'EUR',
565-
orders__date_year: '2024-01-01T00:00:00.000Z',
566-
orders__amount_usd: '1030.0',
567-
orders__amount_in_currency: '1002'
568-
},
569-
{
570-
orders__currency: 'GBP',
571-
orders__date_year: '2024-01-01T00:00:00.000Z',
572-
orders__amount_usd: '1030.0',
573-
orders__amount_in_currency: '828'
574-
},
575-
{
576-
orders__currency: 'USD',
577-
orders__date_year: '2024-01-01T00:00:00.000Z',
578-
orders__amount_usd: '1030.0',
579-
orders__amount_in_currency: '1030.0'
580-
},
581-
{
582-
orders__currency: 'EUR',
583-
orders__date_year: '2025-01-01T00:00:00.000Z',
584-
orders__amount_usd: '40.0',
585-
orders__amount_in_currency: '38'
586-
},
587-
{
588-
orders__currency: 'GBP',
589-
orders__date_year: '2025-01-01T00:00:00.000Z',
590-
orders__amount_usd: '40.0',
591-
orders__amount_in_currency: '33'
592-
},
593-
{
594-
orders__currency: 'USD',
595-
orders__date_year: '2025-01-01T00:00:00.000Z',
596-
orders__amount_usd: '40.0',
597-
orders__amount_in_currency: '40.0'
598-
}
599-
],
563+
{
564+
orders__currency: 'EUR',
565+
orders__date_year: '2024-01-01T00:00:00.000Z',
566+
orders__amount_usd: '1030.0',
567+
orders__amount_in_currency: '1002'
568+
},
569+
{
570+
orders__currency: 'GBP',
571+
orders__date_year: '2024-01-01T00:00:00.000Z',
572+
orders__amount_usd: '1030.0',
573+
orders__amount_in_currency: '828'
574+
},
575+
{
576+
orders__currency: 'USD',
577+
orders__date_year: '2024-01-01T00:00:00.000Z',
578+
orders__amount_usd: '1030.0',
579+
orders__amount_in_currency: '1030.0'
580+
},
581+
{
582+
orders__currency: 'EUR',
583+
orders__date_year: '2025-01-01T00:00:00.000Z',
584+
orders__amount_usd: '40.0',
585+
orders__amount_in_currency: '38'
586+
},
587+
{
588+
orders__currency: 'GBP',
589+
orders__date_year: '2025-01-01T00:00:00.000Z',
590+
orders__amount_usd: '40.0',
591+
orders__amount_in_currency: '33'
592+
},
593+
{
594+
orders__currency: 'USD',
595+
orders__date_year: '2025-01-01T00:00:00.000Z',
596+
orders__amount_usd: '40.0',
597+
orders__amount_in_currency: '40.0'
598+
}
599+
],
600600
{ joinGraph, cubeEvaluator, compiler }));
601601

602602
it('measure switch with filter', async () => dbRunner.runQueryTest({
@@ -620,19 +620,19 @@ views:
620620
},
621621
],
622622
}, [
623-
{
624-
orders__currency: 'EUR',
625-
orders__date_year: '2024-01-01T00:00:00.000Z',
626-
orders__amount_usd: '1030.0',
627-
orders__amount_in_currency: '1002'
628-
},
629-
{
630-
orders__currency: 'EUR',
631-
orders__date_year: '2025-01-01T00:00:00.000Z',
632-
orders__amount_usd: '40.0',
633-
orders__amount_in_currency: '38'
634-
},
635-
],
623+
{
624+
orders__currency: 'EUR',
625+
orders__date_year: '2024-01-01T00:00:00.000Z',
626+
orders__amount_usd: '1030.0',
627+
orders__amount_in_currency: '1002'
628+
},
629+
{
630+
orders__currency: 'EUR',
631+
orders__date_year: '2025-01-01T00:00:00.000Z',
632+
orders__amount_usd: '40.0',
633+
orders__amount_in_currency: '38'
634+
},
635+
],
636636
{ joinGraph, cubeEvaluator, compiler }));
637637
} else {
638638
// This test is working only in tesseract

0 commit comments

Comments
 (0)