• 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.

Primary Keys are Number and Text

Nangys

New Member
Hi All,

I'm trying to do a relationship between two tables that looks like these:

Table1
Company Code | Name | Sales
12345 Comp1 $25
UEB213 Comp2 $35

Table 2
Company Code | State
12345 FL

However, I get the error that "Cannot convert value of type text to type Number". (See attachment)

Is there a workaround?

Thanks

Regards,

Fernando
 

Attachments

  • 2-16-2015 6-06-33 PM.png
    2-16-2015 6-06-33 PM.png
    15.1 KB · Views: 5
Can you swap records in Table1 so that the first record has at text value in that field instead of a number
 
Hi Hui,

You mean have something like these?:

Table1
Company code | Name | Sales
UEB213 comp2 $35
1234 comp1 $25

Actually, the real data starts first with the text type codes, then is all mixed it up.

Regards,

Fernando
 
Hi Fernando ,

But when you have data such as UEB213 in a field should that field not be defined as TEXT to start with ? Ideally , this field in both tables should be defined as TEXT ; only those fields which need to have computations performed on their data should be defined as numeric fields.

Narayan
 
Hi Fernando ,

But when you have data such as UEB213 in a field should that field not be defined as TEXT to start with ? Ideally , this field in both tables should be defined as TEXT ; only those fields which need to have computations performed on their data should be defined as numeric fields.

Narayan

Hi Narayan,

That was the main problem. I had some data as text and another one as numbers.

Thank you for your advice.

Regards,

Fernando
 
Back
Top