|
Home > Archive > SQL Anywhere ultralite > September 2005 > GetColumnID returns duplicate indexes
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
GetColumnID returns duplicate indexes
|
|
| Timothy Dean 2005-09-09, 8:23 pm |
| Ultralite component C++ api 9.0.2.3182
The following code returns the same column index:
CString strFieldName1="VacPressRdg_Date";
CString strFieldName1="VacPressRdg_Time";
ULValue ulvalue1;
ULValue ulvalue2;
ulvalue1. SetString(strFieldNa
me1);
ulvalue2. SetString(strFieldNa
me2);
ul_column_num columnID1=m_pResultS
etSchema-> GetColumnID(ulValue1
);
ul_column_num columnID2=m_pResultS
etSchema-> GetColumnID(ulValue2
);
columnID1 and columnID2 return the same column index even though they are
different fields. If I "walk" the result set schema and search for the
column id that way, I get the proper values.
This was all working fine until I upgraded from 9.0.2.3044 to 9.0.2.3169. I
upgraded today to 3182 and I still have the same problem. Any ideas?
Thanks.
Timothy Dean
| |
| Usmanov A. 2005-09-10, 3:23 am |
| Look in your code:
CString strFieldName1 (!!!) ="VacPressRdg_Date";
CString strFieldName1 (!!!) ="VacPressRdg_Time"; - Is it misprint?
Alex Usmanov.
"Timothy Dean" <tim. dean@mobiledataforce
.com> сообщил/сообщила в новостях
следующее: news:43220dc9$1@foru
ms-1-dub...
> Ultralite component C++ api 9.0.2.3182
>
> The following code returns the same column index:
>
> CString strFieldName1="VacPressRdg_Date";
> CString strFieldName1="VacPressRdg_Time";
>
> ULValue ulvalue1;
> ULValue ulvalue2;
> ulvalue1. SetString(strFieldNa
me1);
> ulvalue2. SetString(strFieldNa
me2);
>
> ul_column_num columnID1=m_pResultS
etSchema-> GetColumnID(ulValue1
);
> ul_column_num columnID2=m_pResultS
etSchema-> GetColumnID(ulValue2
);
>
> columnID1 and columnID2 return the same column index even though they are
> different fields. If I "walk" the result set schema and search for the
> column id that way, I get the proper values.
>
> This was all working fine until I upgraded from 9.0.2.3044 to 9.0.2.3169.
I
> upgraded today to 3182 and I still have the same problem. Any ideas?
> Thanks.
>
> Timothy Dean
>
>
| |
| Timothy Dean 2005-09-12, 11:23 am |
| This is a typo in my message. It should be:
CString strFieldName1="VacPressRdg_Date";
CString strFieldName2="VacPressRdg_Time";
Has anyone else run into this recent problem? It has been working fine for
quite a while in my code until the recent update to 3169. It could be a
problem with ULValue or ResultSet.GetColumnID, I am not sure. If I use the
column indexes directly, it works fine. Thanks.
Timothy Dean
"Usmanov A." <alex_u@pochtamt.ru> wrote in message
news:432288b5$1@foru
ms-1-dub...
> Look in your code:
> CString strFieldName1 (!!!) ="VacPressRdg_Date";
> CString strFieldName1 (!!!) ="VacPressRdg_Time"; - Is it misprint?
>
> Alex Usmanov.
>
> "Timothy Dean" <tim. dean@mobiledataforce
.com> сообщил/сообщила в новостях
> следующее: news:43220dc9$1@foru
ms-1-dub...
are[color=darkred]
9.0.2.3169.[color=darkred]
> I
>
>
| |
| Michael Thode 2005-09-13, 3:23 am |
| Could you post the query you we're executing. Does this occur with every
query or just this one?
Mike
"Timothy Dean" <tim. dean@mobiledataforce
.com> wrote in message
news:43259621$1@foru
ms-2-dub...
> This is a typo in my message. It should be:
>
> CString strFieldName1="VacPressRdg_Date";
> CString strFieldName2="VacPressRdg_Time";
>
> Has anyone else run into this recent problem? It has been working fine
for
> quite a while in my code until the recent update to 3169. It could be a
> problem with ULValue or ResultSet.GetColumnID, I am not sure. If I use
the
> column indexes directly, it works fine. Thanks.
>
> Timothy Dean
>
>
>
> "Usmanov A." <alex_u@pochtamt.ru> wrote in message
> news:432288b5$1@foru
ms-1-dub...
новостях[color=darkr
ed]
> are
the[color=darkred]
> 9.0.2.3169.
>
>
| |
| Timothy Dean 2005-09-13, 11:23 am |
| Here is an example query that causes the problem:
SELECT Site_ID, DATEFORMAT(VacPressR
dg_Date,'m/dd/yy') AS VacPressRdg_Date,
DATEFORMAT(VacPressR
dg_Time,'hh:nn') AS TimeVacPressRdg_Time
,
ROUND(VacPressRdg,3)
as VacPressRdg, Unit as VacPressRdg_Unit
FROM tblVacPressRdg vpr, tblUnits u
WHERE (Site_id like ? OR Site_id like ?)
AND VacPressRdg_Unit_ID = Unit_ID
ORDER BY VacPressRdg_Date DESC, TimeVacPressRdg_Time
DESC
Tim
"Michael Thode" < mthode_no_spam@sybas
e.com> wrote in message
news:432635b8$1@foru
ms-1-dub...
> Could you post the query you we're executing. Does this occur with every
> query or just this one?
>
> Mike
>
> "Timothy Dean" <tim. dean@mobiledataforce
.com> wrote in message
> news:43259621$1@foru
ms-2-dub...
> for
> the
> новостях
they[color=darkred]
> the
ideas?[color=darkred]
>
>
|
|
|
|
|