ClickHouse / ClickHouse

ClickHouse® is a real-time analytics DBMS
https://clickhouse.com
Apache License 2.0
37.63k stars 6.91k forks source link

Received empty body request from URL Engine #71902

Open dev4mobile opened 13 hours ago

dev4mobile commented 13 hours ago
  1. I created a table Base on URL Engine, and I want to post a http request from URL Engine
  2. I created a material view table target to the URL Engine table
  3. when I insert an empty data to source table, the URL Engine table post a empty request, but I haved filter empty data to material view
dev4mobile commented 12 hours ago
DROP TABLE IF EXISTS default.output_http_safe_access;
CREATE TABLE IF NOT EXISTS default.output_http_safe_access(`msgType` String, `version` String, `deviceType` String, `sourceid` LowCardinality(String), `sid` String, `referrer` String, `updateTime` String) ENGINE = URL(
    'http://127.0.0.1:10098/api/data',
    'JSONEachRow',
    headers('Content-Type'='application/json;charset=UTF-8')
);

DROP TABLE IF EXISTS default.output_http_safe_access_mv;

CREATE MATERIALIZED VIEW IF NOT EXISTS default.output_http_safe_access_mv TO default.output_http_safe_access AS SELECT 'DeviceInfoPushReq' AS `msgType`, '1.0.0' AS `version`, 'H5' AS `deviceType`, host AS `sourceid`, sid, refer AS `referrer`, toString(toUnixTimestamp(ts)) as `updateTime` FROM default.access_local WHERE id is not null AND org != 'no_res' AND empty(req_risk) AND id != '';
dev4mobile commented 12 hours ago

image

dev4mobile commented 11 hours ago

why when I insert data failed from source table, the material view table can be updated