I'm working through some jifty tutorials, particular the Model stuff.
I can use the schema language to create most of the following:

CREATE TABLE incoming_components (
  id            BIGINT      PRIMARY KEY,

  -- mac MACADDR,
  mac_as_int    BIGINT      NOT NULL DEFAULT -1,
  mac           VARCHAR(17) NOT NULL DEFAULT '',

  serial_number TEXT        NOT NULL DEFAULT '',
  model_number  TEXT        NOT NULL DEFAULT '',

  UNIQUE(
         mac_as_int,
         mac,
         serial_number,
         model_number
        )
);


Do I model the UNIQUE constraints within my AppName::Record schema { } ?

or

Do I add in the constraints as supplementary sql statements?

Thanks for the help,

-matt zagrabelny
_______________________________________________
jifty-devel mailing list
jifty-devel@lists.jifty.org
http://lists.jifty.org/cgi-bin/mailman/listinfo/jifty-devel

Reply via email to