beginor
9/27/2018 - 7:40 AM

postgresql variables

postgresql variables

DO $$
DECLARE
  counter INTEGER := 1;
  first_name VARCHAR(50) := 'John';
  last_name VARCHAR(50) := 'Doe';
  payment NUMERIC(11, 2) := 20.5;
BEGIN
  RAISE NOTICE '% % % has been paid % USD.', counter, first_name, last_name, payment;
END $$;