docs to the pushing script into the db
This commit is contained in:
25
server/src/table_script/docs/push_script_to_db.txt
Normal file
25
server/src/table_script/docs/push_script_to_db.txt
Normal file
@@ -0,0 +1,25 @@
|
||||
This is how we can push script into the database, now its stored after a push in postgres.
|
||||
❯ grpcurl -plaintext -d '{
|
||||
"table_definition_id": 14,
|
||||
"target_column": "fax",
|
||||
"script": "(set! fax telefon)",
|
||||
"description": "Copy telefon value to fax column"
|
||||
}' localhost:50051 multieko2.table_script.TableScript/PostTableScript
|
||||
{
|
||||
"id": "2"
|
||||
}
|
||||
❯ psql -U multi_psql_dev -d multi_rust_dev
|
||||
|
||||
psql (17.2)
|
||||
Type "help" for help.
|
||||
|
||||
multi_rust_dev=> SELECT * FROM table_scripts;
|
||||
|
||||
|
||||
id | table_definitions_id | target_column | script | source_tables | source_columns | description | created_at
|
||||
----+----------------------+---------------+--------------------+---------------+----------------+----------------------------------+-------------------------------
|
||||
1 | 15 | fax | (set! fax telefon) | | | Copy telefon value to fax column | 2025-03-08 11:52:40.344114+01
|
||||
2 | 14 | fax | (set! fax telefon) | | | Copy telefon value to fax column | 2025-03-08 11:54:05.664425+01
|
||||
(2 rows)
|
||||
|
||||
(END)
|
||||
Reference in New Issue
Block a user