How to use frappe.db in jinja template in report print format html file

Thanks for the response @makarand_b , but I don’t want to use it in jinja. It’s general_ledger.html file which is look like jinja but not jinja.