You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following example produces a non-compliant SQL query on dbplyr 2.3.0, but works correctly with 2.2.
######################################################################## this is site specific code needed to reproduce the error on a live DBcon<- dbi_connect()
######################################################################
tbl(con, sql("test_table")) %>%
select(OBJ_TYPE, CREATED_AT) %>%
group_by(OBJ_TYPE) %>%
filter(1L== row_number(desc(CREATED_AT))) %>%
show_query()
...<SQL>SELECT"OBJ_TYPE", "CREATED_AT"
FROM (
SELECT"OBJ_TYPE",
"CREATED_AT",
CASE
WHEN (NOT(("CREATED_AT"DESCISNULL))) THEN ROW_NUMBER() OVER (PARTITIONBY"OBJ_TYPE", (CASE WHEN (("CREATED_AT"DESCISNULL)) THEN1ELSE0END) ORDERBY"CREATED_AT"DESC)
ENDAS"q02"
FROM (test_table) "q01"
) "q02"
WHERE (1="q02")
>
The text was updated successfully, but these errors were encountered:
donour
changed the title
Groupby+filter produces invalid SQL on tidyverse 2.3.0
Groupby+filter produces invalid SQL on dbplyr 2.3.0
Jan 31, 2023
The following example produces a non-compliant SQL query on dbplyr 2.3.0, but works correctly with 2.2.
The text was updated successfully, but these errors were encountered: