Xata

X

Xata

This is Xata's community Discord server, where we discuss all things Xata: projects, features, dreams!

Join

help

general

xata push main

I'm trying to push my changes to main, (23 migrations) and am getting an error. Any idea what this error could mean? Error: Internal Error (Request ID: faa5be17-dc42-9822-986d-ca24f6b60427)...

file attachments names have many weird requirements

For some filenames, I get: offset 32: unprintable symbols are not allowed when trying to upload or Unicode characters not allowed. This is a bit annoying to take care of. S3 does not have these limitations so I'm wondering why the Xata SDK has them. Could you please either extend the allowed charset to the same that S3 uses OR list the exact requirements for filenames in the docs?...

No module named 'xata'

First time making a call to Xata from VSCode and I have a problem with importing xata.client. I have used Colab before and had no problems. No errors are shown when writing, pip insnall xata made. But when I run the code it gives an error.
No description

summarize columns linked table

```"records": [ { "id": "1", "name": "MW305R Router Inalámbrico N de 300Mbps", "product_references_in_variation_location_details": {...

Filter with link table json field

I've table call students and it has a link field called class to table called classes. Normally I can filter without any problems using like this, xata.db.classes.filter({ "grade->v1" : 13 " }).getAll() How can I filter using student table like that. I tried some of these. But none of them worked....

Flyway SET ROLE

Hi, has anyone used Flyway with Xata DB? Under the hood, when validate method is called, SET ROLE is used, and as I can see it is an unsupported statement: https://xata.io/docs/postgres#supported-statements

Not able to connect directly access DB using pgAdmin

Today when I tried connecting to the DB directly from pgAdmin, I was facing a peculiar issue - "cannot run SET and SHOW operations inline with other statements." (attached SS for reference). 1. I used the API key as my password and the host is correct because my DB is located in Ireland. 2. I have enabled direct access feature in my account settings. 3. I was able to access DB a couple of days ago, but I am not able to access it today....
No description

how to make am update request without returning Xata metadata?

The code below calls: const proj = await xata.db.project.update(id, data); I would like to remove the metadata that comes from it in order to avoid parsing errors from zod at:...

`xata pull <branch>` results in a high number of migration files - Safe to ignore?

This happens after running migrations or pushes with Drizzle. I have been testing different data models and now have over 200 migration files. Is it safe to ignore the folder since we are planning on running all migrations with Drizzle anyways?

Return types of search

I'm calling xata.search.all on my backend, and I'm trying to figure out what types that I should use to represent the record result. I'm currently searching two tables. Doing RouterOutput['search']['records'][0] gives me one of the two possible types I think? RouterOutput is the return type of the function using TRPC....

Re-executing Drizzle Kit push fails after successful push

I'm getting the following error: PL/pgSQL function "xata.pg_catalog".regnamespace(text) line 14 at RAISE ```ts...

Transactions API

i'm using typescript SDK, in the transactions API, it appears to be not accepting any other types except primitive types, to create a new record with json column, i need to pass json object in a stringified version apparently for it to work

how i can link two table like this

right now i got this sql query ```select MAX(products.id) as id, COUNT(v.id) as variation_id,products.name as Nombre,c1.name as Categoria, COUNT(products.category_id) as category_id,b.name as Marca,tax_rates.name as Impuesto,...
No description

Increase check limit on text

It seems like Xata is limiting "text" columns to 204800 when it's created through the ui. I'm judging this based on the schema that's generated through the CLI Is there a specific reason for this, will search break if I increase the column size limit?...

Can we use ULIDs without a dedicated cluster?

We are looking for some solution between a Postgres serial and a long UUID. So ULIDs are a natural choice. I would use something like https://github.com/geckoboard/pgulid or https://github.com/pksunkara/pgx_ulid. But without a dedicated cluster we cannot create types/functions. So is there another way to use ULID-like IDs? I've seen that select ('rec_'::text || (xata_private.xid())::text) produces a similar result. Can we use this for the foreseeable future for our own ID fields?...

Am I forced to use Xata_id?

I'd want to use a numeric primary key if possible, secondly, I'd probably want to remove xata_id all together

Stripe / Payload CMS integration...

I'm trying to configure a next.js project with both Stripe and Payload. Stripe needs access to table header columns id. If i do Postgres, it forces a header column name of xata_id. Payload requires a Postgres enabled DB. I've gotten a schema to work perfectly via Neon, but I'm trying to use Xata as my db. I've gotten past all the "malformed schema file" issues and now it's just giving me one of two errors. Either the migration errors out or theres a runtime error when requesting data from Payload. I'm initiating brand new DB's as such: ``` npx xata init --schema=./schema.template.json --force...

inner join with rest api?

any change of do a inner join with rest api?

Issues with summarize table api rest

hi summarize is not working it shows: { "message": "" }...