I installed PostgreSQL 9.1 under Ubuntu 12.10
And now I have a table called property
I want to add a field that can be used to store photo(link to the photo or import a photo into a column?)
But I do not know how to add this field
Can PostgreSQL do this?
If so, what keywords can I use to find this information?
Update 2013/10/30
I try to use oid to import my files, and it works fine!
But when I want to use a not superuser user to output files,
it's give me an error
ERROR: must be superuser to use server-side lo_export()
HINT: Anyone can use the client-side lo_export() provided by libpq.
How to use client-side lo_export()
?
I try to google it, but there's almost all server-side tutorial
So I tried to use byteA
it's works fine with other user but cannot export data to a file?
I tried to use bytea_export
but bytea_import
is make by Jack's sql script not a built-in function
So there is two more question:
1) How to use clent_side lo_export()
2) how to use bytea_export()
??
Thanks for answers!