xataio / client-ts

Xata.io SDK for TypeScript and JavaScript
https://xata.io/docs/sdk/typescript/overview
Apache License 2.0
123 stars 8 forks source link

Trasaction get operation type error #1308

Closed kostasb closed 10 months ago

kostasb commented 10 months ago

Version: @xata.io/client@0.28.3

Transaction get operation raises a type error:

const result = await xata.transactions.run([
  { get: { table: "prices", id: "rec_cm83un8m922cq6bl2i30", columns: ["id", "original_price"] } },
]);

Object literal may only specify known properties, and 'get' does not exist in type 'NarrowRaw<TransactionOperation<DatabaseSchema, keyof DatabaseSchema>>'.(2353)

image

Reported on Discord.

SferaDev commented 10 months ago

Duplicated of https://github.com/xataio/client-ts/issues/964

We never really implemented it 🥲

kostasb commented 10 months ago

Thank you. Closing this one but it would be good add https://github.com/xataio/client-ts/issues/964 to our priotiries otherwise we should remove it from the docs https://xata.io/docs/sdk/transaction#gets.