我在google bigquery上有sql查询
SELECT distinct
h.transaction.transactionId,
Date,
totals.pageviews,
h.item.itemQuantity,
h.transaction.transactionRevenue,
totals.bounces,
fullvisitorid,
totals.timeOnSite,
device.browser,
device.deviceCategory,
trafficSource.source,
channelGrouping,
h.page.pagePath,
h.eventInfo.eventCategory,
device.operatingSystem
FROM `atomic-life-148403.148778266.ga_sessions_*`,
UNNEST(hits) AS h
WHERE
_TABLE_SUFFIX BETWEEN REPLACE(CAST(DATE_ADD(CURRENT_DATE(), INTERVAL -1 YEAR) AS STRING), '-','')
AND CONCAT('intraday_', REPLACE(CAST(DATE_ADD(CURRENT_DATE(), INTERVAL 0 DAY) AS STRING), '-',''))
order by date
错误是:
错误:在第32行第75栏遇到“”年“”。期待:“)”......
但是,我看不出“年”有什么问题。 任何人都可以帮忙吗?