CREATE TABLE IN ACCESS

Discussion in 'ASP General' started by Rob, Jul 10, 2003.

  1. Rob

    Rob Guest

    Hi all,

    Quick question, how do you create a table in MS Access from with an asp
    script?

    I will be creating the table name from Request.querystring("name"), also
    needs fields of branchname and branchcode

    guess something like CREATE TABLE & Request.querystring("name") branchname.
    branchcode.

    Thanks in advance
    Rob
     
    Rob, Jul 10, 2003
    #1
    1. Advertising

  2. Rob

    Ray at Guest

    Not sure what kind of columns BranchName and BranchCode need to be. I'll
    assume Text(255) and Integer, respectively.

    sTablename = Request.Querystring("name")

    sSQL = "CREATE TABLE [" & sTablename & "] (BranchCode Int PRIMARY KEY,
    BranchName Text(255));"

    objADO.Execute sSQL


    Ray at home



    "Rob" <> wrote in message
    news:bei78i$401$...
    > Hi all,
    >
    > Quick question, how do you create a table in MS Access from with an asp
    > script?
    >
    > I will be creating the table name from Request.querystring("name"), also
    > needs fields of branchname and branchcode
    >
    > guess something like CREATE TABLE & Request.querystring("name")

    branchname.
    > branchcode.
    >
    > Thanks in advance
    > Rob
    >
    >
     
    Ray at, Jul 10, 2003
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. David Williams
    Replies:
    2
    Views:
    1,171
    Jacob Yang [MSFT]
    Aug 12, 2003
  2. Rio
    Replies:
    4
    Views:
    1,241
  3. donet programmer
    Replies:
    1
    Views:
    524
    donet programmer
    Dec 5, 2006
  4. Sonu
    Replies:
    1
    Views:
    840
  5. Replies:
    0
    Views:
    156
Loading...

Share This Page