0

I want generate uuid in postgres to insert in a column

INSERT INTO "EnumMaster"(
            "EnumerationID", "Name", "Text", "Description")
    VALUES (?, 'asasas', 'asasds', 'asdasdsad');

EnumerationID has data type uuid so how to generate new uuid and add in that coloumn

Sumeet
  • 111
  • 1
  • 16
  • You need to install the extension `uuid-ossp` then you can use any of the function provided by the module: http://www.postgresql.org/docs/current/static/uuid-ossp.html –  Mar 27 '14 at 10:51
  • after downloading how to install it please tell now its not downloading page not found – Sumeet Mar 27 '14 at 10:56
  • Installation and use can be seen in this stackoverflow entry: http://stackoverflow.com/questions/12505158/generating-a-uuid-in-postgres-for-insert-statement – Phil Brooks Mar 27 '14 at 10:56

0 Answers0