Overview
Features
Download
Documentation
Community
Add-Ons & Services

Binding MySQL Datatype 'datetime'

Please post support and help requests here.

Binding MySQL Datatype 'datetime'

Postby loens » 09 Feb 2009, 08:51

In the last days i test the Mysql - Inerface to POCO.
I have a Table with datafild from the Type datetime.
I dont know ...
How binding this datatype
This dont run ... it's crash!!
>>std::string teststring ;
>> Statement insert((*MySQL_Datenbank::getSession() <<"SELECT (time) FROM br.test2 ",into(teststring),limit(1)));
do you have a Sample?
thanks!!!!
loens
 
Posts: 1
Joined: 09 Feb 2009, 08:38

Re: Binding MySQL Datatype 'datetime'

Postby alex » 09 Feb 2009, 12:26

You are trying to bind DateTime to std::string. If you are using 1.3.3 release, then you should convert the DateTime field into string in your SQL. Trunk development branch has built-in Poco::DateTime support.
alex
 
Posts: 1121
Joined: 11 Jul 2006, 16:27
Location: United_States


Return to Support

Who is online

Users browsing this forum: No registered users and 1 guest