|
Installation
How to install WWW SQL Designer
Featured InstallationYou will need to install WWW SQL Designer if you want to:
Just download and unpack latest application archive. There are generally no requirements, but to use server-side storage, one should have a working webserver. |
► Sign in to add a comment
How do you install this. I'm only able to unzip it.
You need to do a little digging... I struggled at first, as well. For starters, you need to make sure the entire zip file is unpacked in your server's document root. Access the folder/index.html file to see if it displays the grid and if you are able to create tables. Next, create a database and add the table located at "sqldesigner/backend/php-mysql/database.sql" After creating the database and table make adjustments to the first function in the index.php file located in the same directory.
I haven't played with the Import from DB option yet but I suspect you would need to make changes to the second function and possibly the fourth (by changing "information_schema" to the database you want to import) but you are on your own with that one.
By the way, ondrej.zara, excellent tool! Thanks for the time you've spent on this! Looking forward to seeing where you go with it!
If you want to use import feature, here is how I did it :
To make the save and load feature working follow this steps : 1. Open backend/php-mysql/index.php 2. In setup_saveloadlist function change SERVER, USER, PASSWORD and DB to fit your configuration 3. Import in DB the file backend/php-mysql/database.sql
To make the import from db feature working follow this step : 1. Open backend/php-mysql/index.php 2. In setup_import function change SERVER, USER, PASSWORD
Before any of this step, I suggest that you create through phpmyadmin or mysql client the sqldesigner mysql account.
The process for other server import should be similar.
Note that in php.ini turning on only the php_mysqli extension won't work; you must also turn on the php_mysql extension.
It's also worth noting that (at least with Apache) if you change php.ini you must restart the web server as the php module only reads php.ini once. Which is certainly sensible, but can be annoying when you forget and then waste time trying to figure out why something isn't working.
My installation worked and it seems to be working fine except for one thing - trying to add a comment to a table crashes my browser. (Safari crashes and google gives the "aw snap" crash page). Anyone have any suggestions?
This is probably related to http://code.google.com/p/wwwsqldesigner/issues/detail?id=64 . Stay tuned - it looks like the problem is apparently nearly fixed in Chrome :)
ah, yes that sounds similar. Thanks :)
very good tool, zara. Congratulations.
You state: "There are generally no requirements"
A Web server is not a requirement? One should be able to just open the index.html file directly into the browser and work away? I can't even add a table in Safari 4 or Firefox 3.5 (OS X 10.5 PPC). So it seems to me I have to install in my web server?
My objective would be to design a data model and export it as a SQL creation script.
Web server is definitely not a requirement for a basic functionality. It is necessary only for save/load/export/import tasks.
I got it now. Suggestion: Make a paint selection – mouse held down + making a selection - create a table just like just clicking. For some reason I made a paint move instead of a click. For me that was the most intuitive move.
This looks like something I'd like to install on my web server. Will try it in a live project right now.
Big hand!
I can't seem to get this working. I've extracted the zip file OK and brought the index page up in my web browser. But I just get the following error message:
Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022) Timestamp: Thu, 9 Sep 2010 12:12:52 UTC
Message: Access is denied.
Line: 201 Char: 3 Code: 0 URI: file:///E:/Program%20Files/SQL%20Designer%202.5/js/oz.js
I'm running it on IE8 on XP SP3 inside VMWare. Any ideas what line 201 is doing that IE/XP is objecting to?
Puzzled?
John
Maybe some silly security restrictions in IE and/or Windows prevent local files (served with file:/// protocol) to use JavaScript?? Are you sure there was no confirmation/allowance dialogue prior to this error?
I have an old IIS5 running in my Windows XP. After downloading the .zip I extracted it´s content (a folder maned wwwsqldesigner-2.5) under C:\Inetpub\wwwroot (the default root folder). After, I created an alias "wwwsqldesigner" (no version number) pointing to the new folder using the IIS management applet in the control panel. In the browser entered:
and the application displayed. I was able to add two tables with a column each and set an FK relationship. It all took about 5 minutes. Excellent, Ondrej!is there any way to actually run the SQL file that is generated directly from the system? anyone extended it?
Just transfer it to phpMyAdmin via clipboard :)
CUBRID Database project has added WWW SQL Designer to the list of Web applications supporting their database. See http://www.cubrid.org/wwwsqldesigner.
Besides the DEMO site has been created at http://sqldesigner.cubrid.org/. You might want to add the DEMO site link to either your Manual or Installation Wiki page. Otherwise, I could not find one. In fact, I saw somewhere here the link for the demo site, which loaded some demo schema, but could not find it again. Perhaps, it would be good to place this demo site at some visible spot as well.
There already is a canonical demo site, located at http://ondras.zarovi.cz/sql/demo/?keyword=default and linked directly from project's homepage at http://code.google.com/p/wwwsqldesigner/ .
Right. I remember I saw somewhere, but the links are so tiny I could not find again. Anyways, the http://sqldesigner.cubrid.org/ demo site is backed by the CUBRID Database. That should be the difference.
If you guys want an easy way to run on your local machine without a lot of hassle, you can always use Bitnami's AMP Stacks (available in Linux and Windows varieties - LAMP and WAMP respectively).
This will install apache and mysql on your local machine, and give you a control script.
http://bitnami.org/stack/wampstack
installation is a 2min job. the graphical aspect is stunning, but the time needed to import the structure of one of my smallest database was deadly long. The problem was, seen from my processlist, the queries on the information_schema. tables limiting column per column for every table found in the database. SQL AND information_schema were not created to be used like that.
It took 5 mins to extract info from 21 tables (without notice! I'd expect 99.9% of users re-trying to reimport data almost twice. I did it, I manually killed the duplicate queries on the db)
Given this, it's really nice
The front end of this is fantastic! I had to rewrite the import function to read table definitions from DESC [table] over the tables in the database instead of the information_schema etc. Now it is loading a database of 200 large tables in a few seconds. This is a seriously useful piece of software, something like this has been needed for a long time have been contemplating getting something written to do this exact thing in fact, I just don't really understand the javascript so much, getting the lines between the divs moving and recalculating as they were dragged about was always the stumbling block. Well done!
How do you install this? I got the latest version and unzip it. I opened the file named "index.html" and only appear empty gird without any controls.
I had the same problem index.html appears as an empty grid without any controls.
Use a (local) webserver to view this application, i.e. download, unzip to webserver's root, goto http://localhost/path/to/extracted/archive
NOTE - opening the index file in Chrome you will not see the controls to create a table, etc. Use Firefox and everything works.
I can't use 'save" function. Get a message : 'Server response: Service Unavailable' I'm using Google Chrome and WAMP server. I've checked the server is online.
Thumbs up for this very easy-to use tool!!
To save data, you must properly configure the desired backend to suit your setup. For instance, if you use php-mysql backend to store designs, you have to:
1) create a storage table according to backend/php-mysql/database.sql 2) setup connection and credentials in backend/php-mysql/index.php
:)
Thanks for the help. I'm not a techie at all and struggled a bit but I finally succeeded in saving my tables!!
I'm not a DBA and only have SQL basics but I happen to write SELECT scripts and always have trouble remembering tables names and the links betweend each other.
I was really eager to have the tool working on my comp and get rid of my awful drawings in Excel :p
Thanks a bunch!
these are steps if you would like to add it to your website, are using MySQL and phpMyAdmin, and encoding is OK as english: #1 download zip file, #2 extract, #3 upload contents to a directory on your website, #4 create a database (in cPanel for example), #5 create a database table in phpMyadmin (3 columns - col 1 called keyword, varchar(255), Default is 'None', utf8_unicode_ci; col 2 called data, mediumtext, Default is 'NULL', utf8_unicode_ci, null checkbox checked; col 3 called dt, timestamp, default is CURRENT_TIMESTAMP, attributes 'on update CURRENT_TIMESTAMP'). #6 Set the 'keyword' column as the index - not sure if this is necessary but phpMyAdmin was prompting me to set an index. (You can import the database at backend/php-mysql/database.sql into your new database if you would like to see what the database table should look like). #7 edit the file at backend/php-mysql/index.php so that the first four (4) functions match your new database settings. You should now be able to Save and Load schemas by their keyword.
you could also then password protect that directory by following this tutorial: http://css-tricks.com/easily-password-protect-a-website-or-subdirectory/
can anyone please elaborate on how i can import a database? i have managed to enable 'Save' and 'Load' as above but haven't been able to figure out how to import from a database. Say i have 'main_site_database' and 'sqldesigner_database' - can i import a database from 'main_site_database'? Which function should i be modifying in backend/php-mysql/index.php and should the connection function be defined as the one to 'sqldesigner_database' or the one to 'main_site_database'? Thank You!
Hi,
to import stuff, adjust those DEFINE fields in setup_import() in backend/php-mysql/index.php.
IMPORTANT! Do NOT change the DEFINE("DB","information_schema"); this is NOT the place for the name of database to be imported.
thank you for your reply, in chrome i get XML error: null document. in firefox, a blank grid loads, although with firebug > console on it shows '200 OK 512ms' but then also shows 'Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/ttt/public_html/ttt/backend/php-mysql/index.php on line 38'. is there any other information i can provide to assist with troubleshooting? thank you.
ps to above, as this could have something to do with my index.php and how i have set it up - a commented version of those first four functions would be really helpful eg with comments above each DEFINE field saying what should be changed and how and what shouldn't be changed - perhaps this is something that could be added to this wiki? thank you!
pps to above:
for example, the comments could be (and i don't know if these are correct, please correct if they are not):
// define your server, usually localhost
DEFINE SERVER
// define the user who has access to your wwwsqldesigner database
DEFINE USER
//define their password
DEFINE PASSWORD
// define the wwwsqldesigner database where your keywords will be saved and loaded from
DEFINE DB
// define the wwwsqldesigner database table where you keywords will be saved and loaded from
DEFINE TABLE
// define the server where you will be importing databases from, usually localhost
DEFINE SERVER
// define the user who has access to the database you wish to import
DEFINE USER
// define their password
DEFINE PASSWORD
// leave this as is - do NOT adjust this
DEFINE DB
// ================== generally you do not need to edit below this line ==================
FUNCTION CONNECT
and in case i buried my own request hehe :) i am still getting this error when trying to import db:
in chrome i get XML error: null document. in firefox, a blank grid loads, although with firebug > console on it shows '200 OK 512ms' but then also shows 'Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/ttt/public_html/ttt/backend/php-mysql/index.php on line 38'. is there any other information i can provide to assist with troubleshooting? thank you.
Ok, so i was able to install, run and save to backend "php-mysql" in a windows 7 machine. However, running on a hosting server with Linux i could not save (no error, nothing). What i did? On the "oz.js" file i commented the line 217 - "if (o.method == "POST") { xhr.setRequestHeader("Content-Type","application/x-www-form-urlencoded"); }".
Voilá!! Its working! Hope it helps for those having problems.
nice stuff. took almost 1 hour to understand how to work with. but finally succeeded. gr8 job