After Powersoft acquired Watcom and its famed Fortran compiler, marketing VP Tom Herring told me that the hidden jewel of the acquisition might well be a little DBMS, Watcom SQL. To put it mildly, Tom was right. Watcom SQL became SQL Anywhere; Powersoft was acquired by Sybase; Powersoft’s and Sybase’s main products both fell on hard times; Sybase built a whole mobile technology division around SQL Anywhere; and the whole thing just got sold for billions of dollars to SAP. Chris Kleisath recently briefed me on SQL Anywhere Version 12 (released to manufacturing this month), which seemed like a fine opportunity to catch up on prior developments as well.
The first two things to understand about SQL Anywhere is that there actually are three products:
Sybase SQL Anywhere, a mid-range relational DBMS.
Sybase UltraLite, a DBMS for mobile devices.
Sybase MobiLink, a replication/sync tool.
and also that there are three main deployment/use cases:
Generic desktop or server computers. This was the original market for SQL Anywhere.
Laptop/handheld computers. This was the original growth market for SQL Anywhere. In particular, Siebel Systems’ first growth spurt was selling sales force automation software on laptop computers with SQL Anywhere underneath.
Specialized devices. Earlier this decade, Sybase thought SQL Anywhere’s big growth market was on specialized devices. (I recall a video featuring some kind of automated pill dispensing machine for hospitals.)
Tuesday, July 20, 2010
My SQL and RDMBS
The Oracle and MySQL RDBMS are very different products. This makes me happy. I used to work on the Oracle RDBMS. It has a lot of features that do amazing things. Unfortunately, this also makes it extremely hard to modify. MySQL doesn't have as many features. This makes it easier to modify. This also means there are a lot of things to fix in it when you care about high-performance and high-availability OLTP workloads.But now we have a new story emerging from an independent source of news on the Oracle-Sun merger.
Sunday, June 13, 2010
Advantage of Applet
A Java applet can have any or all of the following advantages:
* it is simple to make it work on Windows, Mac OS and Linux, i.e. to make it cross platform* the same applet can work on "all" installed versions of Java at the same time, rather than just the latest plug-in version only. However, if an applet requires a later version of the JRE the client will be forced wait during the large download.* it runs in a sandbox, so the user does not need to trust the code, so it can work without security approval* it is supported by most web browsers* it will cache in most web browsers, so will be quick to load when returning to a web page* it can have full access to the machine it is running on if the user agrees* it can improve with use: after a first applet is run, the JVS is already running and starts quickly, benefiting regular users of Java* it can run at a comparable (but generally slower) speed to other compiled languages such as C++* it can be a real time application* it can move the work from the server to the client, making a web solution more scalable with the number of users/clients
* it is simple to make it work on Windows, Mac OS and Linux, i.e. to make it cross platform* the same applet can work on "all" installed versions of Java at the same time, rather than just the latest plug-in version only. However, if an applet requires a later version of the JRE the client will be forced wait during the large download.* it runs in a sandbox, so the user does not need to trust the code, so it can work without security approval* it is supported by most web browsers* it will cache in most web browsers, so will be quick to load when returning to a web page* it can have full access to the machine it is running on if the user agrees* it can improve with use: after a first applet is run, the JVS is already running and starts quickly, benefiting regular users of Java* it can run at a comparable (but generally slower) speed to other compiled languages such as C++* it can be a real time application* it can move the work from the server to the client, making a web solution more scalable with the number of users/clients
Example of using Swing
import javax.swing.JFrame;import javax.swing.JLabel;
public final class HelloWorld extends JFrame {private HelloWorld() {setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);getContentPane().add(new JLabel("Hello, World!"));pack();setLocationRelativeTo(null);}
public static void main(String[] args) {new HelloWorld().setVisible(true);}}
public final class HelloWorld extends JFrame {private HelloWorld() {setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);getContentPane().add(new JLabel("Hello, World!"));pack();setLocationRelativeTo(null);}
public static void main(String[] args) {new HelloWorld().setVisible(true);}}
Saturday, June 12, 2010
Calendar sample code
import java.util.Date;import java.util.Calendar;import java.text.SimpleDateFormat;import java.util.*;
public class CalendarExample {private static void prt(String s) { System.out.println(s); }
private static void prt() { System.out.println(); }
private static void doCalendarTimeExample() { prt("CURRENT DATE/TIME"); prt("================================================================="); Date now = Calendar.getInstance().getTime(); prt(" Calendar.getInstance().getTime() : " + now); prt(); }private static void doSimpleDateFormat() { prt("SIMPLE DATE FORMAT"); prt("=================================================================");
Calendar now = Calendar.getInstance(); SimpleDateFormat formatter = new SimpleDateFormat("E yyyy.MM.dd 'at' hh:mm:ss a zzz"); prt(" It is now : " + formatter.format(now.getTime())); prt(); }private static void doAdd() {
prt("ADD / SUBTRACT CALENDAR / DATEs"); prt("=================================================================");
Calendar now = Calendar.getInstance(); Calendar working; SimpleDateFormat formatter = new SimpleDateFormat("E yyyy.MM.dd 'at' hh:mm:ss a zzz");
working = (Calendar) now.clone(); working.add(Calendar.DAY_OF_YEAR, - (365 * 2)); prt(" Two years ago it was: " + formatter.format(working.getTime()));
working = (Calendar) now.clone(); working.add(Calendar.DAY_OF_YEAR, + 5); prt(" In five days it will be: " + formatter.format(working.getTime()));
prt();
}
private static void doDateDifference() { prt("DIFFERENCE BETWEEN TWO DATES"); prt("================================================================="); Date startDate1 = new GregorianCalendar(1994, 02, 14, 14, 00).getTime(); Date endDate1 = new Date();;
long diff = endDate1.getTime() - startDate1.getTime();
prt(" Difference between " + endDate1); prt(" and " + startDate1 + " is " + (diff / (1000L*60L*60L*24L)) + " days."); prt();
}
private static void doGetMethods() {
prt("CALENDAR GET METHODS"); prt("================================================================="); Calendar c = Calendar.getInstance();
prt(" YEAR : " + c.get(Calendar.YEAR)); prt(" MONTH : " + c.get(Calendar.MONTH)); prt(" DAY_OF_MONTH : " + c.get(Calendar.DAY_OF_MONTH)); prt(" DAY_OF_WEEK : " + c.get(Calendar.DAY_OF_WEEK)); prt(" DAY_OF_YEAR : " + c.get(Calendar.DAY_OF_YEAR)); prt(" WEEK_OF_YEAR : " + c.get(Calendar.WEEK_OF_YEAR)); prt(" WEEK_OF_MONTH : " + c.get(Calendar.WEEK_OF_MONTH)); prt(" DAY_OF_WEEK_IN_MONTH : " + c.get(Calendar.DAY_OF_WEEK_IN_MONTH)); prt(" HOUR : " + c.get(Calendar.HOUR)); prt(" AM_PM : " + c.get(Calendar.AM_PM)); prt(" HOUR_OF_DAY (24-hour): " + c.get(Calendar.HOUR_OF_DAY)); prt(" MINUTE : " + c.get(Calendar.MINUTE)); prt(" SECOND : " + c.get(Calendar.SECOND)); prt();
}
public static void main(String[] args) { prt(); doCalendarTimeExample(); doSimpleDateFormat(); doAdd(); doDateDifference(); doGetMethods(); }
}
Management of Database
Although all the database administrative options can be done through PHP scripts, I strongly suggest installing a copy of PHPMyAdmin on your server. It is an excellent free set of scripts that will provide you with an administrative interface for your MySQL database(s). You can add, remove, edit, backup and view your databases using this and it is especially useful when troubleshooting your databases.This TutorialThroughout this tutorial I will be showing you some of the basics of using PHP and MySQL together. To do this I will be using an example all the way through. As you use this tutorial, you will learn how to create a web based contact management program. It will allow you to store names with their addresses, e-mail and phone numbers. You will be able to update records and search the database. There will even be an option which allows you to send an e-mail out to all the people in the database (please note: this system should not be used for Spam or unsolicited e-mail).
Importance if Database
It is actually surprising how useful a database can be when used with a website. There are a huge variety of things you can do when you interact the two, from displaying simple lists to running a complete website from a database. Some examples of PHP and MySQL being used together are:
Banner Rotation. On this site, where each banner is, a PHP script is called. This opens a database and picks a random banner from it to show the visitor. It also counts the number of times the banner has been viewed and could, with a few changes, track clicks too. To add, change or edit the banners all I have to do is change the database and the script will pick the correct banners for all the pages on the site.
Forums. Hundreds of forums (message boards) on the Internet are run using PHP and MySQL. These are much more efficient than other systems that create a page for each message and offer a wide variety of options. All the pages in the forum can be updated by changing one script.
Databases. One quite obvious example is sites, which get all there information from a database. For example Script Avenue is run by a few scripts, which gain all their information from a large database. All the different script categories can be accessed in one script by just changing the URL to access a different part of the database.
Websites. If you have a large website and you want to change the design it can take a very long time to update and upload all the pages. With PHP and MySQL your whole website could be just one or two PHP scripts. These would access a MySQL database to get the information for the pages. To update the website's design you would just have to change one page.
(1) To make database easier to use and manage the data.
(2) To work priperly with timely and fastly and correctly.
Banner Rotation. On this site, where each banner is, a PHP script is called. This opens a database and picks a random banner from it to show the visitor. It also counts the number of times the banner has been viewed and could, with a few changes, track clicks too. To add, change or edit the banners all I have to do is change the database and the script will pick the correct banners for all the pages on the site.
Forums. Hundreds of forums (message boards) on the Internet are run using PHP and MySQL. These are much more efficient than other systems that create a page for each message and offer a wide variety of options. All the pages in the forum can be updated by changing one script.
Databases. One quite obvious example is sites, which get all there information from a database. For example Script Avenue is run by a few scripts, which gain all their information from a large database. All the different script categories can be accessed in one script by just changing the URL to access a different part of the database.
Websites. If you have a large website and you want to change the design it can take a very long time to update and upload all the pages. With PHP and MySQL your whole website could be just one or two PHP scripts. These would access a MySQL database to get the information for the pages. To update the website's design you would just have to change one page.
(1) To make database easier to use and manage the data.
(2) To work priperly with timely and fastly and correctly.
Subscribe to:
Posts (Atom)