feast materialize runs into BigQuery syntax error
See original GitHub issueExpected Behavior
No syntax error
Current Behavior
running feast materialize
using BigQuerySource creates a query that has syntax errors
Steps to reproduce
- Run
feast materialize
- Check the output and inspect the query as part of the job output
google.api_core.exceptions.BadRequest: 400 Syntax error: Expected ")" but got "," at [4:58]
Query with invalid syntax (missing parenthesis)
SELECT InvoiceNo, Quantity, InvoiceDate,
FROM (
SELECT InvoiceNo, Quantity, InvoiceDate, ,
ROW_NUMBER() OVER(PARTITION BY InvoiceNo ORDER BY InvoiceDate DESC, DESC) AS _feast_row
FROM `feast-feature-store:data.ecommerce`
WHERE InvoiceDate BETWEEN TIMESTAMP('2011-03-24 00:00:00+00:00') AND TIMESTAMP('2011-08-02 00:00:00+
7 00:00')
)
WHERE _feast_row = 1
The feature definition does not contain any extraordinary
from datetime import timedelta
from feast import BigQuerySource, Entity, Feature, FeatureView, ValueType
transactions = Entity(
name="transactions",
join_key="InvoiceNo",
value_type=ValueType.INT64,
)
transactions_source= BigQuerySource(
table_ref="feast-feature-store:data.ecommerce",
event_timestamp_column="InvoiceDate",
)
transactions_view = FeatureView(
name="transactions",
entities=["transactions"],
ttl=timedelta(weeks=52),
features=[
Feature(name="Quantity", dtype=ValueType.INT64)
],
input=transactions_source,
tags={"team": "driver_performance"},
)
Specifications
- Version: 0.10
- Platform: GCP
- Subsystem:
Possible Solution
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Quickstart - Feast
In this tutorial, we focus on a local deployment. For a more in-depth guide on how to use Feast with Snowflake / GCP...
Read more >BigQuery Syntax Error with "(" - sql - Stack Overflow
I'm creating a query to uniformly distribute Facebook ad spend amount per ad id's. Syntax stopped me. SELECT t.lead_city, t.lead_time, t.
Read more >Changelog - GitHub
... Fix materialization when running on Spark cluster. ... Fix workflow syntax error ([#2869](https://github.com/feast-dev/feast/issues/2869)) ...
Read more >feast - PyPI
Python SDK for Feast. ... feature engineering rather than debugging error-prone dataset joining logic. ... Want to run the full Feast on Snowflake/GCP/AWS?...
Read more >Machine Learning Feature Store Quickstart Tutorial | Redis
Install Redis and run Redis-Server in the background; Install Feast with Redis; Create a feature repository and define Redis as the online store ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Whenever you have duplicated rows in your source (meaning a row with the same
event_timestamp
andInvoiceNo
) then we deduplicate by taking thelatest
row based oncreated_timestamp
. Thecreated_timestamp
is when the row was written to the source.confirmed working after upgrading to 0.10.1 lovely ❤️