Sybase T-SQL: How to use Cursors in your Stored Procedures

A Cursor is a database structure that allows for the traversal of the records in a result set. In Sybase T-SQL a cursor functions by the following steps: Declare the Cursor: To use a cursor you first must declare it by providing a name and the SELECT query that will provide the result set it

Code Snippets: Left and Right Joins in WHERE statment of SQL Query

SQL Queries can often be written in multiple ways to obtain the same end result set. Tables for instance can be joined in the FROM clause or the WHERE clause of a SQL Statement. In the FROM Clause we can utilize LEFT, RIGHT, INNER keywords to denote if both sides of the statement needs to

What is the difference between: em vs i, and strong vs bold

Often when working on multiple projects and in various frameworks I find that the <em> and <i> tags in addition to <strong> and <bold> are used interchangeably.  After much confusion I finally went and looked up why both of these tags exists. As it turns out the <i> and <b> tags were created to denote

Code Snippets: Opening a new window from JavaScript across all browsers

Much to every developers pain we often find that JavaScript that is functional in one browser is not functional in other browsers.  Recently the update to Safari 3 requrired that the window open command to not contain the url. As it would fail to open a window if it did, the simple fix was to

Code Snippets: Java Calendar – How to get the last day of the Month

The Java Calendar class provides many helpful methods for modifying Date objects. Here you will find a short code snippet for obtaining the last day of the month. To utilize the code please don’t forget to import the java.util.Calendar class or which ever Calendar you utilize. How the snippet works is it utilizes the getActualMaximum

Code Snippet: How to submit and reset a Form using JavaScript

The standard approach to submit a form is through the use of the submit button. However we may find that we may want to utilize an image, text link or other elements to submit a form. In these cases we can utilize JavaScript to submit the form for us through the use of the JavaScript

Tips & Tricks: Ignoring folders and file types with Subversion

Subversion (SVN) is a popular version control system used by developers. Often a developer will find that they have folders or files within their project that they do not want to have saved and versioned. To accomplish this svn provides the ignore property which can be set to tell what not to include. How to

Code Snippets: How to set id property using Struts HTML Tag library

For those new to Struts and in particular the Struts HTML library it might come as a surprise that there is no id property on their tags. Don’t get frustrated the tag library document clearly states that the styleId property renders its assigned value as the element id. This means that instead of id use

Tutorial: How to send email from a Java Application – via a Server requiring Authentication

In the previous tutorial we walked through how to send email from a Java Application. This tutorial extends off that and explains how to send email from a SMTP server that requires  basic User Authentication in the form of a user name and password.  This is performed by use of the Authenticator object. Prerequisites This

// Java //
Read More

Tutorial: How to send email from a Java Application

Sending email from your java application is very straightforward when you utilize the JavaMail API.  This library contains all the functionality necessary to connect to a SMTP Mail Server and send your email to its desired recipients.  The next time you have an application performing some vital functionality instead of just logging an exception send

// Java //
Read More