xxxxxxxxxx
SELECT date(uploaded_date) FROM `tbl_attach_po_docs` where type_id=1 and attach_po_doc_id = (SELECT max(attach_po_doc_id) where type_id=1) limit 1;
//or
SELECT if(max(attach_po_doc_id) && type_id =1,date(uploaded_date),'') FROM `tbl_attach_po_docs` where 1
xxxxxxxxxx
SELECT t.*, (SELECT customer_name FROM customers WHERE id = t.customer_id limit 1) AS customer_name FROM transactions t;
xxxxxxxxxx
const arrays = [
["$6"],
["$12"],
["$25"],
["$25"],
["$18"],
["$22"],
["$10"]
];
const merge3 = arrays.flat(1); //The depth level specifying how deep a nested array structure should be flattened. Defaults to 1.
console.log(merge3);
Run code snippet