Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Two table with one similar column

Status
Not open for further replies.

scon44

Technical User
Jun 15, 2005
65
US
I have two tables with one similar column between the two.

The similar column contains characters (names of places)

I would like to relate the two tables, based on the names of places, but since they are not exactly the same this is not possible.

Any idea on how to use string operators to link up say dublin and dublin_aaa and aviod the suitation where they might be a dublin_bbb?

Probably not but I thought it might be worth asking. Thank you for reading.
 
this is just an out of the box idea.

You can create a computed column on one of the tables. This column should have a function that can convert data of the table to match with the other table.

Now you could create a FK on the computed column (dont know if this is possible)...


Known is handfull, Unknown is worldfull
 
What is the relation between those 2 tables. Are those tables are like STATE, COUNTY and same the county name might exists in the other STATE? Give some examples of both the tables data and how they are related?
 
The data types are the same. Text.

Example are town or city names. On one table citya would exist and on the second table city_a would exist.

These two are the same place. And it's not consistent.... some of them have lakeme_1 or lakeorange_ds

It's like you give a list to someone and they go and create a database but don't follow the list they were given... u know?

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top