Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

oledb with MS Visual C++ 6

6 posts in OLEDB Last posting was on 2005-12-05 22:26:29.0Z
Col Posted on 2005-12-02 04:56:36.0Z
From: "Col" <usesmob@hotmail.com>
Newsgroups: Advantage.OLEDB
Subject: oledb with MS Visual C++ 6
Date: Fri, 2 Dec 2005 14:56:36 +1000
Lines: 22
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2670
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 203.31.246.6
Message-ID: <438fd354@solutions.advantagedatabase.com>
X-Trace: 1 Dec 2005 21:53:40 -0700, 203.31.246.6
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!203.31.246.6
Xref: solutions.advantagedatabase.com Advantage.OLEDB:1129
Article PK: 1133652

Hi all,

I built a small MSVC++ app to access a dbf (cdx)

char CnnStr[200]="Provider=Advantage OLE DB Provider; Data
Source=J:\\DTA\\TEMP\\TEST; ServerType=ADS_REMOTE_SERVER;
TableType=ADS_CDX;";

The code compiles and links OK but whenever I try to run it it sends a
message to Microsoft instead.

The same basic code with sqlserver CnnStr works fine.
char CnnStr[200]="Provider=SQLOLEDB;Trusted_Connection=yes;DRIVER={SQL
Server};SERVER=DBSQLS;DATABASE=Pubs;";.

Is there any help available for MSVC++6?

Regards

Colin


"Lee Stigile" <lees Posted on 2005-12-02 16:07:54.0Z
From: "Lee Stigile" <lees@nospam_extendsys.com>
Newsgroups: Advantage.OLEDB
References: <438fd354@solutions.advantagedatabase.com>
Subject: Re: oledb with MS Visual C++ 6
Date: Fri, 2 Dec 2005 09:07:54 -0700
Lines: 31
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 192.168.30.153
Message-ID: <439070ab@solutions.advantagedatabase.com>
X-Trace: 2 Dec 2005 09:04:59 -0700, 192.168.30.153
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!192.168.30.153
Xref: solutions.advantagedatabase.com Advantage.OLEDB:1130
Article PK: 1133651

What's the error message?

Thanks
Lee

"Col" <usesmob@hotmail.com> wrote in message
news:438fd354@solutions.advantagedatabase.com...
> Hi all,
>
> I built a small MSVC++ app to access a dbf (cdx)
>
> char CnnStr[200]="Provider=Advantage OLE DB Provider; Data
> Source=J:\\DTA\\TEMP\\TEST; ServerType=ADS_REMOTE_SERVER;
> TableType=ADS_CDX;";
>
> The code compiles and links OK but whenever I try to run it it sends a
> message to Microsoft instead.
>
> The same basic code with sqlserver CnnStr works fine.
> char CnnStr[200]="Provider=SQLOLEDB;Trusted_Connection=yes;DRIVER={SQL
> Server};SERVER=DBSQLS;DATABASE=Pubs;";.
>
> Is there any help available for MSVC++6?
>
> Regards
>
> Colin
>


Col Posted on 2005-12-05 20:41:28.0Z
From: "Col" <usesmob@hotmail.com>
Newsgroups: Advantage.OLEDB
References: <438fd354@solutions.advantagedatabase.com> <439070ab@solutions.advantagedatabase.com>
Subject: Re: oledb with MS Visual C++ 6
Date: Tue, 6 Dec 2005 06:41:28 +1000
Lines: 49
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2670
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 203.31.246.6
Message-ID: <4394a562@solutions.advantagedatabase.com>
X-Trace: 5 Dec 2005 13:38:58 -0700, 203.31.246.6
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!203.31.246.6
Xref: solutions.advantagedatabase.com Advantage.OLEDB:1131
Article PK: 1133654

Hi Lee,

In the error report contents there is a
Code: 0xc0000005
Flags: 0x00000000
Record: 0x000000000000000
Address: 0x0000000077c47fd4
This indicates an access violation but I already have all permissions
required to access the tables.

Regards

Colin

"Lee Stigile" <lees@nospam_extendsys.com> wrote in message
news:439070ab@solutions.advantagedatabase.com...
> What's the error message?
>
> Thanks
> Lee
>
>
> "Col" <usesmob@hotmail.com> wrote in message
> news:438fd354@solutions.advantagedatabase.com...
>> Hi all,
>>
>> I built a small MSVC++ app to access a dbf (cdx)
>>
>> char CnnStr[200]="Provider=Advantage OLE DB Provider; Data
>> Source=J:\\DTA\\TEMP\\TEST; ServerType=ADS_REMOTE_SERVER;
>> TableType=ADS_CDX;";
>>
>> The code compiles and links OK but whenever I try to run it it sends a
>> message to Microsoft instead.
>>
>> The same basic code with sqlserver CnnStr works fine.
>> char CnnStr[200]="Provider=SQLOLEDB;Trusted_Connection=yes;DRIVER={SQL
>> Server};SERVER=DBSQLS;DATABASE=Pubs;";.
>>
>> Is there any help available for MSVC++6?
>>
>> Regards
>>
>> Colin
>>
>
>


