Ask and answer questions about WebRatio, WebML and BPMN

Just a simple question: how can I use MySQL database in WebRatio project? There's really NO information about this in the WebRation Wiki or anywhere else. I'm using Linux version of WR Personal. Thanks in advance for help.

asked 09 Dec '11, 15:18

dandys997's gravatar image

dandys997
15145
accept rate: 0%


HI!

The procedure for configuring a database is the same for all types supported by WebRatio (which are a lot!). Although there is no article explaining this part in detail, there are information/examples around:

  • inside WebRatio itself, Help > Web Modeling Tutorials > Add a Database describes the steps in detail for the Derby database;
  • this wiki article briefly mentions database configuration in the Synchronization paragraph.

How it is done

Every project containing persistent (DB stored) entities needs to contain at least one Database element specifying all the properties for connecting to a database, including its type. It is so commonplace that the Web Project creation wizard has a step for automatically creating one for you. Otherwise, you just need to right click the Data Model and choose Add Database.

Once you have a Database, select it and use the Properties view to choose the DB type, the connection parameters, etc. For MySQL you can choose MySQL or, usually, MySQL (InnoDB).

When you are done configuring the Database, right-click it and choose Synchronize. When doing this for the first time you will also have to provide the correct driver, which for MySQL you can download on MySQL site. The Synchronize operation will basically map all your entities and attributes to tables and run SQL statements to create them.

link

answered 09 Dec '11, 16:22

LorenzoDV's gravatar image

LorenzoDV
1754
accept rate: 66%

When doing this for the first time you will also have to provide the correct driver, which for MySQL you can download on MySQL site.

OK, but where should I put the driver file (or files)? Do I have to rename it or leave the original name?

link

answered 09 Dec '11, 16:39

dandys997's gravatar image

dandys997
15145
accept rate: 0%

If you run Synchronize without the driver, a message will be shown prompting you to select it. If you click the hyperlink on that message, a dialog will be shown which you can use to point to the JAR file of the driver. WebRatio will then take care of copying it to the correct location (usually the drivers subdirectory of the installation) and renaming it.

(09 Dec '11, 16:48) LorenzoDV

Great, it works. Thanks a lot for help! :)

(10 Dec '11, 04:00) dandys997
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×9
×2

Asked: 09 Dec '11, 15:18

Seen: 284 times

Last updated: 10 Dec '11, 04:00

©2001-2011 Web Models s.r.l. All rights reserved