Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 Wondering about DDL in Access...

Author  Topic 

HCLollo
Starting Member

49 Posts

Posted - 2006-02-01 : 09:08:54
Hi all! :)
I was (not really) idly wondering if it's possible to create a table
in Access like in SQL Server, using a sort of CREATE TABLE command...
It would really help me greatly in (at least) an application I'm
currently dreaming (er, working ) on...unfortunately, right now
I'm not able to play with some tests, so here I am...

Ok, thankies in advance to anyone that spends his time on my thread!

HCL

"If it works fine, then it doesn't have enough features"

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2006-02-01 : 09:13:33
You can do it via VBA (I think)..

Don't know of any other way..
Go to Top of Page

HCLollo
Starting Member

49 Posts

Posted - 2006-02-01 : 10:17:17
Yes, I'm actually using it for an ASP-based application in which, at
some point, I will be in need of creating some tables, runtime; I'll
try some syntax-jocking but...well, it's soooo hard finding some
SQL docs for Access!

Thanks so much RickD!

HCL

"If it works fine, then it doesn't have enough features"
Go to Top of Page

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2006-02-01 : 11:10:23
The easiest way is to run a create table query with dummy values, then go from there..
Go to Top of Page

HCLollo
Starting Member

49 Posts

Posted - 2006-02-01 : 11:39:39
Mmm...indeed, what was concerning me was the syntax of the
command, since Access's SQL and T-SQL are <i>quite</i> similar,
and fail just when you most need the similitude...

Anyway, as I said, it was mainly idly wondering: when the going
will get tough, lots of tests will start

Have a good night

HCL

"If it works fine, then it doesn't have enough features"
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2006-02-01 : 12:03:05
This might be just what you need:

http://www.devguru.com/Technologies/jetsql/quickref/jet_sql_list.html

When in doubt, try googling. Remember that Access uses the "JET" database engine, so search on that word might help also.
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2006-02-01 : 12:04:38
the on-line help in Access also has tons of stuff. Make sure that you have all options installed with Access. I found tons of stuff under

Microsoft JET SQL Reference -> Data Definition Language
Go to Top of Page

HCLollo
Starting Member

49 Posts

Posted - 2006-02-02 : 02:29:59
Thank you so much for the tips Doctor!
I owe you some...:)

HCL

"If it works fine, then it doesn't have enough features"
Go to Top of Page
   

- Advertisement -