"Lee Stigile" <lees Posted on 2005-12-05 21:10:31.0Z
From: "Lee Stigile" <lees@nospam_extendsys.com>
Newsgroups: Advantage.OLEDB
References: <438fd354@solutions.advantagedatabase.com> <439070ab@solutions.advantagedatabase.com> <4394a562@solutions.advantagedatabase.com>
Subject: Re: oledb with MS Visual C++ 6
Date: Mon, 5 Dec 2005 14:10:31 -0700
Lines: 58
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 192.168.30.153
Message-ID: <4394ac17@solutions.advantagedatabase.com>
X-Trace: 5 Dec 2005 14:07:35 -0700, 192.168.30.153
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!192.168.30.153
Xref: solutions.advantagedatabase.com Advantage.OLEDB:1132
Article PK: 1133653

Is the error on the table open or on the connection? If the table open,
check the ads_err.dbf
-Lee

"Col" <usesmob@hotmail.com> wrote in message
news:4394a562@solutions.advantagedatabase.com...
> Hi Lee,
>
> In the error report contents there is a
> Code: 0xc0000005
> Flags: 0x00000000
> Record: 0x000000000000000
> Address: 0x0000000077c47fd4
> This indicates an access violation but I already have all permissions
> required to access the tables.
>
> Regards
>
> Colin
>
> "Lee Stigile" <lees@nospam_extendsys.com> wrote in message
> news:439070ab@solutions.advantagedatabase.com...
>> What's the error message?
>>
>> Thanks
>> Lee
>>
>>
>> "Col" <usesmob@hotmail.com> wrote in message
>> news:438fd354@solutions.advantagedatabase.com...
>>> Hi all,
>>>
>>> I built a small MSVC++ app to access a dbf (cdx)
>>>
>>> char CnnStr[200]="Provider=Advantage OLE DB Provider; Data
>>> Source=J:\\DTA\\TEMP\\TEST; ServerType=ADS_REMOTE_SERVER;
>>> TableType=ADS_CDX;";
>>>
>>> The code compiles and links OK but whenever I try to run it it sends a
>>> message to Microsoft instead.
>>>
>>> The same basic code with sqlserver CnnStr works fine.
>>> char CnnStr[200]="Provider=SQLOLEDB;Trusted_Connection=yes;DRIVER={SQL
>>> Server};SERVER=DBSQLS;DATABASE=Pubs;";.
>>>
>>> Is there any help available for MSVC++6?
>>>
>>> Regards
>>>
>>> Colin
>>>
>>
>>
>
>


Col Posted on 2005-12-05 21:34:24.0Z
From: "Col" <usesmob@hotmail.com>
Newsgroups: Advantage.OLEDB
References: <438fd354@solutions.advantagedatabase.com> <439070ab@solutions.advantagedatabase.com> <4394a562@solutions.advantagedatabase.com> <4394ac17@solutions.advantagedatabase.com>
Subject: Re: oledb with MS Visual C++ 6
Date: Tue, 6 Dec 2005 07:34:24 +1000
Lines: 86
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2670
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 203.31.246.6
Message-ID: <4394b1ca@solutions.advantagedatabase.com>
X-Trace: 5 Dec 2005 14:31:54 -0700, 203.31.246.6
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!203.31.246.6
Xref: solutions.advantagedatabase.com Advantage.OLEDB:1133
Article PK: 1133655

Hi Lee
The error appears to be on the connection.
I saved a copy of the dmp file.
*extract from dmp

// Construct a Data_t from a const wchar_t*

inline _bstr_t::Data_t::Data_t(const wchar_t* s) throw(_com_error)
: m_str(NULL), m_RefCount(1)
{
m_wstr = ::SysAllocString(s); <*******************the dmp file
stops here in COMUTIL.H****
if (m_wstr == NULL && s != NULL) {
_com_issue_error(E_OUTOFMEMORY);
}
}


*end extract

Regards

Colin

