Jump to content

Pointers In MySQL? Possible?


JustinK101

Recommended Posts

Is it possible to have a field in mysql that simply points to another field in a completely different table?

So, for example:

table1
field: first_name | varchar(50)

table2
field: first_name | table1.first_name

That way when the field in the other table gets modified the field in the new table gets updated automatically. This would be very useful for me. Thanks!
Link to comment
Share on other sites

I'm unsure why you would want to do something like that. Storing the same data in 2 places means that your database isn't normalized.

However, you could create a VIEW that would meet your criteria.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.