Google bigquery bigquery中的函数TIMESTAMP_SUB没有匹配签名

Google bigquery bigquery中的函数TIMESTAMP_SUB没有匹配签名,google-bigquery,Google Bigquery,我试图在Google BigQuery中运行此查询,但是 No matching signature for function TIMESTAMP_SUB for argument types: DATETIME, INT64, DATE_TIME_PART. Supported signature: TIMESTAMP_SUB(TIMESTAMP, INTERVAL INT64 DATE_TIME_PART) at [8:5] 以下是查询: #standardSQL CREATE TEMPO

我试图在Google BigQuery中运行此查询,但是

No matching signature for function TIMESTAMP_SUB for argument types: DATETIME, INT64, DATE_TIME_PART. Supported signature: TIMESTAMP_SUB(TIMESTAMP, INTERVAL INT64 DATE_TIME_PART) at [8:5]
以下是查询:

#standardSQL
CREATE TEMPORARY FUNCTION URL_DECODE(enc STRING)
RETURNS STRING
LANGUAGE js AS """
  try { 
    return decodeURI(enc);;
  } catch (e) { return null }
  return null;
""";

select 
replace(JSON_EXTRACT(URL_DECODE(l.ed), '$.phone'),"\"","") as phone
from pixel_logs.full_logs l
where ev = 'user_authentication'
and ed not like '%filipe.ferminiano%'
AND TIMESTAMP_SUB(CURRENT_DATETIME(), interval 60 minute) > timestamp
group by
phone
;
CURRENT\u DATETIME()
返回一个
DATETIME
值,而不是
时间戳
。也许你想使用
当前时间戳()

CURRENT\u DATETIME()
返回一个
DATETIME
值,而不是
时间戳
。也许你想使用
当前时间戳()

#standardSQL
CREATE TEMPORARY FUNCTION URL_DECODE(enc STRING)
RETURNS STRING
LANGUAGE js AS """
  try { 
    return decodeURI(enc);;
  } catch (e) { return null }
  return null;
""";

select 
replace(JSON_EXTRACT(URL_DECODE(l.ed), '$.phone'),"\"","") as phone
from pixel_logs.full_logs l
where ev = 'user_authentication'
and ed not like '%filipe.ferminiano%'
AND TIMESTAMP_SUB(CURRENT_TIMESTAMP(), interval 60 minute) > timestamp
group by
phone
;