Colin Wang posted a blog about database connecting with C++ and CONNECT. It's good to see an example for that neglected corner of MicroStation!
This code using the mdlDB_api is very procedural. Not a lot different to examples published decades ago for MicroStation/J! Is an object-oriented C++ or .NET API likely to appear for database interfacing?
Hi Jon,
This is what we have today. And, we don't have any plan to upgrade it, at-least till, it supports newer version of Microsoft SQL or Oracle.
Thanks,
Mangesh
Jon Summers said:Is an object-oriented C++ or .NET API likely to appear for database interfacing?
A question is how DB connection can be "transformed" into object API. My experience is that it usually ends at some ORM framework. They are popular and often used in Java and NET (I know nothing about C++ ORMs, only that some exist), but it sounds to me like an overkill.
It would be interesting to know how many people today use DB connection, especially for new projects. Even in Bentley Map it's now obsolete and query/post approach (where data are cached into DGN) is used instead of mslink based online connection.
Regards,
Jan
Bentley Accredited Developer: iTwin Platform - AssociateLabyrinth Technology | dev.notes() | cad.point
Jan Ĺ legr said:It would be interesting to know how many people today use DB connection
Well, that's what lies behind my question. What prompted Colin Wang to create that blog?
I haven't personally seen any interest in MicroStation's DB interface for many years. That's partly, of course, because it's not promoted! There are many reasons still to want to connect to a DB, if only for reading external data relevant to a DGN object. ECSchemas are great as an internal DB that is available to external apps, but there are occasions when one wants to merge internal (ECSchema) data with external (relational DB) data.
Regards, Jon Summers LA Solutions
My company DOES utilize MicroStation-to-Database connections, but we do so without using the mdlDB_api. Typically,we utilize DSN-less ODBC connections.
I used the mdlDB_ API for a number of years for PowerDraft support, all the way up to V8i. It's never seen any updates to existing bugs or functionality, AFAICT. You are much better off just using your own database code. Any existing DB framework would be faster, better documented and more stable than the old MDL Database API.
--Piers PorterAltiva Software
Piers Porter said:Any existing DB framework would be faster, better documented and more stable than the old MDL Database API
Yes: I've successfully used Microsoft ActiveX Data Objects (ADO) with both VBA and C++. .NET has its own, very useful, library of DB interfaces plus LINQ.
That's why I asked the question: What prompted Colin Wang to create that blog?