Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2004
    Posts
    72

    Unanswered: how to create sql database in visual basic

    First i am newbie in vb and Sql server...

    Is possible to create and attaching, via vb classic or VBA, a sql
    database in this instance:\\DVD377-14D9E48C\SQLEXPRESS...
    I have Sql Express.

    Database name: mydatabase
    Database Table: mytable

    fileds:
    fiedl1 text format
    fiedl2 text format
    fiedl3 text format
    fiedl4 date format
    fiedl5 number format
    fiedl6 text format

  2. #2
    Join Date
    Nov 2005
    Location
    San Francisco, CA
    Posts
    506
    Quote Originally Posted by sal21
    First i am newbie in vb and Sql server...

    Is possible to create and attaching, via vb classic or VBA, a sql
    database in this instance:\\DVD377-14D9E48C\SQLEXPRESS...
    I have Sql Express.

    Database name: mydatabase
    Database Table: mytable

    fileds:
    fiedl1 text format
    fiedl2 text format
    fiedl3 text format
    fiedl4 date format
    fiedl5 number format
    fiedl6 text format

    You can execute sql statement from your code...its better to read a book on vb - database programming.
    Success is the ability to go from one failure to another with no loss of enthusiasm.
    - Sir Winston Churchill
    Joydeep

  3. #3
    Join Date
    May 2004
    Location
    Seattle
    Posts
    1,313
    Also it's best not to be creating tables from app code.

    If your app logs in as a user that has rights to create tables, then it's logging in as a user with far too many rights - usually only an admin would be allowed to create tables. So this would ONLY be acceptable to me if your app was an administrative app, such as SSMS.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •