• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

relation between two tables

Hi everyone,

I have defined two tables. Column1 of both is defined as name of employees, I want every time that an employee inserted in Table1 a new row to be inserted (or added) to Table2 with the name of that employee in Column1, or even if one of employees deleted in Table1 that employee to be deleted in Table2 too. Is it possible?

Thanks in advance to everyone,

Saeed
 
Thanks Luke M
It works only if we copy formula in second table down, it can't insert a new row when a new row is added to Table1. Table2 rows must be dynamic based on Table1. This is my problem!
 
I think the only way to do what you are asking exactly is to use VB to try and capture the add/delete, and then mimic the data into the 2nd table.
Might I ask, however, if the two tables have identical layout/names, why not just combine them into a single table?
 
Ok, but I don't know VBA too much. What codes?

@ your ask, because the two tables have different usage, one for raw data, the other one combination of some calculations based on Table1 data and its own data. tables are in separate sheets and are printed separately.
 
This topic is the same as last question of this, just different forum at this same site:
http://chandoo.org/forum/threads/relation-between-two-tables.12548/

What you're doing "is called cross-posting and is generally frowned upon in the Blogosphere as it causes people to potentially waste our time when a question is already answered. You should also check and respond to posts and let posters know if they are heading in the write direction or not." Hui's dixit, SIC. And I agree 101%.

If you'd have read the main green sticky post at this forums main page...
http://chandoo.org/forum/forums/new-users-please-start-here.14/
...you should have noticed this points:

"Consider that the world is operating 24hrs a day. A late post today may well be answered by someone else overnight."

"If you and a reader have been involved in an ongoing conversation and the conversation suddenly stops, recognize that the person may have gone to bed, even though you have just arrived at work. In the worst case a reader may go on holidays and not get back to the question for a few days."

"Never title your posts as "Urgent", "Priority" "Immediate". It may be Important to you, but not for rest of the members here. These words will be moderated out."

"Cross Posting, generally it is considered poor practice to cross post, that is to post the same question on several forums in the hope of getting a response quicker.
If you do cross post, please put that in your post.
Also if you have cross posted and get an answer elsewhere, have the courtesy of posting the answer here so other readers can learn from the answer also, as well as stopping people wasting there time on your answered question."

"Say "Thanks", whenever you can. Recognize when someone has bothered to go to the trouble and time to assist you with your question for free. Often readers will spend several hours working on a solution to a problem, a line of recognition will go a long way."
 
Back
Top