Categories
Mastering Development

Plotly.js multiple subplots not working as expected

I am using array (example element below) to populate traces for plotly.js multiple subplots per their multiple-subplots example [{ “key”: “Ontario|Toronto”, “values”: [{ “key”: “2020-01-25”, “value”: 1 }, { “key”: “2020-01-27”, “value”: 1 }, { “key”: “2020-05-12”, “value”: 218 }, { “key”: “2020-05-13”, “value”: 169 }] }, { etc }] The array has 94 elements […]

Categories
Mastering Development

ReactJS, How to get the oldest and newest date from array using moment.js

I have this array: DatosFechas = [“2020-04-29”, “2020-04-19”, “2020-04-07”, “2020-04-30”, “2020-04-30”, “2018-01-22”] And I would like to get the oldest or the newest date from a given range. Ths function that trying to get work: function ObtenerMaxMinRangoFechas(DatosFechas) { let moments = DatosFechas.map(x => moment(x)), maxDate = moment.max(moments) return maxDate } Thx My date array is […]

Categories
Database Development

Find order that has deliveries in multiple weeks

I thought I had a simple run of the mill problem, but I can’t manage to figure out how to slice it. Assume I have a table of Deliveries that has the OrderNumber, the DeliveryNumber and the DeliveryDate. The question I want to ask is “Which OrderNumbers have DeliverDates that all aren’t in the same […]