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

Using SQL to CREATE a TABLE

Status
Not open for further replies.

PublisoftTelecom

Programmer
Apr 4, 2000
6
CA
I'm using an ACCESS database for a Web application in Cold Fusion and I need to create a table dynamically.&nbsp;&nbsp;<br><br>So far it's not so complicated... I use CREATE TABLE and that's it!!!&nbsp;&nbsp;My problem is that I need to define a TEXT field that will allows NULL entries. (Allow zero length Property)<br><br>Thanks for the help!
 
While creating the table and defining the constraint for the column. Just apply NULL constraint also. Then you will be able to insert NULL also for that column<br>Does this answer your question ?<br>Thanx<br>Siddhartha Singh<br><A HREF="mailto:ssingh@aztecsoft.com">ssingh@aztecsoft.com</A>
 
Good morning!<br><br>Thanks for the tip, but it doesn't seems to work.&nbsp;&nbsp;Here's the way I'm doing it (and the way I used to do it with standard SQL!) but since I'm creating an ACCESS table, some differences seem to applies...<br><br><br>CREATE TABLE ChoixReponse_8<br> (<br> choixReponseID&nbsp;&nbsp;&nbsp; COUNTER,<br> choixReponseNom&nbsp;&nbsp; TEXT(50) NULL<br> )<br><br><br>Thanks for your help!
 
I'm not familiar with using SQL to create tables in Access, but I believe you could try this:<br><br>CREATE TABLE ChoixReponse_8<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;choixReponseID&nbsp;&nbsp;&nbsp;&nbsp;COUNTER,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;choixReponseNom&nbsp;&nbsp;&nbsp;TEXT(50) DEFAULT NULL<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;);<br><br>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top