Skip to content
tanushpatel-gitPublic

About

In this project a merchant will able to share their code very easily to navy and blog type service also there.

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

For doing clean DB

BEGIN;

DO $$
DECLARE
  table_list text;
BEGIN
  SELECT string_agg(format('%I.%I', schemaname, tablename), ', ')
  INTO table_list
  FROM pg_tables
  WHERE schemaname = 'public';

  IF table_list IS NOT NULL THEN
    EXECUTE 'TRUNCATE TABLE ' || table_list || ' RESTART IDENTITY CASCADE';
  END IF;
END $$;

COMMIT;```

About

In this project a merchant will able to share their code very easily to navy and blog type service also there.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages