Join with between - Excel into SQL query?

I have two datasets, one an hourly weather record:

Date Time Cloud Cover
27-Apr-23 13:00 100%
27-Apr-23 14:00 100%

And one a set of events with dates and times:

Event ID Date Time
AA 27-Apr-23 13:15
BB 27-Apr-23 13:26

I would like to join the two, such that I have the format:

Date Time Cloud Cover Events
27-Apr-23 13:00 100% 2
27-Apr-23 14:00 100% 0

This weather data is about 52,000 rows, so a cross join is out of the question! I considered the potential for using SQL, but is there a way of feeding .xlsx into an SQL query to process the join? Or is there perhaps another way of doing it? I have had a look at “H2” databases, but that seems to hold all information about my tables but the actual data! Thanks!

Hello @JWebb
I would do it simple…

  1. ‘Extract Date&Time Fields’ node up to hour granularity.
  2. Group by node with count events.
  3. Join to summary table.

I hope this make some sense for you.

BR

2 Likes

Wow, I was really overcomplicating that! Thanks, that worked well :smiley:

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.