|
-
June 5th, 2009, 03:43 AM
#1
Recordset GetFieldValue for list values
Hello All,
this is my first post here, but I tried several things before posting here...
Here is my problem :
I'm reading different tables inside an Access Database (I'm more used to SQL...), and for some specific fields, i'm getting strange readings...
here is the code :
"CString csRequete;
CDaoRecordset recordset2(&database);
COleVariant l_vProcedure;
csRequete.Format("SELECT * FROM [LB Analysis Profiles] WHERE [LB Analysis Profile Key] = %d",l_vAnalysisProfile.intVal);
recordset2.Open(AFX_DAO_USE_DEFAULT_TYPE,csRequete.GetBuffer(), 0);
recordset2.MoveFirst();
l_vProcedure = recordset2.GetFieldValue(17);
csProcedure = l_vProcedure.bstrVal;"
The problem is that I am getting Chinese symbols in the BSTR of l_vProcedure, or invalid characters...
the field is a text type containing "FILTRE", and that's what I should read...
This functions are working fine on others tables, or for some numerical value...
Do you have any idea what can be happening?
Thanks on advance
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|