Query SeaTable with SQL

SeaTable offers a SQL like interface that supports SELECT, INSERT, UPDATE and DELETE statements.

If you are familiar with SQL, you will have no difficulties to use this endpoint because typical SQL-statements are supported.

This endpoint is the most powerful one that SeaTable can offer and it does not differentiate between the two SeaTable backend (normal and big data). Also the metadata of the table is returned.

📘

INSERT and big data

New rows (INSERT statement) are always added to the big data backend. An error message will be returned, if the big data backend is not activated for the target base.

The complete SQL Reference can be found documentation in the developer manual.

Here are some example requests for a fictitious table Family with the columns name, age and birthday:

  • SELECT * FROM Family LIMIT 3
  • SELECT name, age, birthday FROM Family
  • SELECT name, age FROM Family ORDER BY name
  • INSERT INTO Family (Name,Age) VALUES ('Name', 23)
  • SELECT * FROM Family WHERE Name=? AND Age=?

SELECT does not support column keys. You can only limit the output by column names.

📘

Avoid SQL injection

If you use ? in your SQL-statement, you have to provide values to replace the placeholders with parameters. This protects against SQL injections.

🚧

Max return limit

The request returns a maximum of 10 000 rows, even if you specify a higher limit in your SQL-statement.

Language
Authorization
Bearer
URL
Click Try It! to start a request and see the response here!