The Latest

DevX - Software Development Resource

Determining Stack Content Type

Question: Only Objects can be popped from, or push onto, a stack. That means Ihave to wrap a primitive data type, such as int, with something akin toInteger before pushing

DevX - Software Development Resource

Switching Between Frames

Question: I’m building an application that has several different frames. Eachhas a button that when pressed should bring up a new frame and closethe calling frame. How can I display

DevX - Software Development Resource

Package Protected Constructor

Question: I need to extend class A which resides in a different package, butclass A has only one constructor which is package protected. I get a compile error in class

DevX - Software Development Resource

Random Integer Generation

Question: How do I write a Java program that generates random numbers withinlimits, such as 1 to 100, or 1 to 1000? Answer: The java.util package includes a Random class

DevX - Software Development Resource

Interplatform Networking

Question: I want to connect a Java client program to a C/C++ server applicationusing sockets. What is the easiest way of doing this? Answer: Java provides the ability to write

DevX - Software Development Resource

Stopping Threads

Question: How do you stop a Thread without using the stop() method? Answer: The recommended method for stopping threads in Java is for each thread topoll a boolean value or

DevX - Software Development Resource

Vectors vs. Hashtables

Question: Is there a significant speed advantage to using Hashtables over Vectors? Answer: The answer depends on how you are using those containers classes. Ifyou are only using them for

DevX - Software Development Resource

Invoking C++ Code (or DLL) via Trigger

Question: Is it possible to have a trigger invoke code in a running application (either via a register-notify type of thing or by calling entry points of a DLL or…)?

DevX - Software Development Resource

Setting Default Values

Question: How do I set a default for a date field having sysdate, current_date or date as the value? Answer: To use the current date as a default value in

DevX - Software Development Resource

Altering the Substitution Character in SQL*Plus

When you are inserting data into Oracle tables in SQL*Plus using hard-coded string, some of the character fields may contain the ampersand character (&). The following is an example: insert

DevX - Software Development Resource

Indexing Foreign Key Columns in Child Tables

Although an index is not mandatory on your foreign keys, if they are not indexed you will cause additional locking when certain Data Manipulation Language statements are executed against the

DevX - Software Development Resource

Pre-Compiled Database Triggers

Many programmers create stored procedures out of large bodies of database trigger codes. This has primarily been because while stored procedures are stored in compiled form, database triggers are compiled

DevX - Software Development Resource

Enhanced Parameter Passing in Oracle8i

PL/SQL supports three parameter-passing modes: IN Related Posts Detach from a Docker Container and Leave it RunningRevolutionary Algorithm Transforms Crop MonitoringPrice of Saving Earth: NY Residents Pay MoreAutoplay an Audio

DevX - Software Development Resource

View SQL Behind System Stored Procedures

If you are ever trying to write SQL to access SQL server’s system tables, it is often useful to look at SQL Server’s own system stored procedures. You can do

DevX - Software Development Resource

Meanings of RS232 Signals

Question: Can you explain the interaction of the RS232 signals (RTS, CTS, DTR, etc.). I need to write a software utility to transmit and receive characters between two computers, but

DevX - Software Development Resource

Using Where on Fields of Differing Types

Question: I need to extract information using WHERE on fields in two different tables: one a text field, the other a numeric field. Both hold only numeric data. How can

DevX - Software Development Resource

Problem with Select Statement

Question: I’m writing a select statement to make a table name a variable whose value is set according to a condition: Var tablename;tablename := emp tableselect * from tablename; But

DevX - Software Development Resource

Finding Out if a User Has Disabled Cookies

Question: How do I find out if a user has disabled cookies? Answer: To find out if a user has disabled cookies, follow these steps: Set a cookie. Redirect to

DevX - Software Development Resource

Informix Data Types for Linking Images

Question: Does Informix have a data type similiar to SQL Server’s image or ntext to input paths to link images? Answer: I’d use a CHAR(25) or a VARCHAR field for

DevX - Software Development Resource

Effects of Operator delete

Question: Why, after deleting an object I allocated dynamically, is the pointer still there? What exactly have I deleted and what would happen if I assigned a new value to

DevX - Software Development Resource

WAP IP Address

Question: Does WAP have a concept of IP address? Answer: You can get the gateway IP address and the terminal IP address using HTTP headers. WAP 1.1 currently has no

DevX - Software Development Resource

Percent Sign in SQL

Question: I have a table in which the key field has a value stored with a percent sign, like ‘1234%’.Using this value, I want to select from another table that

DevX - Software Development Resource

ESQL/C (9.2) UC3 Errors

Question: I have installed the version 9.2 of ESQLC, and when I try to run the program in the following manner: esql -e crdb.ec cc -c -I/home/informix/incl/esql crdb.c cc -ocrdb7.exe

DevX - Software Development Resource

Concatenating Fields

Question: How do I concatenate a value in Stored Procedures (e.g., select * from mytable, where mytable.field1 = field that I concatenate)? Answer: If you want to match field1 to

DevX - Software Development Resource

Constructors – Derived to Base

Question: My base class contains this constructor: class Parent { Parent(int a, int b, char* c);}; My derived class contains this constructor: class Child : public Parent { Child(int a);};

DevX - Software Development Resource

Manual Redirection of URL

Instead of using a META tag to re-direct a URL, simply place this code in place of the old page and a visitor will instantly be taken there. This piece