abstra-docs
Search…
abstra-docs
Introduction to Abstra
Changelog
Security
Accessibility
Tutorials
Getting started
Lessons
Documentation
Front-end
Back-end
Connectors
Code
Storage
Airtable
Google Sheets
DynamoDB
E-mail
GraphQL
Microsoft SQL Server
MongoDB
MySQL
PostgreSQL
REST APIs
REST v2
SSH
Telegram
Project Settings
Powered By
GitBook
PostgreSQL
Configuration
Queries
You can write regular
PostgreSQL queries
here, for example:
1
SELECT * FROM "Users" u WHERE u.name LIKE '%John%'
Copied!
Passing parameters to the query
You can add
params
to your query by naming them
$1
,
$2
,
$3
, ... When you use this query in the frontend, you can dinamically fill the parameters:
1
SELECT * FROM "Users" u WHERE u.name = $1
Copied!
Insert example:
1
INSERT INTO "Users"(name, email) VALUES ($1,$2)
Copied!
Update example:
1
UPDATE "Users" SET name = $1 WHERE u.email = $2
Copied!
Delete example:
1
DELETE FROM "Users" WHERE u.email = $1
Copied!
Previous
MySQL
Next
REST APIs
Last modified
1yr ago
Copy link
Contents
Passing parameters to the query