Make Table STRING field results in NUMERIC field in table. WHY

  • Thread starter Thread starter Phil
  • Start date Start date
P

Phil

I have a data file which I need to link to another datafile. Although
the data is numeric, in the table I need to link to, (and cannot change)
the field type is text. So I use CStr() which converts that number to a
text string, right? Well I tried to link to this query, and "type
mismatch." So I convert it to a maketable query, and I STILL end up
with a field, in the QUERY looks like :

Ent_NumberPTW: CStr([Entnumber]),

But in the resulting TABLE is a NUMBER field. Why is this, and how do I
fix it?

Phil
 
Phil said:
I have a data file which I need to link to another datafile. Although the
data is numeric, in the table I need to link to, (and cannot change) the
field type is text. So I use CStr() which converts that number to a text
string, right? Well I tried to link to this query, and "type mismatch." So
I convert it to a maketable query, and I STILL end up with a field, in the
QUERY looks like :

Ent_NumberPTW: CStr([Entnumber]),

But in the resulting TABLE is a NUMBER field. Why is this, and how do I
fix it?
Hi Phil,

I cannot think of a reason why.....
but a "quick fix" (or something that
might "tell me more") would be to
change the field in the table you just
made to number type,

empty it,

then change your maketable query
to an append query.

What happens when you run the new append query?

gary
 
meant to say:
change the field in the table you just
made to TEXT type

Gary Walter said:
Phil said:
I have a data file which I need to link to another datafile. Although the
data is numeric, in the table I need to link to, (and cannot change) the
field type is text. So I use CStr() which converts that number to a text
string, right? Well I tried to link to this query, and "type mismatch."
So I convert it to a maketable query, and I STILL end up with a field, in
the QUERY looks like :

Ent_NumberPTW: CStr([Entnumber]),

But in the resulting TABLE is a NUMBER field. Why is this, and how do I
fix it?
Hi Phil,

I cannot think of a reason why.....
but a "quick fix" (or something that
might "tell me more") would be to
change the field in the table you just
made to number type,

empty it,

then change your maketable query
to an append query.

What happens when you run the new append query?

gary
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top