2

No, 'query optimizer fixes' only affects optimizer bug fixes that may result in unexpected query plan changes. It does not enable new features. The only way to enable scalar function inlining is to set the database compatibility level to 150: Enabling Scalar UDF Inlining You can make workloads automatically eligible for Scalar UDF Inlining by ...


1

Use a subquery: SELECT array_agg(x ORDER BY x) FROM (SELECT my_expensive_function(data) AS x FROM jsonb_array_elements(json_set) AS data ) AS q;


1

To have a realistic demo case, you need to populate the tables, not just create them. Your title says "after deleting a row", but your trigger is clearly a "before" trigger. If you (attempt to) delete a row from people which has no corresponding entry in accounts, then athleteSum naturally becomes NULL. What else would it do? If you wish to avoid this, ...


1

A very simple approach is this: Make sure that you have common variables and parameters that will be passed to a certain function. And simply call the function that you have made from other database. ex. select [databasename].empstatus(empid) as status; PHP Script: $empid=trim($_REQUEST['empid']); $conn=mysqli_connect($db_host, $db_user, $db_pass, $...


Only top voted, non community-wiki answers of a minimum length are eligible