Skip to main content
Stack Overflow
  1. About
  2. For Teams
Filter by
Sorted by
Tagged with
-4 votes
1 answer
64 views

📝 Body I have a Mongo collection CollectionA where each top-level object contains a nested array of meetings now each meetings have start and end times, for example: CollectionA = [ { &...
1 vote
1 answer
75 views

I'm trying to create a virtual column called period created by 2 other columns starting_date (time) and ending_date (time). The aim is to avoid overlapping of periods for the same user. Here is my ...
0 votes
1 answer
68 views

Similar to this SO question, how to convert a tstzrange value to daterange (ignoring the time part) ? alter table x alter column y type daterange using y::daterange; Ouput: ERROR: cannot cast type ...
1 vote
3 answers
172 views

This SQL: select daterange(current_date, current_date); Results in: daterange ----------- empty (1 row) But the daterange() function does not seem to be documented. I've looked here and there. ...
3 votes
3 answers
153 views

I have a table which has 3 columns: task_name -- data type is varchar(50) start_date -- data type is date end_date -- data type is date I want to list the dates which fall within the range (between ...
-1 votes
1 answer
98 views

I have two tables one with request dates and SLA and the other with the list of dates of US holidays. I want to write query that checks if any of the holidays fall between the request dates and the ...
0 votes
1 answer
72 views

I need to calculate OEE (Overall Equipment Effectiveness) for a set of production data given a start and end timestamp. The value I'm stuck on is Availability %, which is (time running/time requested) ...
1 vote
2 answers
93 views

I have 3 tables in SQL: Agency, booking and checkin (and rooms) I need to compute a % of checkin / booking, by week number (of begin), by agency Here somes tables for example Agency : id name 1 first ...
2 votes
2 answers
105 views

I have a collection of user data as follows: user start end John Doe 2025年03月21日 11:30:35 2025年03月21日 13:05:26 ... ... ... Jane Doe 2023年12月31日 01:02:03 2024年01月02日 03:04:05 Each user has a start and end ...
1 vote
5 answers
191 views

I have the columns party_id and data_date. I want to sort the data_dates in ascending order for each party_id. I will always take the first data_date. After that, the data_date I select must be at ...
1 vote
2 answers
85 views

I have a set of database tables in Microsoft SQL Server "in the example flattened to keep this example easy" that is a bunch of time clock records for employees that looks like this. Call ...
-1 votes
1 answer
72 views

I'm working on a Delinea report and need to generate an SQL query to find the day with the highest number of active users simultaneously over the last 4 months. My database has columns like UserId, ...
2 votes
2 answers
78 views

In a table, I have plan details of customers with their customer_id and enroll_date. Now, I want to identify duplicate and valid enrollments from the overall data. Duplicate: If a customer enrolls a ...
4 votes
6 answers
135 views

I have a pandas dataframe that contains two date columns, a start date and an end date that defines a range. I'd like to be able to collect a total count for all dates across all rows in the dataframe,...
-2 votes
2 answers
81 views

I am trying to count number of overlapping events between dates in SQL. Let’s assume some dates for room reservations in a hotel. Like this: start end 14.01.2024 17.01.2024 15.01.2024 17.01.2024 17.01....

15 30 50 per page
1
2 3 4 5
...
112

AltStyle によって変換されたページ (->オリジナル) /