I want it to be dynamically without need to specify the company Id, there must be some solution?
I think I was not that clear before, let me try again.
a Company can have zero (null) or many employees.
a Comapny can have zero (null) or one information.
When a company is disabled (enabled=0)...
Hi,
I cant get this query to work with MySQL.
delete from
companies as com,
employees as emp,
informations as inf
where
emp.companyId=com.id
and
inf.companyId=com.id
and
com.enabled=0;
I ve this tables...
Company
------------
Id Name Enabled
1 acme 0
2 mysql 1
Employees
-------------
Id Name...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.