Tip Bank

DevX - Software Development Resource

Multidimensional Arrays and Classes

Question: I am currently writing a program that uses multidimensional arrays to store and display data items. My problem is that I cannot seem to change the array values from

DevX - Software Development Resource

Storing InitialContext in Servlet Sessions

Question: Suppose a client of a Web application logs in using a login-handler servlet, and then some back-end operations using EJBs need to be performed. Can I store the initial

DevX - Software Development Resource

Memory Allocation

Question: What is the reason that allocated memory should be explicitly deallocated ? Is there any difference in the way the data with different storage types (stack, heap, static memory)

DevX - Software Development Resource

Changing a Character’s Case

Question: Is there a function that can convert upper case to lower case and vice-versa? Answer: The toupper() and tolower() functions are declared in the standard header. Each of them

DevX - Software Development Resource

JDBC Transactions

Question: Does “Connection.setAutoCommit(false)” mean “begin a transaction?” Answer: By default, JDBC connections start in autocommit mode. This means that every executed statement is treated as a separate transaction. A transaction

DevX - Software Development Resource

ResultSet Interface

Question: If ResultSet is an interface, then why can we call methods like next(), isLast() etc. without defining the method body anywhere in the program? As I understand it, in

DevX - Software Development Resource

The MapPath method slows down execution

The Server.MapPath method slightly shows down the execution of your ASP scripts, because IIS has to access some internal variables. For this reason you should try to avoid it if

DevX - Software Development Resource

Buffering is on by default in IIS 5

You can speed up ASP by adding the following statement at the beginning of an ASP page: Response.Buffer = True This statement must be executed before any HTML text is

DevX - Software Development Resource

Use Response.IsClientConnected after long queries

When you perform a complex and time-consuming query in your ASP program, you should periodically test whether the client is still connected, using the IsClientConnected method of the Response object,