Solved

how to create a database using vb

Posted on 1998-11-06
4
129 Views
Last Modified: 2010-04-30
teach me how to create an application databse using vb
thankd
0
Comment
Question by:JOHNHO
4 Comments
 
LVL 1

Expert Comment

by:csalves
Comment Utility
Hello,

Your Question is simple you can execute DDL comands from VB.

For exemple:

IF you have a connection to an INFORMIX USER you can create a VB program to create a database with the SQL ANSI instruction
"CREATE DATABASE <database_name>;"

after that you can create so many tables you wish:
With CREATE TABLE instruction.

Bye,

0
 

Author Comment

by:JOHNHO
Comment Utility
CAN YOU EXPLAIN MORE TO ME PLEASE
BECAUSE IM SO STUPID
THANKS IN ADVANCE

0
 
LVL 1

Expert Comment

by:tommy_boy
Comment Utility
Johnho..

Get yourself a copy of DBMapper.  It maps an existing Access Database into Visual Basic code (BAS Module). There you can go through it at your own pace and se exactly how it is done.  DBMapper also creates the queries stored in Acess Databases.

I think it is shareware and you should be able to find it by searching the web. If you can't email me back at tommy_boy@rocketmail.com and I'll send you a copy.

0
 
LVL 3

Accepted Solution

by:
myqlG earned 20 total points
Comment Utility
using vb5 and DAO:
dim dbsnew as database
dim wrkdefault as workspace

 Set dbsNew = wrkDefault.CreateDatabase("c:\order entry\NewDB.mdb", _
        dbLangGeneral)
       dbsNew.Execute "CREATE TABLE Daily " _
        & "(Operator TEXT, regular INTEGER,gift INTEGER,shipping CURRENCY);"
dbsNew.Close
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now