DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: ALTER TABLE

  1. #1
    David Codding Guest

    ALTER TABLE


    vb6/ad0/mdac 2.7

    Where can I find all of the syntax for the ALTER TABLE / ALTER COLUMN statements.
    I cant find much on the kb.

    TIA

    David


  2. #2
    Michael Culley Guest

    Re: ALTER TABLE

    Which database are you using? The help file for your database should contain
    this info.

    "David Codding" <dcodding@saicorporate.com> wrote in message
    news:3d04fa8e$1@10.1.10.29...
    >
    > vb6/ad0/mdac 2.7
    >
    > Where can I find all of the syntax for the ALTER TABLE / ALTER COLUMN

    statements.
    > I cant find much on the kb.
    >
    > TIA
    >
    > David
    >




  3. #3
    David Codding Guest

    Re: ALTER TABLE


    I'm using VB6 with Access 97 and Access 2000. I'd like to find something
    on-line that would list this syntax but my immediate problem is that I need
    to programmatically add a few columns to a table and change a column from
    a yes/no to an SMALLINT. All of that I have already done, but there is
    a couple of parameters that are as rediculous as the "Less than null" problem
    with access. Specifically I need to get the "Allow Zero Length String" =
    Yes and when I change the column from Yes/No to SMALLINT the "Format" says
    Yes/No and the table displays it with a check mark. That doesn't "appear"
    to be a problem, but I'd rather see the value. Again, I need to be able
    to changes these programatically and I would rather not use the ADOX catalog
    method if possible. And of-course the help inside Access-2000 doesn't even
    have "ALTER" in the index.

    db.Execute "ALTER TABLE mytable ALTER COLUMN AllowLogin SMALLINT DEFAULT
    0"
    The above line changes the field from yes/no to Integer but has the problem
    with the yes/no format

    db.Execute "ALTER TABLE mytable ADD COLUMN EmailAddrss TEXT(50) DEFAULT ''"
    The above line creates the field, but "Allow Zero Length String" is set to
    No"

    "Michael Culley" <m_culley@hotmail.com> wrote:
    >Which database are you using? The help file for your database should contain
    >this info.
    >
    >"David Codding" <dcodding@saicorporate.com> wrote in message
    >news:3d04fa8e$1@10.1.10.29...
    >>
    >> vb6/ad0/mdac 2.7
    >>
    >> Where can I find all of the syntax for the ALTER TABLE / ALTER COLUMN

    >statements.
    >> I cant find much on the kb.
    >>
    >> TIA
    >>
    >> David
    >>

    >
    >



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center