-- Table: public.categorias

CREATE TABLE IF NOT EXISTS public.categorias
(
    id integer NOT NULL GENERATED BY DEFAULT AS IDENTITY ( INCREMENT 1 START 1 MINVALUE 1 MAXVALUE 2147483647 CACHE 1 ),
    nombre character varying(100) COLLATE pg_catalog."default" NOT NULL,
    descripcion character varying(500) COLLATE pg_catalog."default",
    activo boolean NOT NULL DEFAULT true,
    eliminado boolean NOT NULL DEFAULT false,
    creado_en timestamp without time zone NOT NULL DEFAULT (now() AT TIME ZONE 'utc'::text),
    actualizado_en timestamp without time zone NOT NULL DEFAULT (now() AT TIME ZONE 'utc'::text),
    creado_por character varying(100) COLLATE pg_catalog."default",
    CONSTRAINT categorias_pkey PRIMARY KEY (id)
)
TABLESPACE pg_default;

ALTER TABLE IF EXISTS public.categorias
    OWNER to postgres;

-- Index: ix_categorias_nombre

-- DROP INDEX IF EXISTS public.ix_categorias_nombre;

CREATE INDEX IF NOT EXISTS ix_categorias_nombre
    ON public.categorias USING btree
    (nombre COLLATE pg_catalog."default" ASC NULLS LAST)
    TABLESPACE pg_default;
