Skip to content

Commit 8ac6d61

Browse files
authored
fix(script): fetch log script need use the timestamp (#18352)
fix: fetch log script need use the timestamp
1 parent 59735a7 commit 8ac6d61

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/selfhost/fetch_log.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ main() {
299299
log INFO "Fetch Databend query logs..."
300300
execute_query "REMOVE @a5c7667401c0c728c2ef9703bdaea66d9ae2d906;"
301301

302-
execute_query "COPY INTO @a5c7667401c0c728c2ef9703bdaea66d9ae2d906 FROM (SELECT * FROM system_history.query_history WHERE event_date = '$FORMATTED_DATE');"
302+
execute_query "COPY INTO @a5c7667401c0c728c2ef9703bdaea66d9ae2d906 FROM (SELECT * FROM system_history.query_history WHERE to_date(event_time) = '$FORMATTED_DATE');"
303303

304304
file_list=$(execute_query "list @a5c7667401c0c728c2ef9703bdaea66d9ae2d906;" | awk '{print $1}')
305305
[[ -z "$file_list" ]] && {

0 commit comments

Comments
 (0)