After going through all the mailing lists , i could not find a single example of using bytea datatype in an embedded SQL program in postgres. What i am particularly looking at is to populate and retrieve a bytea datatype from a postgresql table using embedded SQL .I am particularly interested in declaring a host variable to retrieve a bytea datatype Any pointers / example src code will be extremely helpful.