From: Pat Sherrill Date: March 17 1999 12:24pm Subject: Re: ODBC/MFC problem List-Archive: http://lists.mysql.com/myodbc/44 Message-Id: <00a601be7071$149cfa80$1e0110ac@pms98> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Stefan, The path of least resistance would be to create a jet DB link to the ODBC driver for the mysql database. In this way, you can use dynamic recordsets. You do, however, need to then deal with the thread-safe issues of DAO. At this time, myodbc relies on manager cursors since mysql does not yet implement cursors. I hope this helps. Pat Sherrill... -----Original Message----- From: Stefan Pantke To: myodbc@stripped Date: Tuesday, March 16, 1999 7:57 PM Subject: ODBC/MFC problem >I'm about to write an ISAPI DLL on NT 4.0 using VC++ 6.0. > >Using various settings while opening the CDatabase/CRecordset objects, >I allways get error messages from thrown exceptions: > > - dynasets not supported > - static-cursors required, if snapshop requested > >I found no combination of parameters to use the ODBC >MFC classes to even read one record. > >Question: > > Can I use MySQL using MFC and ODBC with VC++ 6.0? > Is the MySQL ODBC driver thread-safe? > >Thanks > >Stefan > > >Here is a code sample: > >************************************************* > // simple call to CDatabase.Open failes -> KB Q181434 > lCompanyDB.OpenEx(_T("DSN=my2;UID=root;"), >CDatabase::noOdbcDialog); > > CGetCompany lCompanyRS( &lCompanyDB ); > > lCompanyRS.Open( CRecordset::dynaset, NULL ); > > if ( ! lCompanyRS.IsBOF() ) > { > while( ! lCompanyRS.IsEOF() ) > { > *pCtxt << _T( "
" ); > // *pCtxt << lCompanyRS.m_Name; > lCompanyRS.MoveNext(); > } > } > > lCompanyRS.Close(); > > > lCompanyDB.Close(); >************************************************* > > > >--------------------------------------------------------------------- >To request this thread, e-mail myodbc-thread42@stripped >To unsubscribe, e-mail the address shown in the >List-Unsubscribe header of this message. >For additional commands, e-mail: myodbc-help@stripped > >