Skip to content

Instantly share code, notes, and snippets.

@nurmdrafi
Created June 11, 2024 10:56
Show Gist options
  • Save nurmdrafi/42ecf040287d8d853e613f5af684fbbe to your computer and use it in GitHub Desktop.
Save nurmdrafi/42ecf040287d8d853e613f5af684fbbe to your computer and use it in GitHub Desktop.
Hello Raju
@dasraju
Copy link

dasraju commented Jun 30, 2024

select sum(final.total_gross_stick_quantity)as total_gross_stick_quantity, sum(final.lpc)/count(*) as lpc, sum(final.total_order) as total_order
from (select sum(sii.quantity) as total_gross_stick_quantity, case
when count(distinct customer_id) = 0 then 0
else count(sku_id) / count(distinct customer_id)
end as lpc, count( distinct s.brand_id) as total_order
from (select id, invoice_date, route_id, customer_id from sales_invoices
where invoice_date >= '$start_filter_date'
and invoice_date <= '$end_filter_date'
and (no_sales_reason_id = 0 or no_sales_reason_id IS NUll)) si
join (select id from routes where $filter_field = $filter_value) r on r.id = si.route_id
join (select invoice_id, quantity, sku_id from sales_invoice_item) sii on sii.invoice_id = si.id
join skus s on s.id = sii.sku_id
group by si.id) final

@dasraju
Copy link

dasraju commented Jul 14, 2024

2024/07/14 02:58:29 [error] 2319#2319: *62066 FastCGI sent in stderr: "PHP message: PHP Warning: Unknown: Failed to open stream: Permission denied in Unknown on line 0Unable to open primary script: /srv/www/sites/retail-jti-backend/public/index.php (Permission denied)" while reading response header from upstream, client: 138.91.34.200, server: drishtievista.jti.com, request: "POST /api/v1/login HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "drishtievista.jti.com"

@dasraju
Copy link

dasraju commented Jul 14, 2024

@dasraju
Copy link

dasraju commented Jul 14, 2024

zypper search --installed-only --repo snappy

@dasraju
Copy link

dasraju commented Jul 14, 2024

[14-Jul-2024 12:20:05] NOTICE: [pool www] child 28412 exited with code 0 after 1.927654 seconds from start
[14-Jul-2024 12:20:05] NOTICE: [pool www] child 28606 started

@dasraju
Copy link

dasraju commented Jul 14, 2024

2024/07/14 12:22:18 [error] 27474#27474: *126263 FastCGI sent in stderr: "PHP message: PHP Warning: Unknown: Failed to open stream: Permission denied in Unknown on line 0Unable to open primary script: /srv/www/sites/retail-jti-backend/public/index.php (Permission denied)" while reading response header from upstream, client: 37.111.232.24, server: drishtievista.jti.com, request: "POST /api/v1/store-order HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "drishtievista.jti.com"

@dasraju
Copy link

dasraju commented Jul 14, 2024

2024/07/14 16:07:37 [crit] 2314#2314: *19058 open() "/var/lib/nginx/proxy//9/32/0000000329" failed (13: Permission denied) while reading upstream, client: 37.111.243.96, server: drishtievista.jti.com, request: "GET /_next/static/chunks/pages/_app-871aea6e9132285b.js HTTP/1.1", upstream: "http://[::1]:3090/_next/static/chunks/pages/_app-871aea6e9132285b.js", host: "drishtievista.jti.com", referrer: "https://drishtievista.jti.com/"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment