Building A Database. (please read this after you have read Database basics)

easyGen takes the hard work out of building your database, you don't need to know anything about how your database works or what to do. It doesn't matter if you are starting from a blank database or an existing one, easyGen manages it all for you.

To add a new or existing database to your project click on Data Source Manager in the Project Menu.

Then either Add a new one or choose an existing one you may have set up before.

If you choose to add, the data source wizard steps in to build your connection, you can choose from MySQL for PHP or any of the OLE databases in the list, for instance if you were using a Access DB you would choose Microsoft Jet 4.00 OLE, if you wanted to use a SQL Server database you would select the OLE DB for SQL Server

 

The wizard will then ask you where the database is and any usernames and passwords, it will then test the connection for you. And ask you if you want to import the current table information (Schema) that may already exist, even if this is a new database we advise clicking on "Import Schema" just incase some information is held in the database.

 

 

Now easyGen knows what information is already in your database you can start to build your pages, if you have existing tables you can use them to either pull data from them or save information to them. To add fields to a existing table or create a new table with fields all you have to do is create a blank page, add a form from the toolbox, add the new fields (i.e. text box) and then choose "Build Database fields from form values" in the Tools menu.

TIP: easyGen automatically assigns a name to every new dynamic element you add to a page, you may first want to change the names of your data entry fields in the Properties window so you can easily identify them and give them a meaning, to do this just click on the input field (the text box) and change the name in "Properties <INPUT>" We have called ours Name Box C_Name (short for customer name) and email C_email.

Then the easyGen wizard takes over and builds your data source from the values you have on your page, you can choose which ones to use and what sort of fields they are. (i.e. Text, Date, Number) this allows you to do calculations on numeric fields and store the correct type of information in the database. The wizard will also automatically set up a Primary Key which will be a AutoNumber as outlined in Database Basics.

When you now export your project your database will be updated with the new information. We should also point out that you will need full permissions to add fields and tables to your database. If you are using MySQL you will need Alter Privileges, Access will need to be set to read and write privlidges, and be in a read and write folder. Other databases will need you to have ownership rights. Please check this with your service provider if you are renting space on a server database. Make sure you have full privileges and can alter the database, add data and view data.

Next we will look at how to pull data from you database and use it in you web pages, Click Here