All Questions
Tagged with database-trigger or triggers
21,801 questions
-4
votes
0
answers
46
views
Triggers usage on updating two tables
I'm having two loans table. one is for internal other one is for external. Both having similar columns.
I don't want to disturb one for other so i have created 2.
Problem is both has to be sync. ...
0
votes
1
answer
80
views
Checkbox behavior
So as per previous suggestions, I'm using checkboxes to replace the .getUi method so my project will work properly on mobile devices. I've come across a strange scenario and I wanted to confirm this ...
2
votes
1
answer
72
views
In my Blazor SSR app., my service method is failing when calling an Azure HTTP trigger
In my PayPalService.cs file, I have a public method in the class that calls an Azure HTTP triggered method in PayPalFunctions.cs file that keeps failing due to an error: "Method not Allowed"....
1
vote
1
answer
70
views
Google Sheets script .protect() working intermittently
Depending upon a specific input in a set of cells on my Google Sheet, I want to be able to freeze a particular row and stop it being updated.
I have the following script:
function testFreeze() {
...
1
vote
1
answer
29
views
Azure Logic App - Azure File Trigger - Not firing on subfolder
I want to implement a logic app workflow which is using a trigger:
Logic App: Standard
Connector: Azure File Storage
Trigger: When a file is added or updated
Configuration: giniusdata/Plot/PDF/PDFOUT-...
1
vote
1
answer
80
views
MYSQL Trigger after insert
I am writing a trigger to run whenever a new row is inserted into table_a. The trigger adds a new row into table_b, see insert statement.
CREATE TRIGGER `trigger` AFTER INSERT ON `table_a`
FOR EACH ...
0
votes
1
answer
98
views
Time Trigger is not firing after few hours in Google Apps Script
I have a script that processes email's data and saves it in google sheet. I have set a time trigger to run automatically every 15 minutes. It runs fine for few hours and then it stops working. I do ...
1
vote
1
answer
112
views
Why is this Deferred Constraint Trigger Raising an Exception on the Not Final State of the Record
Why is my deferred constraint checking an intermediate state and not the final state of the record?
We use PostgreSQL 16.9 for our database and we use Python3 and Psycopg2 to manage our data pipeline.
...
2
votes
2
answers
90
views
Use trigger to log addition of child record only if parent not added in same transaction
I'm using triggers in Postgres to do audit logging in a system with parent/child tables. Think an invoice with line items.
The problem I'm trying to solve is that if an invoice is new, the invoice and ...
1
vote
1
answer
162
views
Problem with INSERT and UPDATE Trigger in case of INSERT ON CONFLICT in Postgres
I have a problem regarding ON INSERT BEFORE triggers firing on rows that are inserted via insert on conflict update upserts.
I have a postgres (v.17) database with a base table or super table that 5 ...
0
votes
1
answer
94
views
Dynamically extract PK value from OLD inside generic trigger while trying to save audit info
I am trying to use a postgres (v17) audit trigger found here: Postgres Audit Trigger:
CREATE OR REPLACE FUNCTION audit.if_modified_func() RETURNS TRIGGER AS $body$
DECLARE
audit_row audit....
2
votes
2
answers
93
views
How to setup a constraint on this child table?
I have the following 2 postgresql tables:
CREATE TABLE my_table_a (
id SERIAL PRIMARY KEY,
my_field_a BOOLEAN NOT NULL
);
CREATE TABLE my_table_b (
id SERIAL PRIMARY KEY,
fk_id INTEGER ...
1
vote
1
answer
91
views
Oracle database Trigger to track account lock issues [closed]
I’m looking for guidance on creating a DDL trigger to track account lock scenarios, including failed login attempts.
I’ve already implemented a LOGON trigger, but as expected, it only captures ...
0
votes
2
answers
115
views
Copying rows to new sheet rather than Moving rows, Lowest row with empty cell in Column "A"
I have the following script in a sheet to move rows of data from tab to tab based on the result of a drop down in column C. I'm having a couple of problems that I have tried many different solutions ...
0
votes
2
answers
104
views
INNER JOIN on inserted trigger table includes all table rows
My objective is to create a trigger which fires after an UPDATE, and which set a ModifiedTimeStamp field to the current date for all and only effectively updated / inserted rows.
I had a previous ...
0
votes
2
answers
75
views
onOpen timing out is there a way to make it run faster?
I have a spreadsheet with 11 sheets. I am using an onOpen script that checks the first 9 pages, hides all of the blank rows, and sets the cursor to cell B4 (a search box). For the last two sheets it ...
1
vote
1
answer
57
views
WPF HeaderedItemsControl changing template in trigger not working
I have this xaml code:
<HeaderedItemsControl ItemsSource="{Binding ProjectInfo.ProgressEntries}"
Focusable="False">
<HeaderedItemsControl.Style&...
1
vote
0
answers
23
views
How to Debug Trigger Execution Order Conflicts in OceanBase?
OceanBase Version
OceanBase Community version 4.2.1 (MySQL mode)
We have a customer order system on OceanBase 4.2 where multiple triggers interact:
-- Trigger 1: Update inventory AFTER ORDER INSERT
...
-2
votes
1
answer
85
views
When a cell changes, copy a range [duplicate]
When the value in P47 changes, I'd like a range of cells to copy from column L to column A of that same sheet. (I don't think I'm succesfully entering the "IF" condition but I'm not sure ...
0
votes
2
answers
53
views
Exception inside pragma transaction oracle stored procedure
I have an app table. On the insert of rows, a trigger is fired, and it logs audit to a audit table via a pragma autonomous transaction procedure.
create trigger app_trg
after insert on app_txn
for ...
0
votes
1
answer
65
views
Get the result of the triggered pipelines
I have a main azure pipeline (pipelineFinal) that should be triggered when a pipelineA is finished.
pipelineA:
trigger: none
jobs:
- job: BuildA
displayName: "Build Pipeline A"
pool:
...
0
votes
2
answers
96
views
How can I prevent my Apps Script code from timing out?
I have the following code:
function onOpen() {
const ss = SpreadsheetApp.getActive();
ss.getSheets().forEach((sheet, index) => {
if (index < 9) {
const lastRow = sheet.getLastRow();...
0
votes
0
answers
56
views
Spark with availableNow trigger doesn't archive sources
I use Spark to read JSON files that appear in a folder everyday with path pattern Yyyy/mm/dd to convert them into Iceberg format. Both folders JSON and Iceberg are in a s3 bucket on different paths.
...
-3
votes
1
answer
82
views
sqlalchemy DML statement cannot have any enabled triggers
I'm using SQLAlchemy and MSSQL 2019 with triggers (insert/update) can't remove .
engine_new = create_engine('mssql+pymssql://***:***@***/***', implicit_returning=False)
Session_new = sessionmaker(bind=...
0
votes
0
answers
64
views
PostgreSQL Trigger: Keep my_table2 column in sync with my_table1 regardless of insert order
I have two tables: my_table1 and my_table2. a_column in my_table2 should always match the corresponding value in my_table1.
However, the tricky part is that rows in my_table2 may be inserted before or ...