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 table or view `tools_orders` cannot be found. Verify the spelling and correctness of the schema and catalog.
If you did not qualify the name with a schema, verify the current_schema() output, or qualify the name with the correct schema and catalog.
To tolerate the error on drop use DROP VIEW IF EXISTS or DROP TABLE IF EXISTS. SQLSTATE: 42P01
%sql
CREATE OR REPLACE FUNCTION get_customer_orders ()
RETURNS TABLE(user_id STRING,
id STRING,
transaction_date STRING,
item_count DOUBLE,
amount DOUBLE,
order_status STRING)
COMMENT 'Returns a list of customer orders for the given customer ID (expect a UUID)'
LANGUAGE SQL
RETURN
SELECT o.* from tools_orders o
inner join tools_customers c on c.id = o.user_id
where email=current_user() ORDER BY transaction_date desc;
SELECT * FROM get_customer_orders();
The text was updated successfully, but these errors were encountered:
%sql
CREATE OR REPLACE FUNCTION get_customer_orders ()
RETURNS TABLE(user_id STRING,
id STRING,
transaction_date STRING,
item_count DOUBLE,
amount DOUBLE,
order_status STRING)
COMMENT 'Returns a list of customer orders for the given customer ID (expect a UUID)'
LANGUAGE SQL
RETURN
SELECT o.* from tools_orders o
inner join tools_customers c on c.id = o.user_id
where email=current_user() ORDER BY transaction_date desc;
SELECT * FROM get_customer_orders();
The text was updated successfully, but these errors were encountered: