QxORM Connection Provider

Open discussion on QxOrm library

QxORM Connection Provider

Postby zbenjamin » Wed Dec 07, 2011 10:48 pm

Hello,

i'm currently looking for a good Qt based ORM solution for my next project
and i came across QxtORM. It looks very promising but there is one small
problem.

I'm going to implement a Webservice Application on top of a qt application server.
This server provides a connection pool and uses a randrom free connection from that pool.
Is it possible to "tell" QxORM which connection to use?

regards zbenjamin
zbenjamin
 
Posts: 5
Joined: Wed Dec 07, 2011 10:34 pm

Re: QxORM Connection Provider

Postby QxOrm admin » Thu Dec 08, 2011 7:57 am

Yes you can ! :)

All functions into namespace qx::dao provides an optional parameter of type QSqlDatabase from QtSql Qt module.
So, you can use your own connection to communicate with database (from a connection pool for example).

You can also use your own connection if you want to work with a session (QxSession class).
For more details about session, you can go in the FAQ of QxOrm website :
http://www.qxorm.com/qxorm_en/faq.html#faq_170
QxOrm admin
 

Re: QxORM Connection Provider

Postby Guest » Thu Dec 08, 2011 8:59 am

Aaaa ic, i should have read the documentation a littlebit better ;).
So there is no need for me to initialize the QxSqlDatabase singleton thats good.
I already feared it maybe needs lots of time to initialize the Library when i pass it the Database Object.

Thanks for your help ;)
Guest
 


Return to QxOrm - Open discussion

Who is online

Users browsing this forum: No registered users and 18 guests