| |
FAQs about Rowset/View/Index
- I find that it is difficult to handle a statement like "Select *
from Orders where OrderID in (?, ?, ?, .....)" with ATL consumer
templates. Can OleDBPro handle this statement easily?
Yes! All the OleDBPro classes and
templates are 100% generic and dynamic to handle any one of statements with
no requirement of schema data at the design time at all, no matter how
complicate the statement is. For how to deal with the above statement using
OleDBPro, see the provided examples Scroll
and MultiRecords.
-
How about TCHAR in OleDBPro module? Can I use
TCHAR data type with CRBase
based classes and templates?
Yes! We can easily use TCHAR data
type with CRBase
based classes and templates by calling CRBase::SetDataType.
If the size of TCHAR is 1, the data type should be set to DBTYPE_STR for a
string. Otherwise, the data type should be DBTYPE_WSTR.
-
I am able to use MS Access providers with some
ISAM drivers to read records with no problems, but I failed to update
records. Why?
You can use jet providers to read
ISAM database files such as dBase, Paradox, Text, HTML, and so on. However,
you may have problems in updating, adding and deleting records. To update
ISAM database files, you need to contact Borland
for Borland database engine. Microsoft also has updateable ISAM drivers for
dBase and Paradox files too.
-
I know most of providers don't support OLEDB
TView object and can't open a COView
directly. With the help of MS Client Cursor Engine, I may open a COView
object. However, I am only able to open a COView
object with COView::OpenView
using MS CCE. I can't use template
functions or COView::OpenWithCmnd
to open a COView
object with MS CCE. Why?
You are right! Currently you can
only use COView::OpenView
to open a COView object because of limitations of current version of MS CCE.
Additionally, you can't use COView::OpenRowset
to apply a view to a rowset either. We hope MS continue to improve its MS
CCE functionality.
-
BLOB as in-memory or BLOB as storage? Which
method is better to be used for accessing a BLOB?
A BLOB can be accessed as an
in-memory data, an array of bytes, or retrieved as a single unit, a storage
object. OleDBPro supports both the two methods. See the examples BLOBs
and AOTBLOB. According to our experience and as shown in the two examples, it
is simpler, more convenient and more straight to use BLOB as in-memory.
Additionally, the first method may be faster for most of relational DBMS
providers. It seems to us that relational DBMS providers internally transfer
a storage object from and into an array of bytes at the client side, which costs a
fraction of time.
|