6 messages in com.mysql.lists.plusplusHow to overcome a runtime error when ...
FromSent OnAttachments
Bassam A. Al-Khaffaf25 Feb 2007 16:51 
Warren Young26 Feb 2007 19:53 
Bassam A. Al-Khaffaf27 Feb 2007 00:26 
Warren Young27 Feb 2007 01:14 
Bassam A. Al-Khaffaf27 Feb 2007 01:58 
Warren Young28 Feb 2007 05:04 
Subject:How to overcome a runtime error when there is no matching in database
From:Bassam A. Al-Khaffaf (bas@palettemm.com)
Date:02/25/2007 04:51:30 PM
List:com.mysql.lists.plusplus

Dear All,

Using win32 C++ with MySQL++ 2.2.0. I am trying to query my data base using SSQLS. I am successfully retrieving the information from my database using the following command:

Cout << attributesList.lower_bound(_ATTRIBUTES_LIST(attribute_id, vendor_id))->attribute_name << endl;

However, I am getting a runtime error when there is no (attribute_id, vendor_id) matching in my database so how can I control or overcome this error.

For example, if there is nothing returned, a NULL or “no match found” message could be show up.

Regards

Bassam