Hi friends Short question: While the following statement works like a charm:
User user; sql << "select * from user where id=7", into(user); issue the following two lines an error message: vector<User> user; sql << "select * from user", into(users); The message goes like this: C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-conversion.h: In function 'soci::details::into_type_ptr soci::details::do_into(T&, soci::details::user_type_tag) [with T = std::vector<com::emc::entity::user::User, std::allocator<com::emc::entity::user::User> >]': C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/into.h:26: instantiated from 'soci::details::into_type_ptr soci::into(T&) [with T = std::vector<com::emc::entity::user::User, std::allocator<com::emc::entity::user::User> >]' ..\src\main\com\emc\persistence\user\UserDAO.cpp:36: instantiated from here C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-conversion.h:256: error: no matching function for call to 'soci::details::type_ptr<soci::details::into_type_base>::type_ptr(soci::deta ils::conversion_into_type<std::vector<com::emc::entity::user::User, std::allocator<com::emc::entity::user::User> > >*)' C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-ptr.h:21: note: candidates are: soci::details::type_ptr<T>::type_ptr(T*) [with T = soci::details::into_type_base] C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-ptr.h:19: note: soci::details::type_ptr<soci::details::into_type_base>::type_ptr(const soci::details::type_ptr<soci::details::into_type_base>&) C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-conversion.h: In constructor 'soci::details::conversion_into_type<std::vector<T, std::allocator<_Tp1> > >::conversion_into_type(std::vector<T, std::allocator<_Tp1> >&) [with T = com::emc::entity::user::User]': C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-conversion.h:256: instantiated from 'soci::details::into_type_ptr soci::details::do_into(T&, soci::details::user_type_tag) [with T = std::vector<com::emc::entity::user::User, std::allocator<com::emc::entity::user::User> >]' C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/into.h:26: instantiated from 'soci::details::into_type_ptr soci::into(T&) [with T = std::vector<com::emc::entity::user::User, std::allocator<com::emc::entity::user::User> >]' ..\src\main\com\emc\persistence\user\UserDAO.cpp:36: instantiated from here C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/type-conversion.h:145: error: no matching function for call to 'soci::details::into_type<std::vector<soci::values, std::allocator<soci::values> > >::into_type(std::vector<soci::values, std::allocator<soci::values> >&, std::vector<soci::indicator, std::allocator<soci::indicator> >&)' C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/values-exchange.h:101: note: candidates are: soci::details::into_type<std::vector<soci::values, std::allocator<soci::values> > >::into_type() C:\Program Files\C++\soci\soci-3.0.0\build\unix\include/values-exchange.h:99: note: soci::details::into_type<std::vector<soci::values, std::allocator<soci::values> > >::into_type(const soci::details::into_type<std::vector<soci::values, std::allocator<soci::values> > >&) Build error occurred, build is stopped Time consumed: 2114 ms. What do I need to add to my type_conversion specialization make such a bulk operation possible? Thanks in advance for your help and best regards Pascal ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Soci-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/soci-users
