0

Hope someone can guide a noob as I have done alot of googling and searching here as well but here's what I am trying to accomplish.

I have a program that upon registering it creates a table that is yours in the database. A workerID is generated upon registration on that workerID gets attached the table name that gets created for you.

For example after you register you get assigned a worker ID number of 10001. A table is then created for you named DB_10001.

Easy enough.

Within Table DB_10001 there is a column that Identifies who the project creator was (ID'd by workerID). Worker ID: 10001 creates his or her own projects but sometimes, a project is assigned by another workerID and it is placed in DB_10001 table.

I want to create a trigger that if the PROJECT CREATOR (which is a column in DB_10001) is not the owner of the table (WorkerID: 10001), to be notified that the owner of that table (10001) of a pending project to they can either accept or reject.

Is it possible to put this trigger when the table is created???

Thanks in advance,

Stavros
  • 23
  • 1
  • 5
  • 1
    Which dbms are you using? (Many products have their own versions of triggers.) – jarlh Jun 23 '20 at 09:59
  • [Why should I tag my DBMS](https://meta.stackoverflow.com/questions/388759/) –  Jun 23 '20 at 11:36
  • Using SQL... I went ahead and did the coding in my application instead. But I am still stuck in figuring out how to get a return response if the assignee accepted. Do I just query the DB every minute or so in my application? – Stavros Jun 24 '20 at 10:04

0 Answers0