Hi everyone,

I would like to save an Uploaded image to the database.

1) How can I create a BLOB (Binary Data Types) in PostgreSQL (bytea)
using Wt::Dbo ?

I tried: char * picture; and std::vector<char*> picture;

template<class Action>
void persist(Action& a) {
Wt::Dbo::field(a, picture, "picture");
}

but not working.

2) How can I save this uploaded file to a database?
(I'm thinking something like:)

wFileResource = new WFileResource(uploaded_.contentType(),
uploaded_.spoolFileName(), this);
picture = wFileResource;

Thank you.


------------------------------------------------------------------------------
The modern datacenter depends on network connectivity to access resources
and provide services. The best practices for maximizing a physical server's
connectivity to a physical network are well understood - see how these
rules translate into the virtual world? 
http://p.sf.net/sfu/oracle-sfdevnlfb
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to