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 derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

create table

Status
Not open for further replies.

carranz

Technical User
Nov 17, 2006
40
US
I have a query that makes a table. I create some fields that are not in the table I\'m using for the query. So I create fields on the fly.

This works just fine, but the data type for the fields I created on the fly are set in binary. I would like to set them as TEXT while I make the table by using the make table
query

Does anyone know how to do this
 
What is your actual SQL code and which fields you want to set as text ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
This is what it looks like when I look at the SQL
I run this it create a table test
but when I look at the design it shows the data type as binary

How can I do this through the query

SELECT [Last_namex] AS Last_name, [First_namex] AS First_name INTO test;
 
How do you:
create some fields that are not in the table I\'m using for the query. So I create fields on the fly.

Leslie

Anything worth doing is a lot more difficult than it's worth - Unknown Induhvidual

Essential reading for anyone working with databases:
The Fundamentals of Relational Database Design
Understanding SQL Joi
 
You SQL code is strange: no FROM clause in your SELECT instruction !
It should ask for 2 parameters values, doesn't it ?

Provided your code is real, you may try either this:
PARAMETERS [Last_namex] TEXT(50), [First_namex] TEXT(50);
SELECT [Last_namex] AS Last_name, [First_namex] AS First_name INTO test;

Or this:
SELECT [Last_namex] & '' AS Last_name, [First_namex] & '' AS First_name INTO test;

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top