devxlogo

Tip Bank

Calling the CD-Rom

Question: I would like to know how to call the CD-Rom, or rather search for its drive letter. Answer: You can use the FileSystemObject (Microsoft Scripting Runtime in the references

The binary_search Algorithm

STL’s binary_search() algorithm traverses a sequence and returns a Boolean value indicating whether the sought-after element exists in that sequence. binary_search() is declared in the header as follows: bool binary_search

Useful STL Terminology

Here are some key terms that you may find useful for reading Standard Template Library (STL) literature and documentation. ContainerA container is an object that stores objects as its elements.

Blocking Object Copying and Assignment

To block copying and assignment of an object, explicitly declare the assignment operator and copy constructor private. Don’t define them, (there’s no point in defining them because they can’t be

Querying Date Fields

Question: I have a table with column called Date, which stores date record, that was entered in smalldatetime format (e.g., 2000-06-01 00:00:00). I need to write a stored procedure that