Showing posts with label database. Show all posts
Showing posts with label database. Show all posts
Tuesday, February 16, 2016
GoDaddy MySQL Server changes
I have been hosting one of my website at GoDaddy for a long time (too long that I couldn't remember) and I setup my own instance of WordPress 1.5 back then (now it's a feature of GoDaddy web hosting and it's so much easier) and I seldom make any change unless it's broken. I visited my site just now and got a helpful error message saying WordPress cannot connect to the database (I used a host name in the secureserver.net domain) And I (re)discovered where the db server name was stored: it's wp-config.php. So I opened the database manager from GoDaddy to figure out the IP address of the db server and replace the one in wp-config.php. Voila! My site is back.
Friday, January 15, 2016
Time series database
Most application developers are probably familiar with good old relational databases (Yes, I am a certified Oracle DBA) as well as the new breed of NoSQL database like MongoDB. I deal with quite a bit of metric data at work, which is time-based. I have been playing with InfluxDB which is optimized for such data and is part of a TICK stack for collecting, managing and visualizing time series data. Compared to Oracle and SQL Server, installing InfluxDB is a piece of cake: just do a yum install, then start it and it's ready for inserting data! To interact with it, it has a command-line interface, influx, just like Oracle has SQLPlus. Programmatically, all you need to do is making use of its HTTP API: 'get' to query and 'post' to insert. No complicated database driver configurations. Of course, you could use one of the available client library for your language to make things even easier. My next step would be trying to time the queries using something like Influx-cli to evaluate its performance.
Thursday, July 31, 2014
Using Oracle SQL Developer with MySQL database
I have been using the free Oracle SQL Developer as my main "alternative" to the text-based SQL Plus client for a while. I have used TOAD before. My co-w's favorite was Golden32. Even though I work with the database quite a bit, I am actually not too picky about what client to use. After all, there are times I have to get on to the database server itself and use SQL Plus. Any GUI is a luxury compared to that. Recently I needed to work on a MySQL database so I wonder if I could "re-use" SQL Developer. I didn't have high-hope to begin with (the alternative would have been the free MySQL Workbench from MySQL.) After all, it's from Oracle and might work with Oracle DB only. MySQL was acquired by Sun which was acquired by Oracle though. It turns out Oracle SQL Developer does work with MySQL (since 2007) I learned from this page that all it takes is opening Tools > Preferences > Databases and there is a third party JDBC driver. Simply add the MySQL Connector JAR. I also opened Help > Check for updates and get the MySQL related update. Not sure if it's really necessary. These links (1,2) did not mention this step.
Another MySQL tip I learned today was how to limit the number of rows it queries. In M$ SQL Server, you simply add TOP [N] after SELECT. For MySQL, it's adding LIMIT [N] at the end.
Subscribe to:
Posts (Atom)