Skip to content

Eftdb.Design: query has no destination for result data #39

@Inzta

Description

@Inzta

Description

I am trying to run my migrations as an SQL script inside my TimescaleDB docker container.
I am getting the following error from the DB:
I have tried to manually edit the SQL script and use PERFORM instead of the SELECT in front of the create_hypertable which fixed the problem and made the script run as expected.


This fix seems to work and the script is applied. Could be nice to fix this with the designer, so the dotnet tool outputs valid SQL scripts.

2026-03-30 10:46:36.122 UTC [81] ERROR:  query has no destination for result data

2026-03-30 10:46:36.122 UTC [81] HINT:  If you want to discard the results of a SELECT, use PERFORM instead.

2026-03-30 10:46:36.122 UTC [81] CONTEXT:  PL/pgSQL function inline_code_block line 5 at SQL statement

2026-03-30 10:46:36.122 UTC [81] STATEMENT:  DO $EF$

	BEGIN

	    IF NOT EXISTS(SELECT 1 FROM "__EFMigrationsHistory" WHERE "MigrationId" = '20260327140529_Initial') THEN

	

	                    SELECT create_hypertable('public."Events"', 'CapturedAt', chunk_time_interval => INTERVAL '1 day');

	                    DO $$

	    DECLARE

	        license TEXT;

Steps to reproduce

  1. Create Migration for DbContext with HyperTable
  2. run dotnet ef migrations script --idempotent
  3. Try applying the SQL against the DB
  4. Confirm that the SQL script fails

Expected behavior

I would expect it to generate appropriate SQL scripts

.NET version

10.0

TimescaleDB version

2.26.0-pg17

Eftdb version

10.0.2

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions