By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,466 Members | 1,537 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,466 IT Pros & Developers. It's quick & easy.

Join 2 tables using text and num fields

P: 77
Hi,

I have a query to join two tables,
Table1 - Case (Text), Division (Text)
Table2 - CaseID (Text), Division Num (Number)

Please help to convert (Number to text) and join the tables in the same query.
Please treat this as urgent.

Load of thanks.
May 23 '08 #1
Share this Question
Share on Google+
1 Reply


FishVal
Expert 2.5K+
P: 2,653
Hi,

I have a query to join two tables,
Table1 - Case (Text), Division (Text)
Table2 - CaseID (Text), Division Num (Number)

Please help to convert (Number to text) and join the tables in the same query.
Please treat this as urgent.

Load of thanks.
Hi, AccessHunter.

Try something like the following in ON clause of join.
Expand|Select|Wrap|Line Numbers
  1. .... ON Val(Table1.Division)=Table2.[Division Num] ...
  2.  
or
Expand|Select|Wrap|Line Numbers
  1. .... ON Table1.Division=Str(Table2.[Division Num]) ...
  2.  
or use type conversion function CLng(), CStr() instead of Val() and Str()

Regards,
Fish
May 23 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.