"Lee Stigile" <lees@nospam_extendsys.com> wrote in message
news:4394ac17@solutions.advantagedatabase.com...
> Is the error on the table open or on the connection? If the table open,
> check the ads_err.dbf
> -Lee
>
>
> "Col" <usesmob@hotmail.com> wrote in message
> news:4394a562@solutions.advantagedatabase.com...
>> Hi Lee,
>>
>> In the error report contents there is a
>> Code: 0xc0000005
>> Flags: 0x00000000
>> Record: 0x000000000000000
>> Address: 0x0000000077c47fd4
>> This indicates an access violation but I already have all permissions
>> required to access the tables.
>>
>> Regards
>>
>> Colin
>>
>> "Lee Stigile" <lees@nospam_extendsys.com> wrote in message
>> news:439070ab@solutions.advantagedatabase.com...
>>> What's the error message?
>>>
>>> Thanks
>>> Lee
>>>
>>>
>>> "Col" <usesmob@hotmail.com> wrote in message
>>> news:438fd354@solutions.advantagedatabase.com...
>>>> Hi all,
>>>>
>>>> I built a small MSVC++ app to access a dbf (cdx)
>>>>
>>>> char CnnStr[200]="Provider=Advantage OLE DB Provider; Data
>>>> Source=J:\\DTA\\TEMP\\TEST; ServerType=ADS_REMOTE_SERVER;
>>>> TableType=ADS_CDX;";
>>>>
>>>> The code compiles and links OK but whenever I try to run it it sends a
>>>> message to Microsoft instead.
>>>>
>>>> The same basic code with sqlserver CnnStr works fine.
>>>> char CnnStr[200]="Provider=SQLOLEDB;Trusted_Connection=yes;DRIVER={SQL
>>>> Server};SERVER=DBSQLS;DATABASE=Pubs;";.
>>>>
>>>> Is there any help available for MSVC++6?
>>>>
>>>> Regards
>>>>
>>>> Colin
>>>>
>>>
>>>
>>
>>
>
>


Col Posted on 2005-12-05 22:26:29.0Z
From: "Col" <usesmob@hotmail.com>
Newsgroups: Advantage.OLEDB
References: <438fd354@solutions.advantagedatabase.com> <439070ab@solutions.advantagedatabase.com> <4394a562@solutions.advantagedatabase.com> <4394ac17@solutions.advantagedatabase.com>
Subject: Re: oledb with MS Visual C++ 6
Date: Tue, 6 Dec 2005 08:26:29 +1000
Lines: 83
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2670
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670
X-RFC2646: Format=Flowed; Response
NNTP-Posting-Host: 203.31.246.6
Message-ID: <4394bdff@solutions.advantagedatabase.com>
X-Trace: 5 Dec 2005 15:23:59 -0700, 203.31.246.6
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!203.31.246.6
Xref: solutions.advantagedatabase.com Advantage.OLEDB:1134
Article PK: 1133657

Hi Lee,

Thanks for your help. The program is making the connection OK
It is reading text fields OK, date fields as garbage and falls over reading
numeric fields.

if(tbl.Get("CUSTNO",id)){ *****************Falls over here (id is char[100]
and CUSTNO is numeric.
strcpy(strPH,(id)); * Get
returns a link error if I use a long for id).
}
else
{
tbl.GetErrorErrStr(ErrStr);
MessageBox(ErrStr);
break;
}
Regards

Colin

"Lee Stigile" <lees@nospam_extendsys.com> wrote in message
news:4394ac17@solutions.advantagedatabase.com...
> Is the error on the table open or on the connection? If the table open,
> check the ads_err.dbf
> -Lee
>
>
> "Col" <usesmob@hotmail.com> wrote in message
> news:4394a562@solutions.advantagedatabase.com...
>> Hi Lee,
>>
>> In the error report contents there is a
>> Code: 0xc0000005
>> Flags: 0x00000000
>> Record: 0x000000000000000
>> Address: 0x0000000077c47fd4
>> This indicates an access violation but I already have all permissions
>> required to access the tables.
>>
>> Regards
>>
>> Colin
>>
>> "Lee Stigile" <lees@nospam_extendsys.com> wrote in message
>> news:439070ab@solutions.advantagedatabase.com...
>>> What's the error message?
>>>
>>> Thanks
>>> Lee
>>>
>>>
>>> "Col" <usesmob@hotmail.com> wrote in message
>>> news:438fd354@solutions.advantagedatabase.com...
>>>> Hi all,
>>>>
>>>> I built a small MSVC++ app to access a dbf (cdx)
>>>>
>>>> char CnnStr[200]="Provider=Advantage OLE DB Provider; Data
>>>> Source=J:\\DTA\\TEMP\\TEST; ServerType=ADS_REMOTE_SERVER;
>>>> TableType=ADS_CDX;";
>>>>
>>>> The code compiles and links OK but whenever I try to run it it sends a
>>>> message to Microsoft instead.
>>>>
>>>> The same basic code with sqlserver CnnStr works fine.
>>>> char CnnStr[200]="Provider=SQLOLEDB;Trusted_Connection=yes;DRIVER={SQL
>>>> Server};SERVER=DBSQLS;DATABASE=Pubs;";.
>>>>
>>>> Is there any help available for MSVC++6?
>>>>
>>>> Regards
>>>>
>>>> Colin
>>>>
>>>
>>>
>>
>>
>
>