Bug report
Describe the bug
Inserting silently fails with no reason for large inputs.
To Reproduce
Set up:
- Create this table:
create table saved_pages (
id uuid not null primary key default uuid_generate_v4(),
created_at timestamp with time zone default timezone('utc'::text, now()) not null,
archived boolean not null default false,
url text not null,
html jsonb not null,
title text not null,
authors text not null,
reading_time int,
published_at timestamp
);
- Go to https://www.youtube.com/watch?v=LVxL_p_kToc
- Define the variable:
const data_html = JSON.stringify({ data: document.documentElement.innerHTML})
- Make the following call:
const data_html `{"data":"<head>\x3Cscript data-original-src=\\"/s/player/ace4(....)`
const table_data = {
url: "http://example.org",
html: JSON.stringify(data_html),
title: "Test",
authors: "Person",
reading_time: 6,
published_at: new Date().toISOString()
}
const { data: response, error } = await supabase.from("saved_pages").insert(table_data, {count:null});
Expected behavior
If it is not possible to use a JSON of roughly 5mb, then there should be a limitation specified in postgREST about this limitation.
Screenshots
If applicable, add screenshots to help explain your problem.
System information
- OS: macOS
- Version of supabase-js: 2.12.1
- Version of Node.js: v19.8.1
Additional context
It is possible to insert these directly by changing the format to HTML and changing the raw format to accept HTML, but not possible to insert this as a JSONB object within a table.
https://postgrest.org/en/stable/configuration.html?#raw-media-types
Bug report
Describe the bug
Inserting silently fails with no reason for large inputs.
To Reproduce
Set up:
const data_html = JSON.stringify({ data: document.documentElement.innerHTML})Expected behavior
If it is not possible to use a JSON of roughly 5mb, then there should be a limitation specified in postgREST about this limitation.
Screenshots
If applicable, add screenshots to help explain your problem.
System information
Additional context
It is possible to insert these directly by changing the format to HTML and changing the raw format to accept HTML, but not possible to insert this as a JSONB object within a table.
https://postgrest.org/en/stable/configuration.html?#raw-media-types