Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Aliases are not returned from serial #179

Open
FreePhoenix888 opened this issue Jun 5, 2023 · 0 comments · May be fixed by #180
Open

Aliases are not returned from serial #179

FreePhoenix888 opened this issue Jun 5, 2023 · 0 comments · May be fixed by #180
Assignees
Labels
enhancement New feature or request

Comments

@FreePhoenix888
Copy link
Member

When I do execute these serial operations:

  await deep.serial({
    operations: [
      {
        table: 'strings',
        type: 'update',
        exp: {
          link_id: 5663
        },
        value: {
          value: "HiWorld"
        }
      },
      {
        table: 'strings',
        type: 'update',
        exp: {
          link_id: 5671
        },
        value: {
          value: "HiWorld"
        }
      },
    ],
  });

It gets full info including aliases

mutation Name($_set0: strings_set_input, $where0: strings_bool_exp!, $_set1: strings_set_input, $where1: strings_bool_exp!) {
  m0: update_strings(_set: $_set0, where: $where0) {
    returning {
      id
      __typename
    }
    __typename
  }
  m1: update_strings(_set: $_set1, where: $where1) {
    returning {
      id
      __typename
    }
    __typename
  }
}

but serial ignores it:

return { ...result, data: (result)?.data && Object.values((result)?.data).flatMap(m => m.returning)};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: In Progress
Development

Successfully merging a pull request may close this issue.

1 participant