github.com/Redstoneguy129/cli@v0.0.0-20230211220159-15dca4e91917/internal/utils/templates/initial_schemas/15.sql (about) 1 -- 2 -- PostgreSQL database dump 3 -- 4 5 -- Dumped from database version 15.1 (Debian 15.1-1.pgdg110+1) 6 -- Dumped by pg_dump version 15.0 7 8 SET statement_timeout = 0; 9 SET lock_timeout = 0; 10 SET idle_in_transaction_session_timeout = 0; 11 SET client_encoding = 'UTF8'; 12 SET standard_conforming_strings = on; 13 SELECT pg_catalog.set_config('search_path', '', false); 14 SET check_function_bodies = false; 15 SET xmloption = content; 16 SET client_min_messages = warning; 17 SET row_security = off; 18 19 -- 20 -- Name: _realtime; Type: SCHEMA; Schema: -; Owner: postgres 21 -- 22 23 CREATE SCHEMA IF NOT EXISTS _realtime; 24 25 26 ALTER SCHEMA _realtime OWNER TO postgres; 27 28 -- 29 -- Name: auth; Type: SCHEMA; Schema: -; Owner: supabase_admin 30 -- 31 32 CREATE SCHEMA IF NOT EXISTS auth; 33 34 35 ALTER SCHEMA auth OWNER TO supabase_admin; 36 37 -- 38 -- Name: extensions; Type: SCHEMA; Schema: -; Owner: postgres 39 -- 40 41 CREATE SCHEMA IF NOT EXISTS extensions; 42 43 44 ALTER SCHEMA extensions OWNER TO postgres; 45 46 -- 47 -- Name: graphql; Type: SCHEMA; Schema: -; Owner: supabase_admin 48 -- 49 50 CREATE SCHEMA IF NOT EXISTS graphql; 51 52 53 ALTER SCHEMA graphql OWNER TO supabase_admin; 54 55 -- 56 -- Name: graphql_public; Type: SCHEMA; Schema: -; Owner: supabase_admin 57 -- 58 59 CREATE SCHEMA IF NOT EXISTS graphql_public; 60 61 62 ALTER SCHEMA graphql_public OWNER TO supabase_admin; 63 64 -- 65 -- Name: pgbouncer; Type: SCHEMA; Schema: -; Owner: pgbouncer 66 -- 67 68 CREATE SCHEMA IF NOT EXISTS pgbouncer; 69 70 71 ALTER SCHEMA pgbouncer OWNER TO pgbouncer; 72 73 -- 74 -- Name: pgsodium; Type: SCHEMA; Schema: -; Owner: supabase_admin 75 -- 76 77 CREATE SCHEMA IF NOT EXISTS pgsodium; 78 79 80 ALTER SCHEMA pgsodium OWNER TO supabase_admin; 81 82 -- 83 -- Name: pgsodium; Type: EXTENSION; Schema: -; Owner: - 84 -- 85 86 CREATE EXTENSION IF NOT EXISTS pgsodium WITH SCHEMA pgsodium; 87 88 89 -- 90 -- Name: EXTENSION pgsodium; Type: COMMENT; Schema: -; Owner: 91 -- 92 93 COMMENT ON EXTENSION pgsodium IS 'Pgsodium is a modern cryptography library for Postgres.'; 94 95 96 -- 97 -- Name: realtime; Type: SCHEMA; Schema: -; Owner: supabase_admin 98 -- 99 100 CREATE SCHEMA IF NOT EXISTS realtime; 101 102 103 ALTER SCHEMA realtime OWNER TO supabase_admin; 104 105 -- 106 -- Name: storage; Type: SCHEMA; Schema: -; Owner: supabase_admin 107 -- 108 109 CREATE SCHEMA IF NOT EXISTS storage; 110 111 112 ALTER SCHEMA storage OWNER TO supabase_admin; 113 114 -- 115 -- Name: pg_graphql; Type: EXTENSION; Schema: -; Owner: - 116 -- 117 118 CREATE EXTENSION IF NOT EXISTS pg_graphql WITH SCHEMA graphql; 119 120 121 -- 122 -- Name: EXTENSION pg_graphql; Type: COMMENT; Schema: -; Owner: 123 -- 124 125 COMMENT ON EXTENSION pg_graphql IS 'pg_graphql: GraphQL support'; 126 127 128 -- 129 -- Name: pg_stat_statements; Type: EXTENSION; Schema: -; Owner: - 130 -- 131 132 CREATE EXTENSION IF NOT EXISTS pg_stat_statements WITH SCHEMA extensions; 133 134 135 -- 136 -- Name: EXTENSION pg_stat_statements; Type: COMMENT; Schema: -; Owner: 137 -- 138 139 COMMENT ON EXTENSION pg_stat_statements IS 'track planning and execution statistics of all SQL statements executed'; 140 141 142 -- 143 -- Name: pgcrypto; Type: EXTENSION; Schema: -; Owner: - 144 -- 145 146 CREATE EXTENSION IF NOT EXISTS pgcrypto WITH SCHEMA extensions; 147 148 149 -- 150 -- Name: EXTENSION pgcrypto; Type: COMMENT; Schema: -; Owner: 151 -- 152 153 COMMENT ON EXTENSION pgcrypto IS 'cryptographic functions'; 154 155 156 -- 157 -- Name: pgjwt; Type: EXTENSION; Schema: -; Owner: - 158 -- 159 160 CREATE EXTENSION IF NOT EXISTS pgjwt WITH SCHEMA extensions; 161 162 163 -- 164 -- Name: EXTENSION pgjwt; Type: COMMENT; Schema: -; Owner: 165 -- 166 167 COMMENT ON EXTENSION pgjwt IS 'JSON Web Token API for Postgresql'; 168 169 170 -- 171 -- Name: uuid-ossp; Type: EXTENSION; Schema: -; Owner: - 172 -- 173 174 CREATE EXTENSION IF NOT EXISTS "uuid-ossp" WITH SCHEMA extensions; 175 176 177 -- 178 -- Name: EXTENSION "uuid-ossp"; Type: COMMENT; Schema: -; Owner: 179 -- 180 181 COMMENT ON EXTENSION "uuid-ossp" IS 'generate universally unique identifiers (UUIDs)'; 182 183 184 -- 185 -- Name: aal_level; Type: TYPE; Schema: auth; Owner: supabase_auth_admin 186 -- 187 188 CREATE TYPE auth.aal_level AS ENUM ( 189 'aal1', 190 'aal2', 191 'aal3' 192 ); 193 194 195 ALTER TYPE auth.aal_level OWNER TO supabase_auth_admin; 196 197 -- 198 -- Name: factor_status; Type: TYPE; Schema: auth; Owner: supabase_auth_admin 199 -- 200 201 CREATE TYPE auth.factor_status AS ENUM ( 202 'unverified', 203 'verified' 204 ); 205 206 207 ALTER TYPE auth.factor_status OWNER TO supabase_auth_admin; 208 209 -- 210 -- Name: factor_type; Type: TYPE; Schema: auth; Owner: supabase_auth_admin 211 -- 212 213 CREATE TYPE auth.factor_type AS ENUM ( 214 'totp', 215 'webauthn' 216 ); 217 218 219 ALTER TYPE auth.factor_type OWNER TO supabase_auth_admin; 220 221 -- 222 -- Name: email(); Type: FUNCTION; Schema: auth; Owner: supabase_auth_admin 223 -- 224 225 CREATE OR REPLACE FUNCTION auth.email() RETURNS text 226 LANGUAGE sql STABLE 227 AS $$ 228 select 229 coalesce( 230 nullif(current_setting('request.jwt.claim.email', true), ''), 231 (nullif(current_setting('request.jwt.claims', true), '')::jsonb ->> 'email') 232 )::text 233 $$; 234 235 236 ALTER FUNCTION auth.email() OWNER TO supabase_auth_admin; 237 238 -- 239 -- Name: FUNCTION email(); Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 240 -- 241 242 COMMENT ON FUNCTION auth.email() IS 'Deprecated. Use auth.jwt() -> ''email'' instead.'; 243 244 245 -- 246 -- Name: jwt(); Type: FUNCTION; Schema: auth; Owner: supabase_auth_admin 247 -- 248 249 CREATE OR REPLACE FUNCTION auth.jwt() RETURNS jsonb 250 LANGUAGE sql STABLE 251 AS $$ 252 select 253 coalesce( 254 nullif(current_setting('request.jwt.claim', true), ''), 255 nullif(current_setting('request.jwt.claims', true), '') 256 )::jsonb 257 $$; 258 259 260 ALTER FUNCTION auth.jwt() OWNER TO supabase_auth_admin; 261 262 -- 263 -- Name: role(); Type: FUNCTION; Schema: auth; Owner: supabase_auth_admin 264 -- 265 266 CREATE OR REPLACE FUNCTION auth.role() RETURNS text 267 LANGUAGE sql STABLE 268 AS $$ 269 select 270 coalesce( 271 nullif(current_setting('request.jwt.claim.role', true), ''), 272 (nullif(current_setting('request.jwt.claims', true), '')::jsonb ->> 'role') 273 )::text 274 $$; 275 276 277 ALTER FUNCTION auth.role() OWNER TO supabase_auth_admin; 278 279 -- 280 -- Name: FUNCTION role(); Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 281 -- 282 283 COMMENT ON FUNCTION auth.role() IS 'Deprecated. Use auth.jwt() -> ''role'' instead.'; 284 285 286 -- 287 -- Name: uid(); Type: FUNCTION; Schema: auth; Owner: supabase_auth_admin 288 -- 289 290 CREATE OR REPLACE FUNCTION auth.uid() RETURNS uuid 291 LANGUAGE sql STABLE 292 AS $$ 293 select 294 coalesce( 295 nullif(current_setting('request.jwt.claim.sub', true), ''), 296 (nullif(current_setting('request.jwt.claims', true), '')::jsonb ->> 'sub') 297 )::uuid 298 $$; 299 300 301 ALTER FUNCTION auth.uid() OWNER TO supabase_auth_admin; 302 303 -- 304 -- Name: FUNCTION uid(); Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 305 -- 306 307 COMMENT ON FUNCTION auth.uid() IS 'Deprecated. Use auth.jwt() -> ''sub'' instead.'; 308 309 310 -- 311 -- Name: grant_pg_cron_access(); Type: FUNCTION; Schema: extensions; Owner: postgres 312 -- 313 314 CREATE OR REPLACE FUNCTION extensions.grant_pg_cron_access() RETURNS event_trigger 315 LANGUAGE plpgsql 316 AS $$ 317 DECLARE 318 schema_is_cron bool; 319 BEGIN 320 schema_is_cron = ( 321 SELECT n.nspname = 'cron' 322 FROM pg_event_trigger_ddl_commands() AS ev 323 LEFT JOIN pg_catalog.pg_namespace AS n 324 ON ev.objid = n.oid 325 ); 326 327 IF schema_is_cron 328 THEN 329 grant usage on schema cron to postgres with grant option; 330 331 alter default privileges in schema cron grant all on tables to postgres with grant option; 332 alter default privileges in schema cron grant all on functions to postgres with grant option; 333 alter default privileges in schema cron grant all on sequences to postgres with grant option; 334 335 alter default privileges for user supabase_admin in schema cron grant all 336 on sequences to postgres with grant option; 337 alter default privileges for user supabase_admin in schema cron grant all 338 on tables to postgres with grant option; 339 alter default privileges for user supabase_admin in schema cron grant all 340 on functions to postgres with grant option; 341 342 grant all privileges on all tables in schema cron to postgres with grant option; 343 344 END IF; 345 346 END; 347 $$; 348 349 350 ALTER FUNCTION extensions.grant_pg_cron_access() OWNER TO postgres; 351 352 -- 353 -- Name: FUNCTION grant_pg_cron_access(); Type: COMMENT; Schema: extensions; Owner: postgres 354 -- 355 356 COMMENT ON FUNCTION extensions.grant_pg_cron_access() IS 'Grants access to pg_cron'; 357 358 359 -- 360 -- Name: grant_pg_graphql_access(); Type: FUNCTION; Schema: extensions; Owner: supabase_admin 361 -- 362 363 CREATE OR REPLACE FUNCTION extensions.grant_pg_graphql_access() RETURNS event_trigger 364 LANGUAGE plpgsql 365 AS $_$ 366 DECLARE 367 func_is_graphql_resolve bool; 368 BEGIN 369 func_is_graphql_resolve = ( 370 SELECT n.proname = 'resolve' 371 FROM pg_event_trigger_ddl_commands() AS ev 372 LEFT JOIN pg_catalog.pg_proc AS n 373 ON ev.objid = n.oid 374 ); 375 376 IF func_is_graphql_resolve 377 THEN 378 -- Update public wrapper to pass all arguments through to the pg_graphql resolve func 379 DROP FUNCTION IF EXISTS graphql_public.graphql; 380 create or replace function graphql_public.graphql( 381 "operationName" text default null, 382 query text default null, 383 variables jsonb default null, 384 extensions jsonb default null 385 ) 386 returns jsonb 387 language sql 388 as $$ 389 select graphql.resolve( 390 query := query, 391 variables := coalesce(variables, '{}'), 392 "operationName" := "operationName", 393 extensions := extensions 394 ); 395 $$; 396 397 -- This hook executes when `graphql.resolve` is created. That is not necessarily the last 398 -- function in the extension so we need to grant permissions on existing entities AND 399 -- update default permissions to any others that are created after `graphql.resolve` 400 grant usage on schema graphql to postgres, anon, authenticated, service_role; 401 grant select on all tables in schema graphql to postgres, anon, authenticated, service_role; 402 grant execute on all functions in schema graphql to postgres, anon, authenticated, service_role; 403 grant all on all sequences in schema graphql to postgres, anon, authenticated, service_role; 404 alter default privileges in schema graphql grant all on tables to postgres, anon, authenticated, service_role; 405 alter default privileges in schema graphql grant all on functions to postgres, anon, authenticated, service_role; 406 alter default privileges in schema graphql grant all on sequences to postgres, anon, authenticated, service_role; 407 END IF; 408 409 END; 410 $_$; 411 412 413 ALTER FUNCTION extensions.grant_pg_graphql_access() OWNER TO supabase_admin; 414 415 -- 416 -- Name: FUNCTION grant_pg_graphql_access(); Type: COMMENT; Schema: extensions; Owner: supabase_admin 417 -- 418 419 COMMENT ON FUNCTION extensions.grant_pg_graphql_access() IS 'Grants access to pg_graphql'; 420 421 422 -- 423 -- Name: grant_pg_net_access(); Type: FUNCTION; Schema: extensions; Owner: postgres 424 -- 425 426 CREATE OR REPLACE FUNCTION extensions.grant_pg_net_access() RETURNS event_trigger 427 LANGUAGE plpgsql 428 AS $$ 429 BEGIN 430 IF EXISTS ( 431 SELECT 1 432 FROM pg_event_trigger_ddl_commands() AS ev 433 JOIN pg_extension AS ext 434 ON ev.objid = ext.oid 435 WHERE ext.extname = 'pg_net' 436 ) 437 THEN 438 IF NOT EXISTS ( 439 SELECT 1 440 FROM pg_roles 441 WHERE rolname = 'supabase_functions_admin' 442 ) 443 THEN 444 CREATE USER supabase_functions_admin NOINHERIT CREATEROLE LOGIN NOREPLICATION; 445 END IF; 446 447 GRANT USAGE ON SCHEMA net TO supabase_functions_admin, postgres, anon, authenticated, service_role; 448 449 ALTER function net.http_get(url text, params jsonb, headers jsonb, timeout_milliseconds integer) SECURITY DEFINER; 450 ALTER function net.http_post(url text, body jsonb, params jsonb, headers jsonb, timeout_milliseconds integer) SECURITY DEFINER; 451 452 ALTER function net.http_get(url text, params jsonb, headers jsonb, timeout_milliseconds integer) SET search_path = net; 453 ALTER function net.http_post(url text, body jsonb, params jsonb, headers jsonb, timeout_milliseconds integer) SET search_path = net; 454 455 REVOKE ALL ON FUNCTION net.http_get(url text, params jsonb, headers jsonb, timeout_milliseconds integer) FROM PUBLIC; 456 REVOKE ALL ON FUNCTION net.http_post(url text, body jsonb, params jsonb, headers jsonb, timeout_milliseconds integer) FROM PUBLIC; 457 458 GRANT EXECUTE ON FUNCTION net.http_get(url text, params jsonb, headers jsonb, timeout_milliseconds integer) TO supabase_functions_admin, postgres, anon, authenticated, service_role; 459 GRANT EXECUTE ON FUNCTION net.http_post(url text, body jsonb, params jsonb, headers jsonb, timeout_milliseconds integer) TO supabase_functions_admin, postgres, anon, authenticated, service_role; 460 END IF; 461 END; 462 $$; 463 464 465 ALTER FUNCTION extensions.grant_pg_net_access() OWNER TO postgres; 466 467 -- 468 -- Name: FUNCTION grant_pg_net_access(); Type: COMMENT; Schema: extensions; Owner: postgres 469 -- 470 471 COMMENT ON FUNCTION extensions.grant_pg_net_access() IS 'Grants access to pg_net'; 472 473 474 -- 475 -- Name: pgrst_ddl_watch(); Type: FUNCTION; Schema: extensions; Owner: supabase_admin 476 -- 477 478 CREATE OR REPLACE FUNCTION extensions.pgrst_ddl_watch() RETURNS event_trigger 479 LANGUAGE plpgsql 480 AS $$ 481 DECLARE 482 cmd record; 483 BEGIN 484 FOR cmd IN SELECT * FROM pg_event_trigger_ddl_commands() 485 LOOP 486 IF cmd.command_tag IN ( 487 'CREATE SCHEMA', 'ALTER SCHEMA' 488 , 'CREATE TABLE', 'CREATE TABLE AS', 'SELECT INTO', 'ALTER TABLE' 489 , 'CREATE FOREIGN TABLE', 'ALTER FOREIGN TABLE' 490 , 'CREATE VIEW', 'ALTER VIEW' 491 , 'CREATE MATERIALIZED VIEW', 'ALTER MATERIALIZED VIEW' 492 , 'CREATE FUNCTION', 'ALTER FUNCTION' 493 , 'CREATE TRIGGER' 494 , 'CREATE TYPE', 'ALTER TYPE' 495 , 'CREATE RULE' 496 , 'COMMENT' 497 ) 498 -- don't notify in case of CREATE TEMP table or other objects created on pg_temp 499 AND cmd.schema_name is distinct from 'pg_temp' 500 THEN 501 NOTIFY pgrst, 'reload schema'; 502 END IF; 503 END LOOP; 504 END; $$; 505 506 507 ALTER FUNCTION extensions.pgrst_ddl_watch() OWNER TO supabase_admin; 508 509 -- 510 -- Name: pgrst_drop_watch(); Type: FUNCTION; Schema: extensions; Owner: supabase_admin 511 -- 512 513 CREATE OR REPLACE FUNCTION extensions.pgrst_drop_watch() RETURNS event_trigger 514 LANGUAGE plpgsql 515 AS $$ 516 DECLARE 517 obj record; 518 BEGIN 519 FOR obj IN SELECT * FROM pg_event_trigger_dropped_objects() 520 LOOP 521 IF obj.object_type IN ( 522 'schema' 523 , 'table' 524 , 'foreign table' 525 , 'view' 526 , 'materialized view' 527 , 'function' 528 , 'trigger' 529 , 'type' 530 , 'rule' 531 ) 532 AND obj.is_temporary IS false -- no pg_temp objects 533 THEN 534 NOTIFY pgrst, 'reload schema'; 535 END IF; 536 END LOOP; 537 END; $$; 538 539 540 ALTER FUNCTION extensions.pgrst_drop_watch() OWNER TO supabase_admin; 541 542 -- 543 -- Name: set_graphql_placeholder(); Type: FUNCTION; Schema: extensions; Owner: supabase_admin 544 -- 545 546 CREATE OR REPLACE FUNCTION extensions.set_graphql_placeholder() RETURNS event_trigger 547 LANGUAGE plpgsql 548 AS $_$ 549 DECLARE 550 graphql_is_dropped bool; 551 BEGIN 552 graphql_is_dropped = ( 553 SELECT ev.schema_name = 'graphql_public' 554 FROM pg_event_trigger_dropped_objects() AS ev 555 WHERE ev.schema_name = 'graphql_public' 556 ); 557 558 IF graphql_is_dropped 559 THEN 560 create or replace function graphql_public.graphql( 561 "operationName" text default null, 562 query text default null, 563 variables jsonb default null, 564 extensions jsonb default null 565 ) 566 returns jsonb 567 language plpgsql 568 as $$ 569 DECLARE 570 server_version float; 571 BEGIN 572 server_version = (SELECT (SPLIT_PART((select version()), ' ', 2))::float); 573 574 IF server_version >= 14 THEN 575 RETURN jsonb_build_object( 576 'errors', jsonb_build_array( 577 jsonb_build_object( 578 'message', 'pg_graphql extension is not enabled.' 579 ) 580 ) 581 ); 582 ELSE 583 RETURN jsonb_build_object( 584 'errors', jsonb_build_array( 585 jsonb_build_object( 586 'message', 'pg_graphql is only available on projects running Postgres 14 onwards.' 587 ) 588 ) 589 ); 590 END IF; 591 END; 592 $$; 593 END IF; 594 595 END; 596 $_$; 597 598 599 ALTER FUNCTION extensions.set_graphql_placeholder() OWNER TO supabase_admin; 600 601 -- 602 -- Name: FUNCTION set_graphql_placeholder(); Type: COMMENT; Schema: extensions; Owner: supabase_admin 603 -- 604 605 COMMENT ON FUNCTION extensions.set_graphql_placeholder() IS 'Reintroduces placeholder function for graphql_public.graphql'; 606 607 608 -- 609 -- Name: get_auth(text); Type: FUNCTION; Schema: pgbouncer; Owner: postgres 610 -- 611 612 CREATE OR REPLACE FUNCTION pgbouncer.get_auth(p_usename text) RETURNS TABLE(username text, password text) 613 LANGUAGE plpgsql SECURITY DEFINER 614 AS $$ 615 BEGIN 616 RAISE WARNING 'PgBouncer auth request: %', p_usename; 617 618 RETURN QUERY 619 SELECT usename::TEXT, passwd::TEXT FROM pg_catalog.pg_shadow 620 WHERE usename = p_usename; 621 END; 622 $$; 623 624 625 ALTER FUNCTION pgbouncer.get_auth(p_usename text) OWNER TO postgres; 626 627 -- 628 -- Name: extension(text); Type: FUNCTION; Schema: storage; Owner: supabase_storage_admin 629 -- 630 631 CREATE OR REPLACE FUNCTION storage.extension(name text) RETURNS text 632 LANGUAGE plpgsql 633 AS $$ 634 DECLARE 635 _parts text[]; 636 _filename text; 637 BEGIN 638 select string_to_array(name, '/') into _parts; 639 select _parts[array_length(_parts,1)] into _filename; 640 -- @todo return the last part instead of 2 641 return split_part(_filename, '.', 2); 642 END 643 $$; 644 645 646 ALTER FUNCTION storage.extension(name text) OWNER TO supabase_storage_admin; 647 648 -- 649 -- Name: filename(text); Type: FUNCTION; Schema: storage; Owner: supabase_storage_admin 650 -- 651 652 CREATE OR REPLACE FUNCTION storage.filename(name text) RETURNS text 653 LANGUAGE plpgsql 654 AS $$ 655 DECLARE 656 _parts text[]; 657 BEGIN 658 select string_to_array(name, '/') into _parts; 659 return _parts[array_length(_parts,1)]; 660 END 661 $$; 662 663 664 ALTER FUNCTION storage.filename(name text) OWNER TO supabase_storage_admin; 665 666 -- 667 -- Name: foldername(text); Type: FUNCTION; Schema: storage; Owner: supabase_storage_admin 668 -- 669 670 CREATE OR REPLACE FUNCTION storage.foldername(name text) RETURNS text[] 671 LANGUAGE plpgsql 672 AS $$ 673 DECLARE 674 _parts text[]; 675 BEGIN 676 select string_to_array(name, '/') into _parts; 677 return _parts[1:array_length(_parts,1)-1]; 678 END 679 $$; 680 681 682 ALTER FUNCTION storage.foldername(name text) OWNER TO supabase_storage_admin; 683 684 -- 685 -- Name: get_size_by_bucket(); Type: FUNCTION; Schema: storage; Owner: supabase_storage_admin 686 -- 687 688 CREATE OR REPLACE FUNCTION storage.get_size_by_bucket() RETURNS TABLE(size bigint, bucket_id text) 689 LANGUAGE plpgsql 690 AS $$ 691 BEGIN 692 return query 693 select sum((metadata->>'size')::int) as size, obj.bucket_id 694 from "storage".objects as obj 695 group by obj.bucket_id; 696 END 697 $$; 698 699 700 ALTER FUNCTION storage.get_size_by_bucket() OWNER TO supabase_storage_admin; 701 702 -- 703 -- Name: search(text, text, integer, integer, integer, text, text, text); Type: FUNCTION; Schema: storage; Owner: supabase_storage_admin 704 -- 705 706 CREATE OR REPLACE FUNCTION storage.search(prefix text, bucketname text, limits integer DEFAULT 100, levels integer DEFAULT 1, offsets integer DEFAULT 0, search text DEFAULT ''::text, sortcolumn text DEFAULT 'name'::text, sortorder text DEFAULT 'asc'::text) RETURNS TABLE(name text, id uuid, updated_at timestamp with time zone, created_at timestamp with time zone, last_accessed_at timestamp with time zone, metadata jsonb) 707 LANGUAGE plpgsql STABLE 708 AS $_$ 709 declare 710 v_order_by text; 711 v_sort_order text; 712 begin 713 case 714 when sortcolumn = 'name' then 715 v_order_by = 'name'; 716 when sortcolumn = 'updated_at' then 717 v_order_by = 'updated_at'; 718 when sortcolumn = 'created_at' then 719 v_order_by = 'created_at'; 720 when sortcolumn = 'last_accessed_at' then 721 v_order_by = 'last_accessed_at'; 722 else 723 v_order_by = 'name'; 724 end case; 725 726 case 727 when sortorder = 'asc' then 728 v_sort_order = 'asc'; 729 when sortorder = 'desc' then 730 v_sort_order = 'desc'; 731 else 732 v_sort_order = 'asc'; 733 end case; 734 735 v_order_by = v_order_by || ' ' || v_sort_order; 736 737 return query execute 738 'with folders as ( 739 select path_tokens[$1] as folder 740 from storage.objects 741 where objects.name ilike $2 || $3 || ''%'' 742 and bucket_id = $4 743 and array_length(regexp_split_to_array(objects.name, ''/''), 1) <> $1 744 group by folder 745 order by folder ' || v_sort_order || ' 746 ) 747 (select folder as "name", 748 null as id, 749 null as updated_at, 750 null as created_at, 751 null as last_accessed_at, 752 null as metadata from folders) 753 union all 754 (select path_tokens[$1] as "name", 755 id, 756 updated_at, 757 created_at, 758 last_accessed_at, 759 metadata 760 from storage.objects 761 where objects.name ilike $2 || $3 || ''%'' 762 and bucket_id = $4 763 and array_length(regexp_split_to_array(objects.name, ''/''), 1) = $1 764 order by ' || v_order_by || ') 765 limit $5 766 offset $6' using levels, prefix, search, bucketname, limits, offsets; 767 end; 768 $_$; 769 770 771 ALTER FUNCTION storage.search(prefix text, bucketname text, limits integer, levels integer, offsets integer, search text, sortcolumn text, sortorder text) OWNER TO supabase_storage_admin; 772 773 -- 774 -- Name: update_updated_at_column(); Type: FUNCTION; Schema: storage; Owner: supabase_storage_admin 775 -- 776 777 CREATE OR REPLACE FUNCTION storage.update_updated_at_column() RETURNS trigger 778 LANGUAGE plpgsql 779 AS $$ 780 BEGIN 781 NEW.updated_at = now(); 782 RETURN NEW; 783 END; 784 $$; 785 786 787 ALTER FUNCTION storage.update_updated_at_column() OWNER TO supabase_storage_admin; 788 789 SET default_tablespace = ''; 790 791 SET default_table_access_method = heap; 792 793 -- 794 -- Name: extensions; Type: TABLE; Schema: _realtime; Owner: postgres 795 -- 796 797 CREATE TABLE IF NOT EXISTS _realtime.extensions ( 798 id uuid NOT NULL, 799 type character varying(255), 800 settings jsonb, 801 tenant_external_id character varying(255), 802 inserted_at timestamp(0) without time zone NOT NULL, 803 updated_at timestamp(0) without time zone NOT NULL 804 ); 805 806 807 ALTER TABLE _realtime.extensions OWNER TO postgres; 808 809 -- 810 -- Name: schema_migrations; Type: TABLE; Schema: _realtime; Owner: postgres 811 -- 812 813 CREATE TABLE IF NOT EXISTS _realtime.schema_migrations ( 814 version bigint NOT NULL, 815 inserted_at timestamp(0) without time zone 816 ); 817 818 819 ALTER TABLE _realtime.schema_migrations OWNER TO postgres; 820 821 -- 822 -- Name: tenants; Type: TABLE; Schema: _realtime; Owner: postgres 823 -- 824 825 CREATE TABLE IF NOT EXISTS _realtime.tenants ( 826 id uuid NOT NULL, 827 name character varying(255), 828 external_id character varying(255), 829 jwt_secret character varying(500), 830 max_concurrent_users integer DEFAULT 200 NOT NULL, 831 inserted_at timestamp(0) without time zone NOT NULL, 832 updated_at timestamp(0) without time zone NOT NULL, 833 max_events_per_second integer DEFAULT 100 NOT NULL, 834 postgres_cdc_default character varying(255) DEFAULT 'postgres_cdc_rls'::character varying, 835 max_bytes_per_second integer DEFAULT 100000 NOT NULL, 836 max_channels_per_client integer DEFAULT 100 NOT NULL, 837 max_joins_per_second integer DEFAULT 500 NOT NULL 838 ); 839 840 841 ALTER TABLE _realtime.tenants OWNER TO postgres; 842 843 -- 844 -- Name: audit_log_entries; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 845 -- 846 847 CREATE TABLE IF NOT EXISTS auth.audit_log_entries ( 848 instance_id uuid, 849 id uuid NOT NULL, 850 payload json, 851 created_at timestamp with time zone, 852 ip_address character varying(64) DEFAULT ''::character varying NOT NULL 853 ); 854 855 856 ALTER TABLE auth.audit_log_entries OWNER TO supabase_auth_admin; 857 858 -- 859 -- Name: TABLE audit_log_entries; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 860 -- 861 862 COMMENT ON TABLE auth.audit_log_entries IS 'Auth: Audit trail for user actions.'; 863 864 865 -- 866 -- Name: identities; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 867 -- 868 869 CREATE TABLE IF NOT EXISTS auth.identities ( 870 id text NOT NULL, 871 user_id uuid NOT NULL, 872 identity_data jsonb NOT NULL, 873 provider text NOT NULL, 874 last_sign_in_at timestamp with time zone, 875 created_at timestamp with time zone, 876 updated_at timestamp with time zone, 877 email text GENERATED ALWAYS AS (lower((identity_data ->> 'email'::text))) STORED 878 ); 879 880 881 ALTER TABLE auth.identities OWNER TO supabase_auth_admin; 882 883 -- 884 -- Name: TABLE identities; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 885 -- 886 887 COMMENT ON TABLE auth.identities IS 'Auth: Stores identities associated to a user.'; 888 889 890 -- 891 -- Name: COLUMN identities.email; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 892 -- 893 894 COMMENT ON COLUMN auth.identities.email IS 'Auth: Email is a generated column that references the optional email property in the identity_data'; 895 896 897 -- 898 -- Name: instances; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 899 -- 900 901 CREATE TABLE IF NOT EXISTS auth.instances ( 902 id uuid NOT NULL, 903 uuid uuid, 904 raw_base_config text, 905 created_at timestamp with time zone, 906 updated_at timestamp with time zone 907 ); 908 909 910 ALTER TABLE auth.instances OWNER TO supabase_auth_admin; 911 912 -- 913 -- Name: TABLE instances; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 914 -- 915 916 COMMENT ON TABLE auth.instances IS 'Auth: Manages users across multiple sites.'; 917 918 919 -- 920 -- Name: mfa_amr_claims; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 921 -- 922 923 CREATE TABLE IF NOT EXISTS auth.mfa_amr_claims ( 924 session_id uuid NOT NULL, 925 created_at timestamp with time zone NOT NULL, 926 updated_at timestamp with time zone NOT NULL, 927 authentication_method text NOT NULL, 928 id uuid NOT NULL 929 ); 930 931 932 ALTER TABLE auth.mfa_amr_claims OWNER TO supabase_auth_admin; 933 934 -- 935 -- Name: TABLE mfa_amr_claims; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 936 -- 937 938 COMMENT ON TABLE auth.mfa_amr_claims IS 'auth: stores authenticator method reference claims for multi factor authentication'; 939 940 941 -- 942 -- Name: mfa_challenges; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 943 -- 944 945 CREATE TABLE IF NOT EXISTS auth.mfa_challenges ( 946 id uuid NOT NULL, 947 factor_id uuid NOT NULL, 948 created_at timestamp with time zone NOT NULL, 949 verified_at timestamp with time zone, 950 ip_address inet NOT NULL 951 ); 952 953 954 ALTER TABLE auth.mfa_challenges OWNER TO supabase_auth_admin; 955 956 -- 957 -- Name: TABLE mfa_challenges; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 958 -- 959 960 COMMENT ON TABLE auth.mfa_challenges IS 'auth: stores metadata about challenge requests made'; 961 962 963 -- 964 -- Name: mfa_factors; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 965 -- 966 967 CREATE TABLE IF NOT EXISTS auth.mfa_factors ( 968 id uuid NOT NULL, 969 user_id uuid NOT NULL, 970 friendly_name text, 971 factor_type auth.factor_type NOT NULL, 972 status auth.factor_status NOT NULL, 973 created_at timestamp with time zone NOT NULL, 974 updated_at timestamp with time zone NOT NULL, 975 secret text 976 ); 977 978 979 ALTER TABLE auth.mfa_factors OWNER TO supabase_auth_admin; 980 981 -- 982 -- Name: TABLE mfa_factors; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 983 -- 984 985 COMMENT ON TABLE auth.mfa_factors IS 'auth: stores metadata about factors'; 986 987 988 -- 989 -- Name: refresh_tokens; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 990 -- 991 992 CREATE TABLE IF NOT EXISTS auth.refresh_tokens ( 993 instance_id uuid, 994 id bigint NOT NULL, 995 token character varying(255), 996 user_id character varying(255), 997 revoked boolean, 998 created_at timestamp with time zone, 999 updated_at timestamp with time zone, 1000 parent character varying(255), 1001 session_id uuid 1002 ); 1003 1004 1005 ALTER TABLE auth.refresh_tokens OWNER TO supabase_auth_admin; 1006 1007 -- 1008 -- Name: TABLE refresh_tokens; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1009 -- 1010 1011 COMMENT ON TABLE auth.refresh_tokens IS 'Auth: Store of tokens used to refresh JWT tokens once they expire.'; 1012 1013 1014 -- 1015 -- Name: refresh_tokens_id_seq; Type: SEQUENCE; Schema: auth; Owner: supabase_auth_admin 1016 -- 1017 1018 CREATE SEQUENCE IF NOT EXISTS auth.refresh_tokens_id_seq 1019 START WITH 1 1020 INCREMENT BY 1 1021 NO MINVALUE 1022 NO MAXVALUE 1023 CACHE 1; 1024 1025 1026 ALTER TABLE auth.refresh_tokens_id_seq OWNER TO supabase_auth_admin; 1027 1028 -- 1029 -- Name: refresh_tokens_id_seq; Type: SEQUENCE OWNED BY; Schema: auth; Owner: supabase_auth_admin 1030 -- 1031 1032 ALTER SEQUENCE auth.refresh_tokens_id_seq OWNED BY auth.refresh_tokens.id; 1033 1034 1035 -- 1036 -- Name: saml_providers; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1037 -- 1038 1039 CREATE TABLE IF NOT EXISTS auth.saml_providers ( 1040 id uuid NOT NULL, 1041 sso_provider_id uuid NOT NULL, 1042 entity_id text NOT NULL, 1043 metadata_xml text NOT NULL, 1044 metadata_url text, 1045 attribute_mapping jsonb, 1046 created_at timestamp with time zone, 1047 updated_at timestamp with time zone, 1048 CONSTRAINT "entity_id not empty" CHECK ((char_length(entity_id) > 0)), 1049 CONSTRAINT "metadata_url not empty" CHECK (((metadata_url = NULL::text) OR (char_length(metadata_url) > 0))), 1050 CONSTRAINT "metadata_xml not empty" CHECK ((char_length(metadata_xml) > 0)) 1051 ); 1052 1053 1054 ALTER TABLE auth.saml_providers OWNER TO supabase_auth_admin; 1055 1056 -- 1057 -- Name: TABLE saml_providers; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1058 -- 1059 1060 COMMENT ON TABLE auth.saml_providers IS 'Auth: Manages SAML Identity Provider connections.'; 1061 1062 1063 -- 1064 -- Name: saml_relay_states; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1065 -- 1066 1067 CREATE TABLE IF NOT EXISTS auth.saml_relay_states ( 1068 id uuid NOT NULL, 1069 sso_provider_id uuid NOT NULL, 1070 request_id text NOT NULL, 1071 for_email text, 1072 redirect_to text, 1073 from_ip_address inet, 1074 created_at timestamp with time zone, 1075 updated_at timestamp with time zone, 1076 CONSTRAINT "request_id not empty" CHECK ((char_length(request_id) > 0)) 1077 ); 1078 1079 1080 ALTER TABLE auth.saml_relay_states OWNER TO supabase_auth_admin; 1081 1082 -- 1083 -- Name: TABLE saml_relay_states; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1084 -- 1085 1086 COMMENT ON TABLE auth.saml_relay_states IS 'Auth: Contains SAML Relay State information for each Service Provider initiated login.'; 1087 1088 1089 -- 1090 -- Name: schema_migrations; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1091 -- 1092 1093 CREATE TABLE IF NOT EXISTS auth.schema_migrations ( 1094 version character varying(255) NOT NULL 1095 ); 1096 1097 1098 ALTER TABLE auth.schema_migrations OWNER TO supabase_auth_admin; 1099 1100 -- 1101 -- Name: TABLE schema_migrations; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1102 -- 1103 1104 COMMENT ON TABLE auth.schema_migrations IS 'Auth: Manages updates to the auth system.'; 1105 1106 1107 -- 1108 -- Name: sessions; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1109 -- 1110 1111 CREATE TABLE IF NOT EXISTS auth.sessions ( 1112 id uuid NOT NULL, 1113 user_id uuid NOT NULL, 1114 created_at timestamp with time zone, 1115 updated_at timestamp with time zone, 1116 factor_id uuid, 1117 aal auth.aal_level, 1118 not_after timestamp with time zone 1119 ); 1120 1121 1122 ALTER TABLE auth.sessions OWNER TO supabase_auth_admin; 1123 1124 -- 1125 -- Name: TABLE sessions; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1126 -- 1127 1128 COMMENT ON TABLE auth.sessions IS 'Auth: Stores session data associated to a user.'; 1129 1130 1131 -- 1132 -- Name: COLUMN sessions.not_after; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1133 -- 1134 1135 COMMENT ON COLUMN auth.sessions.not_after IS 'Auth: Not after is a nullable column that contains a timestamp after which the session should be regarded as expired.'; 1136 1137 1138 -- 1139 -- Name: sso_domains; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1140 -- 1141 1142 CREATE TABLE IF NOT EXISTS auth.sso_domains ( 1143 id uuid NOT NULL, 1144 sso_provider_id uuid NOT NULL, 1145 domain text NOT NULL, 1146 created_at timestamp with time zone, 1147 updated_at timestamp with time zone, 1148 CONSTRAINT "domain not empty" CHECK ((char_length(domain) > 0)) 1149 ); 1150 1151 1152 ALTER TABLE auth.sso_domains OWNER TO supabase_auth_admin; 1153 1154 -- 1155 -- Name: TABLE sso_domains; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1156 -- 1157 1158 COMMENT ON TABLE auth.sso_domains IS 'Auth: Manages SSO email address domain mapping to an SSO Identity Provider.'; 1159 1160 1161 -- 1162 -- Name: sso_providers; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1163 -- 1164 1165 CREATE TABLE IF NOT EXISTS auth.sso_providers ( 1166 id uuid NOT NULL, 1167 resource_id text, 1168 created_at timestamp with time zone, 1169 updated_at timestamp with time zone, 1170 CONSTRAINT "resource_id not empty" CHECK (((resource_id = NULL::text) OR (char_length(resource_id) > 0))) 1171 ); 1172 1173 1174 ALTER TABLE auth.sso_providers OWNER TO supabase_auth_admin; 1175 1176 -- 1177 -- Name: TABLE sso_providers; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1178 -- 1179 1180 COMMENT ON TABLE auth.sso_providers IS 'Auth: Manages SSO identity provider information; see saml_providers for SAML.'; 1181 1182 1183 -- 1184 -- Name: COLUMN sso_providers.resource_id; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1185 -- 1186 1187 COMMENT ON COLUMN auth.sso_providers.resource_id IS 'Auth: Uniquely identifies a SSO provider according to a user-chosen resource ID (case insensitive), useful in infrastructure as code.'; 1188 1189 1190 -- 1191 -- Name: users; Type: TABLE; Schema: auth; Owner: supabase_auth_admin 1192 -- 1193 1194 CREATE TABLE IF NOT EXISTS auth.users ( 1195 instance_id uuid, 1196 id uuid NOT NULL, 1197 aud character varying(255), 1198 role character varying(255), 1199 email character varying(255), 1200 encrypted_password character varying(255), 1201 email_confirmed_at timestamp with time zone, 1202 invited_at timestamp with time zone, 1203 confirmation_token character varying(255), 1204 confirmation_sent_at timestamp with time zone, 1205 recovery_token character varying(255), 1206 recovery_sent_at timestamp with time zone, 1207 email_change_token_new character varying(255), 1208 email_change character varying(255), 1209 email_change_sent_at timestamp with time zone, 1210 last_sign_in_at timestamp with time zone, 1211 raw_app_meta_data jsonb, 1212 raw_user_meta_data jsonb, 1213 is_super_admin boolean, 1214 created_at timestamp with time zone, 1215 updated_at timestamp with time zone, 1216 phone character varying(15) DEFAULT NULL::character varying, 1217 phone_confirmed_at timestamp with time zone, 1218 phone_change character varying(15) DEFAULT ''::character varying, 1219 phone_change_token character varying(255) DEFAULT ''::character varying, 1220 phone_change_sent_at timestamp with time zone, 1221 confirmed_at timestamp with time zone GENERATED ALWAYS AS (LEAST(email_confirmed_at, phone_confirmed_at)) STORED, 1222 email_change_token_current character varying(255) DEFAULT ''::character varying, 1223 email_change_confirm_status smallint DEFAULT 0, 1224 banned_until timestamp with time zone, 1225 reauthentication_token character varying(255) DEFAULT ''::character varying, 1226 reauthentication_sent_at timestamp with time zone, 1227 is_sso_user boolean DEFAULT false NOT NULL, 1228 CONSTRAINT users_email_change_confirm_status_check CHECK (((email_change_confirm_status >= 0) AND (email_change_confirm_status <= 2))) 1229 ); 1230 1231 1232 ALTER TABLE auth.users OWNER TO supabase_auth_admin; 1233 1234 -- 1235 -- Name: TABLE users; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1236 -- 1237 1238 COMMENT ON TABLE auth.users IS 'Auth: Stores user login data within a secure schema.'; 1239 1240 1241 -- 1242 -- Name: COLUMN users.is_sso_user; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1243 -- 1244 1245 COMMENT ON COLUMN auth.users.is_sso_user IS 'Auth: Set this column to true when the account comes from SSO. These accounts can have duplicate emails.'; 1246 1247 1248 -- 1249 -- Name: buckets; Type: TABLE; Schema: storage; Owner: supabase_storage_admin 1250 -- 1251 1252 CREATE TABLE IF NOT EXISTS storage.buckets ( 1253 id text NOT NULL, 1254 name text NOT NULL, 1255 owner uuid, 1256 created_at timestamp with time zone DEFAULT now(), 1257 updated_at timestamp with time zone DEFAULT now(), 1258 public boolean DEFAULT false 1259 ); 1260 1261 1262 ALTER TABLE storage.buckets OWNER TO supabase_storage_admin; 1263 1264 -- 1265 -- Name: migrations; Type: TABLE; Schema: storage; Owner: supabase_storage_admin 1266 -- 1267 1268 CREATE TABLE IF NOT EXISTS storage.migrations ( 1269 id integer NOT NULL, 1270 name character varying(100) NOT NULL, 1271 hash character varying(40) NOT NULL, 1272 executed_at timestamp without time zone DEFAULT CURRENT_TIMESTAMP 1273 ); 1274 1275 1276 ALTER TABLE storage.migrations OWNER TO supabase_storage_admin; 1277 1278 -- 1279 -- Name: objects; Type: TABLE; Schema: storage; Owner: supabase_storage_admin 1280 -- 1281 1282 CREATE TABLE IF NOT EXISTS storage.objects ( 1283 id uuid DEFAULT extensions.uuid_generate_v4() NOT NULL, 1284 bucket_id text, 1285 name text, 1286 owner uuid, 1287 created_at timestamp with time zone DEFAULT now(), 1288 updated_at timestamp with time zone DEFAULT now(), 1289 last_accessed_at timestamp with time zone DEFAULT now(), 1290 metadata jsonb, 1291 path_tokens text[] GENERATED ALWAYS AS (string_to_array(name, '/'::text)) STORED 1292 ); 1293 1294 1295 ALTER TABLE storage.objects OWNER TO supabase_storage_admin; 1296 1297 -- 1298 -- Name: refresh_tokens id; Type: DEFAULT; Schema: auth; Owner: supabase_auth_admin 1299 -- 1300 1301 ALTER TABLE ONLY auth.refresh_tokens ALTER COLUMN id SET DEFAULT nextval('auth.refresh_tokens_id_seq'::regclass); 1302 1303 1304 -- 1305 -- Data for Name: extensions; Type: TABLE DATA; Schema: _realtime; Owner: postgres 1306 -- 1307 1308 INSERT INTO _realtime.extensions (id, type, settings, tenant_external_id, inserted_at, updated_at) VALUES ('1d784f3e-9e48-45ac-9d56-50f8b39d5c64', 'postgres_cdc_rls', '{"region": "us-east-1", "db_host": "ABK7kBu27y/PVdL10i/b+A==", "db_name": "sWBpZNdjggEPTQVlI52Zfw==", "db_port": "+enMDFi1J/3IrrquHHwUmA==", "db_user": "sWBpZNdjggEPTQVlI52Zfw==", "slot_name": "supabase_realtime_replication_slot", "ip_version": 4, "db_password": "sWBpZNdjggEPTQVlI52Zfw==", "publication": "supabase_realtime", "poll_interval_ms": 100, "poll_max_changes": 100, "poll_max_record_bytes": 1048576}', 'realtime-dev', '2023-01-05 05:01:34', '2023-01-05 05:01:34'); 1309 1310 1311 -- 1312 -- Data for Name: schema_migrations; Type: TABLE DATA; Schema: _realtime; Owner: postgres 1313 -- 1314 1315 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20210706140551, '2023-01-30 04:09:10'); 1316 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220329161857, '2023-01-30 04:09:10'); 1317 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220410212326, '2023-01-30 04:09:10'); 1318 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220506102948, '2023-01-30 04:09:10'); 1319 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220527210857, '2023-01-30 04:09:10'); 1320 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220815211129, '2023-01-30 04:09:10'); 1321 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220815215024, '2023-01-30 04:09:10'); 1322 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20220818141501, '2023-01-30 04:09:10'); 1323 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20221018173709, '2023-01-30 04:09:10'); 1324 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20221102172703, '2023-01-30 04:09:10'); 1325 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20221223010058, '2023-01-30 04:09:10'); 1326 INSERT INTO _realtime.schema_migrations (version, inserted_at) VALUES (20230110180046, '2023-01-30 04:09:10'); 1327 1328 1329 -- 1330 -- Data for Name: tenants; Type: TABLE DATA; Schema: _realtime; Owner: postgres 1331 -- 1332 1333 INSERT INTO _realtime.tenants (id, name, external_id, jwt_secret, max_concurrent_users, inserted_at, updated_at, max_events_per_second, postgres_cdc_default, max_bytes_per_second, max_channels_per_client, max_joins_per_second) VALUES ('bb4a1909-7f48-42b5-9814-68ebb2d065b9', 'realtime-dev', 'realtime-dev', 'iNjicxc4+llvc9wovDvqymwfnj9teWMlyOIbJ8Fh6j2WNU8CIJ2ZgjR6MUIKqSmeDmvpsKLsZ9jgXJmQPpwL8w==', 200, '2023-01-30 04:09:12', '2023-01-30 04:09:12', 100, 'postgres_cdc_rls', 100000, 100, 500); 1334 1335 1336 -- 1337 -- Data for Name: audit_log_entries; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1338 -- 1339 1340 1341 1342 -- 1343 -- Data for Name: identities; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1344 -- 1345 1346 1347 1348 -- 1349 -- Data for Name: instances; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1350 -- 1351 1352 1353 1354 -- 1355 -- Data for Name: mfa_amr_claims; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1356 -- 1357 1358 1359 1360 -- 1361 -- Data for Name: mfa_challenges; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1362 -- 1363 1364 1365 1366 -- 1367 -- Data for Name: mfa_factors; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1368 -- 1369 1370 1371 1372 -- 1373 -- Data for Name: refresh_tokens; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1374 -- 1375 1376 1377 1378 -- 1379 -- Data for Name: saml_providers; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1380 -- 1381 1382 1383 1384 -- 1385 -- Data for Name: saml_relay_states; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1386 -- 1387 1388 1389 1390 -- 1391 -- Data for Name: schema_migrations; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1392 -- 1393 1394 INSERT INTO auth.schema_migrations (version) VALUES ('20171026211738'); 1395 INSERT INTO auth.schema_migrations (version) VALUES ('20171026211808'); 1396 INSERT INTO auth.schema_migrations (version) VALUES ('20171026211834'); 1397 INSERT INTO auth.schema_migrations (version) VALUES ('20180103212743'); 1398 INSERT INTO auth.schema_migrations (version) VALUES ('20180108183307'); 1399 INSERT INTO auth.schema_migrations (version) VALUES ('20180119214651'); 1400 INSERT INTO auth.schema_migrations (version) VALUES ('20180125194653'); 1401 INSERT INTO auth.schema_migrations (version) VALUES ('00'); 1402 INSERT INTO auth.schema_migrations (version) VALUES ('20210710035447'); 1403 INSERT INTO auth.schema_migrations (version) VALUES ('20210722035447'); 1404 INSERT INTO auth.schema_migrations (version) VALUES ('20210730183235'); 1405 INSERT INTO auth.schema_migrations (version) VALUES ('20210909172000'); 1406 INSERT INTO auth.schema_migrations (version) VALUES ('20210927181326'); 1407 INSERT INTO auth.schema_migrations (version) VALUES ('20211122151130'); 1408 INSERT INTO auth.schema_migrations (version) VALUES ('20211124214934'); 1409 INSERT INTO auth.schema_migrations (version) VALUES ('20211202183645'); 1410 INSERT INTO auth.schema_migrations (version) VALUES ('20220114185221'); 1411 INSERT INTO auth.schema_migrations (version) VALUES ('20220114185340'); 1412 INSERT INTO auth.schema_migrations (version) VALUES ('20220224000811'); 1413 INSERT INTO auth.schema_migrations (version) VALUES ('20220323170000'); 1414 INSERT INTO auth.schema_migrations (version) VALUES ('20220429102000'); 1415 INSERT INTO auth.schema_migrations (version) VALUES ('20220531120530'); 1416 INSERT INTO auth.schema_migrations (version) VALUES ('20220614074223'); 1417 INSERT INTO auth.schema_migrations (version) VALUES ('20220811173540'); 1418 INSERT INTO auth.schema_migrations (version) VALUES ('20221003041349'); 1419 INSERT INTO auth.schema_migrations (version) VALUES ('20221003041400'); 1420 INSERT INTO auth.schema_migrations (version) VALUES ('20221011041400'); 1421 INSERT INTO auth.schema_migrations (version) VALUES ('20221020193600'); 1422 INSERT INTO auth.schema_migrations (version) VALUES ('20221021073300'); 1423 INSERT INTO auth.schema_migrations (version) VALUES ('20221021082433'); 1424 INSERT INTO auth.schema_migrations (version) VALUES ('20221027105023'); 1425 INSERT INTO auth.schema_migrations (version) VALUES ('20221114143122'); 1426 INSERT INTO auth.schema_migrations (version) VALUES ('20221114143410'); 1427 INSERT INTO auth.schema_migrations (version) VALUES ('20221125140132'); 1428 INSERT INTO auth.schema_migrations (version) VALUES ('20221208132122'); 1429 INSERT INTO auth.schema_migrations (version) VALUES ('20221215195500'); 1430 INSERT INTO auth.schema_migrations (version) VALUES ('20221215195800'); 1431 INSERT INTO auth.schema_migrations (version) VALUES ('20221215195900'); 1432 1433 1434 -- 1435 -- Data for Name: sessions; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1436 -- 1437 1438 1439 1440 -- 1441 -- Data for Name: sso_domains; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1442 -- 1443 1444 1445 1446 -- 1447 -- Data for Name: sso_providers; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1448 -- 1449 1450 1451 1452 -- 1453 -- Data for Name: users; Type: TABLE DATA; Schema: auth; Owner: supabase_auth_admin 1454 -- 1455 1456 1457 1458 -- 1459 -- Data for Name: buckets; Type: TABLE DATA; Schema: storage; Owner: supabase_storage_admin 1460 -- 1461 1462 1463 1464 -- 1465 -- Data for Name: migrations; Type: TABLE DATA; Schema: storage; Owner: supabase_storage_admin 1466 -- 1467 1468 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (0, 'create-migrations-table', 'e18db593bcde2aca2a408c4d1100f6abba2195df', '2022-12-14 17:16:56.385073'); 1469 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (1, 'initialmigration', '6ab16121fbaa08bbd11b712d05f358f9b555d777', '2022-12-14 17:16:56.393739'); 1470 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (2, 'pathtoken-column', '49756be03be4c17bb85fe70d4a861f27de7e49ad', '2022-12-14 17:16:56.398583'); 1471 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (3, 'add-migrations-rls', 'bb5d124c53d68635a883e399426c6a5a25fc893d', '2022-12-14 17:16:56.429952'); 1472 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (4, 'add-size-functions', '6d79007d04f5acd288c9c250c42d2d5fd286c54d', '2022-12-14 17:16:56.443332'); 1473 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (5, 'change-column-name-in-get-size', 'fd65688505d2ffa9fbdc58a944348dd8604d688c', '2022-12-14 17:16:56.452704'); 1474 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (6, 'add-rls-to-buckets', '63e2bab75a2040fee8e3fb3f15a0d26f3380e9b6', '2022-12-14 17:16:56.459977'); 1475 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (7, 'add-public-to-buckets', '82568934f8a4d9e0a85f126f6fb483ad8214c418', '2022-12-14 17:16:56.467924'); 1476 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (8, 'fix-search-function', '1a43a40eddb525f2e2f26efd709e6c06e58e059c', '2022-12-14 17:16:56.472925'); 1477 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (9, 'search-files-search-function', '34c096597eb8b9d077fdfdde9878c88501b2fafc', '2022-12-14 17:16:56.4773'); 1478 INSERT INTO storage.migrations (id, name, hash, executed_at) VALUES (10, 'add-trigger-to-auto-update-updated_at-column', '37d6bb964a70a822e6d37f22f457b9bca7885928', '2022-12-14 17:16:56.486363'); 1479 1480 1481 -- 1482 -- Data for Name: objects; Type: TABLE DATA; Schema: storage; Owner: supabase_storage_admin 1483 -- 1484 1485 1486 1487 -- 1488 -- Name: refresh_tokens_id_seq; Type: SEQUENCE SET; Schema: auth; Owner: supabase_auth_admin 1489 -- 1490 1491 SELECT pg_catalog.setval('auth.refresh_tokens_id_seq', 1, false); 1492 1493 1494 -- 1495 -- Name: extensions extensions_pkey; Type: CONSTRAINT; Schema: _realtime; Owner: postgres 1496 -- 1497 1498 ALTER TABLE ONLY _realtime.extensions 1499 ADD CONSTRAINT extensions_pkey PRIMARY KEY (id); 1500 1501 1502 -- 1503 -- Name: schema_migrations schema_migrations_pkey; Type: CONSTRAINT; Schema: _realtime; Owner: postgres 1504 -- 1505 1506 ALTER TABLE ONLY _realtime.schema_migrations 1507 ADD CONSTRAINT schema_migrations_pkey PRIMARY KEY (version); 1508 1509 1510 -- 1511 -- Name: tenants tenants_pkey; Type: CONSTRAINT; Schema: _realtime; Owner: postgres 1512 -- 1513 1514 ALTER TABLE ONLY _realtime.tenants 1515 ADD CONSTRAINT tenants_pkey PRIMARY KEY (id); 1516 1517 1518 -- 1519 -- Name: mfa_amr_claims amr_id_pk; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1520 -- 1521 1522 ALTER TABLE ONLY auth.mfa_amr_claims 1523 ADD CONSTRAINT amr_id_pk PRIMARY KEY (id); 1524 1525 1526 -- 1527 -- Name: audit_log_entries audit_log_entries_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1528 -- 1529 1530 ALTER TABLE ONLY auth.audit_log_entries 1531 ADD CONSTRAINT audit_log_entries_pkey PRIMARY KEY (id); 1532 1533 1534 -- 1535 -- Name: identities identities_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1536 -- 1537 1538 ALTER TABLE ONLY auth.identities 1539 ADD CONSTRAINT identities_pkey PRIMARY KEY (provider, id); 1540 1541 1542 -- 1543 -- Name: instances instances_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1544 -- 1545 1546 ALTER TABLE ONLY auth.instances 1547 ADD CONSTRAINT instances_pkey PRIMARY KEY (id); 1548 1549 1550 -- 1551 -- Name: mfa_amr_claims mfa_amr_claims_session_id_authentication_method_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1552 -- 1553 1554 ALTER TABLE ONLY auth.mfa_amr_claims 1555 ADD CONSTRAINT mfa_amr_claims_session_id_authentication_method_pkey UNIQUE (session_id, authentication_method); 1556 1557 1558 -- 1559 -- Name: mfa_challenges mfa_challenges_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1560 -- 1561 1562 ALTER TABLE ONLY auth.mfa_challenges 1563 ADD CONSTRAINT mfa_challenges_pkey PRIMARY KEY (id); 1564 1565 1566 -- 1567 -- Name: mfa_factors mfa_factors_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1568 -- 1569 1570 ALTER TABLE ONLY auth.mfa_factors 1571 ADD CONSTRAINT mfa_factors_pkey PRIMARY KEY (id); 1572 1573 1574 -- 1575 -- Name: refresh_tokens refresh_tokens_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1576 -- 1577 1578 ALTER TABLE ONLY auth.refresh_tokens 1579 ADD CONSTRAINT refresh_tokens_pkey PRIMARY KEY (id); 1580 1581 1582 -- 1583 -- Name: refresh_tokens refresh_tokens_token_unique; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1584 -- 1585 1586 ALTER TABLE ONLY auth.refresh_tokens 1587 ADD CONSTRAINT refresh_tokens_token_unique UNIQUE (token); 1588 1589 1590 -- 1591 -- Name: saml_providers saml_providers_entity_id_key; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1592 -- 1593 1594 ALTER TABLE ONLY auth.saml_providers 1595 ADD CONSTRAINT saml_providers_entity_id_key UNIQUE (entity_id); 1596 1597 1598 -- 1599 -- Name: saml_providers saml_providers_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1600 -- 1601 1602 ALTER TABLE ONLY auth.saml_providers 1603 ADD CONSTRAINT saml_providers_pkey PRIMARY KEY (id); 1604 1605 1606 -- 1607 -- Name: saml_relay_states saml_relay_states_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1608 -- 1609 1610 ALTER TABLE ONLY auth.saml_relay_states 1611 ADD CONSTRAINT saml_relay_states_pkey PRIMARY KEY (id); 1612 1613 1614 -- 1615 -- Name: schema_migrations schema_migrations_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1616 -- 1617 1618 ALTER TABLE ONLY auth.schema_migrations 1619 ADD CONSTRAINT schema_migrations_pkey PRIMARY KEY (version); 1620 1621 1622 -- 1623 -- Name: sessions sessions_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1624 -- 1625 1626 ALTER TABLE ONLY auth.sessions 1627 ADD CONSTRAINT sessions_pkey PRIMARY KEY (id); 1628 1629 1630 -- 1631 -- Name: sso_domains sso_domains_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1632 -- 1633 1634 ALTER TABLE ONLY auth.sso_domains 1635 ADD CONSTRAINT sso_domains_pkey PRIMARY KEY (id); 1636 1637 1638 -- 1639 -- Name: sso_providers sso_providers_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1640 -- 1641 1642 ALTER TABLE ONLY auth.sso_providers 1643 ADD CONSTRAINT sso_providers_pkey PRIMARY KEY (id); 1644 1645 1646 -- 1647 -- Name: users users_phone_key; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1648 -- 1649 1650 ALTER TABLE ONLY auth.users 1651 ADD CONSTRAINT users_phone_key UNIQUE (phone); 1652 1653 1654 -- 1655 -- Name: users users_pkey; Type: CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1656 -- 1657 1658 ALTER TABLE ONLY auth.users 1659 ADD CONSTRAINT users_pkey PRIMARY KEY (id); 1660 1661 1662 -- 1663 -- Name: buckets buckets_pkey; Type: CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 1664 -- 1665 1666 ALTER TABLE ONLY storage.buckets 1667 ADD CONSTRAINT buckets_pkey PRIMARY KEY (id); 1668 1669 1670 -- 1671 -- Name: migrations migrations_name_key; Type: CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 1672 -- 1673 1674 ALTER TABLE ONLY storage.migrations 1675 ADD CONSTRAINT migrations_name_key UNIQUE (name); 1676 1677 1678 -- 1679 -- Name: migrations migrations_pkey; Type: CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 1680 -- 1681 1682 ALTER TABLE ONLY storage.migrations 1683 ADD CONSTRAINT migrations_pkey PRIMARY KEY (id); 1684 1685 1686 -- 1687 -- Name: objects objects_pkey; Type: CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 1688 -- 1689 1690 ALTER TABLE ONLY storage.objects 1691 ADD CONSTRAINT objects_pkey PRIMARY KEY (id); 1692 1693 1694 -- 1695 -- Name: extensions_tenant_external_id_type_index; Type: INDEX; Schema: _realtime; Owner: postgres 1696 -- 1697 1698 CREATE UNIQUE INDEX extensions_tenant_external_id_type_index ON _realtime.extensions USING btree (tenant_external_id, type); 1699 1700 1701 -- 1702 -- Name: tenants_external_id_index; Type: INDEX; Schema: _realtime; Owner: postgres 1703 -- 1704 1705 CREATE UNIQUE INDEX tenants_external_id_index ON _realtime.tenants USING btree (external_id); 1706 1707 1708 -- 1709 -- Name: audit_logs_instance_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1710 -- 1711 1712 CREATE INDEX audit_logs_instance_id_idx ON auth.audit_log_entries USING btree (instance_id); 1713 1714 1715 -- 1716 -- Name: confirmation_token_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1717 -- 1718 1719 CREATE UNIQUE INDEX confirmation_token_idx ON auth.users USING btree (confirmation_token) WHERE ((confirmation_token)::text !~ '^[0-9 ]*$'::text); 1720 1721 1722 -- 1723 -- Name: email_change_token_current_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1724 -- 1725 1726 CREATE UNIQUE INDEX email_change_token_current_idx ON auth.users USING btree (email_change_token_current) WHERE ((email_change_token_current)::text !~ '^[0-9 ]*$'::text); 1727 1728 1729 -- 1730 -- Name: email_change_token_new_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1731 -- 1732 1733 CREATE UNIQUE INDEX email_change_token_new_idx ON auth.users USING btree (email_change_token_new) WHERE ((email_change_token_new)::text !~ '^[0-9 ]*$'::text); 1734 1735 1736 -- 1737 -- Name: factor_id_created_at_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1738 -- 1739 1740 CREATE INDEX factor_id_created_at_idx ON auth.mfa_factors USING btree (user_id, created_at); 1741 1742 1743 -- 1744 -- Name: identities_email_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1745 -- 1746 1747 CREATE INDEX identities_email_idx ON auth.identities USING btree (email text_pattern_ops); 1748 1749 1750 -- 1751 -- Name: INDEX identities_email_idx; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1752 -- 1753 1754 COMMENT ON INDEX auth.identities_email_idx IS 'Auth: Ensures indexed queries on the email column'; 1755 1756 1757 -- 1758 -- Name: identities_user_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1759 -- 1760 1761 CREATE INDEX identities_user_id_idx ON auth.identities USING btree (user_id); 1762 1763 1764 -- 1765 -- Name: mfa_factors_user_friendly_name_unique; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1766 -- 1767 1768 CREATE UNIQUE INDEX mfa_factors_user_friendly_name_unique ON auth.mfa_factors USING btree (friendly_name, user_id) WHERE (TRIM(BOTH FROM friendly_name) <> ''::text); 1769 1770 1771 -- 1772 -- Name: reauthentication_token_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1773 -- 1774 1775 CREATE UNIQUE INDEX reauthentication_token_idx ON auth.users USING btree (reauthentication_token) WHERE ((reauthentication_token)::text !~ '^[0-9 ]*$'::text); 1776 1777 1778 -- 1779 -- Name: recovery_token_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1780 -- 1781 1782 CREATE UNIQUE INDEX recovery_token_idx ON auth.users USING btree (recovery_token) WHERE ((recovery_token)::text !~ '^[0-9 ]*$'::text); 1783 1784 1785 -- 1786 -- Name: refresh_tokens_instance_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1787 -- 1788 1789 CREATE INDEX refresh_tokens_instance_id_idx ON auth.refresh_tokens USING btree (instance_id); 1790 1791 1792 -- 1793 -- Name: refresh_tokens_instance_id_user_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1794 -- 1795 1796 CREATE INDEX refresh_tokens_instance_id_user_id_idx ON auth.refresh_tokens USING btree (instance_id, user_id); 1797 1798 1799 -- 1800 -- Name: refresh_tokens_parent_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1801 -- 1802 1803 CREATE INDEX refresh_tokens_parent_idx ON auth.refresh_tokens USING btree (parent); 1804 1805 1806 -- 1807 -- Name: refresh_tokens_session_id_revoked_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1808 -- 1809 1810 CREATE INDEX refresh_tokens_session_id_revoked_idx ON auth.refresh_tokens USING btree (session_id, revoked); 1811 1812 1813 -- 1814 -- Name: refresh_tokens_token_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1815 -- 1816 1817 CREATE INDEX refresh_tokens_token_idx ON auth.refresh_tokens USING btree (token); 1818 1819 1820 -- 1821 -- Name: saml_providers_sso_provider_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1822 -- 1823 1824 CREATE INDEX saml_providers_sso_provider_id_idx ON auth.saml_providers USING btree (sso_provider_id); 1825 1826 1827 -- 1828 -- Name: saml_relay_states_for_email_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1829 -- 1830 1831 CREATE INDEX saml_relay_states_for_email_idx ON auth.saml_relay_states USING btree (for_email); 1832 1833 1834 -- 1835 -- Name: saml_relay_states_sso_provider_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1836 -- 1837 1838 CREATE INDEX saml_relay_states_sso_provider_id_idx ON auth.saml_relay_states USING btree (sso_provider_id); 1839 1840 1841 -- 1842 -- Name: sessions_user_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1843 -- 1844 1845 CREATE INDEX sessions_user_id_idx ON auth.sessions USING btree (user_id); 1846 1847 1848 -- 1849 -- Name: sso_domains_domain_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1850 -- 1851 1852 CREATE UNIQUE INDEX sso_domains_domain_idx ON auth.sso_domains USING btree (lower(domain)); 1853 1854 1855 -- 1856 -- Name: sso_domains_sso_provider_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1857 -- 1858 1859 CREATE INDEX sso_domains_sso_provider_id_idx ON auth.sso_domains USING btree (sso_provider_id); 1860 1861 1862 -- 1863 -- Name: sso_providers_resource_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1864 -- 1865 1866 CREATE UNIQUE INDEX sso_providers_resource_id_idx ON auth.sso_providers USING btree (lower(resource_id)); 1867 1868 1869 -- 1870 -- Name: user_id_created_at_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1871 -- 1872 1873 CREATE INDEX user_id_created_at_idx ON auth.sessions USING btree (user_id, created_at); 1874 1875 1876 -- 1877 -- Name: users_email_partial_key; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1878 -- 1879 1880 CREATE UNIQUE INDEX users_email_partial_key ON auth.users USING btree (email) WHERE (is_sso_user = false); 1881 1882 1883 -- 1884 -- Name: INDEX users_email_partial_key; Type: COMMENT; Schema: auth; Owner: supabase_auth_admin 1885 -- 1886 1887 COMMENT ON INDEX auth.users_email_partial_key IS 'Auth: A partial unique index that applies only when is_sso_user is false'; 1888 1889 1890 -- 1891 -- Name: users_instance_id_email_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1892 -- 1893 1894 CREATE INDEX users_instance_id_email_idx ON auth.users USING btree (instance_id, lower((email)::text)); 1895 1896 1897 -- 1898 -- Name: users_instance_id_idx; Type: INDEX; Schema: auth; Owner: supabase_auth_admin 1899 -- 1900 1901 CREATE INDEX users_instance_id_idx ON auth.users USING btree (instance_id); 1902 1903 1904 -- 1905 -- Name: bname; Type: INDEX; Schema: storage; Owner: supabase_storage_admin 1906 -- 1907 1908 CREATE UNIQUE INDEX bname ON storage.buckets USING btree (name); 1909 1910 1911 -- 1912 -- Name: bucketid_objname; Type: INDEX; Schema: storage; Owner: supabase_storage_admin 1913 -- 1914 1915 CREATE UNIQUE INDEX bucketid_objname ON storage.objects USING btree (bucket_id, name); 1916 1917 1918 -- 1919 -- Name: name_prefix_search; Type: INDEX; Schema: storage; Owner: supabase_storage_admin 1920 -- 1921 1922 CREATE INDEX name_prefix_search ON storage.objects USING btree (name text_pattern_ops); 1923 1924 1925 -- 1926 -- Name: objects update_objects_updated_at; Type: TRIGGER; Schema: storage; Owner: supabase_storage_admin 1927 -- 1928 1929 CREATE TRIGGER update_objects_updated_at BEFORE UPDATE ON storage.objects FOR EACH ROW EXECUTE FUNCTION storage.update_updated_at_column(); 1930 1931 1932 -- 1933 -- Name: extensions extensions_tenant_external_id_fkey; Type: FK CONSTRAINT; Schema: _realtime; Owner: postgres 1934 -- 1935 1936 ALTER TABLE ONLY _realtime.extensions 1937 ADD CONSTRAINT extensions_tenant_external_id_fkey FOREIGN KEY (tenant_external_id) REFERENCES _realtime.tenants(external_id) ON DELETE CASCADE; 1938 1939 1940 -- 1941 -- Name: identities identities_user_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1942 -- 1943 1944 ALTER TABLE ONLY auth.identities 1945 ADD CONSTRAINT identities_user_id_fkey FOREIGN KEY (user_id) REFERENCES auth.users(id) ON DELETE CASCADE; 1946 1947 1948 -- 1949 -- Name: mfa_amr_claims mfa_amr_claims_session_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1950 -- 1951 1952 ALTER TABLE ONLY auth.mfa_amr_claims 1953 ADD CONSTRAINT mfa_amr_claims_session_id_fkey FOREIGN KEY (session_id) REFERENCES auth.sessions(id) ON DELETE CASCADE; 1954 1955 1956 -- 1957 -- Name: mfa_challenges mfa_challenges_auth_factor_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1958 -- 1959 1960 ALTER TABLE ONLY auth.mfa_challenges 1961 ADD CONSTRAINT mfa_challenges_auth_factor_id_fkey FOREIGN KEY (factor_id) REFERENCES auth.mfa_factors(id) ON DELETE CASCADE; 1962 1963 1964 -- 1965 -- Name: mfa_factors mfa_factors_user_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1966 -- 1967 1968 ALTER TABLE ONLY auth.mfa_factors 1969 ADD CONSTRAINT mfa_factors_user_id_fkey FOREIGN KEY (user_id) REFERENCES auth.users(id) ON DELETE CASCADE; 1970 1971 1972 -- 1973 -- Name: refresh_tokens refresh_tokens_session_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1974 -- 1975 1976 ALTER TABLE ONLY auth.refresh_tokens 1977 ADD CONSTRAINT refresh_tokens_session_id_fkey FOREIGN KEY (session_id) REFERENCES auth.sessions(id) ON DELETE CASCADE; 1978 1979 1980 -- 1981 -- Name: saml_providers saml_providers_sso_provider_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1982 -- 1983 1984 ALTER TABLE ONLY auth.saml_providers 1985 ADD CONSTRAINT saml_providers_sso_provider_id_fkey FOREIGN KEY (sso_provider_id) REFERENCES auth.sso_providers(id) ON DELETE CASCADE; 1986 1987 1988 -- 1989 -- Name: saml_relay_states saml_relay_states_sso_provider_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1990 -- 1991 1992 ALTER TABLE ONLY auth.saml_relay_states 1993 ADD CONSTRAINT saml_relay_states_sso_provider_id_fkey FOREIGN KEY (sso_provider_id) REFERENCES auth.sso_providers(id) ON DELETE CASCADE; 1994 1995 1996 -- 1997 -- Name: sessions sessions_user_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 1998 -- 1999 2000 ALTER TABLE ONLY auth.sessions 2001 ADD CONSTRAINT sessions_user_id_fkey FOREIGN KEY (user_id) REFERENCES auth.users(id) ON DELETE CASCADE; 2002 2003 2004 -- 2005 -- Name: sso_domains sso_domains_sso_provider_id_fkey; Type: FK CONSTRAINT; Schema: auth; Owner: supabase_auth_admin 2006 -- 2007 2008 ALTER TABLE ONLY auth.sso_domains 2009 ADD CONSTRAINT sso_domains_sso_provider_id_fkey FOREIGN KEY (sso_provider_id) REFERENCES auth.sso_providers(id) ON DELETE CASCADE; 2010 2011 2012 -- 2013 -- Name: buckets buckets_owner_fkey; Type: FK CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 2014 -- 2015 2016 ALTER TABLE ONLY storage.buckets 2017 ADD CONSTRAINT buckets_owner_fkey FOREIGN KEY (owner) REFERENCES auth.users(id); 2018 2019 2020 -- 2021 -- Name: objects objects_bucketId_fkey; Type: FK CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 2022 -- 2023 2024 ALTER TABLE ONLY storage.objects 2025 ADD CONSTRAINT "objects_bucketId_fkey" FOREIGN KEY (bucket_id) REFERENCES storage.buckets(id); 2026 2027 2028 -- 2029 -- Name: objects objects_owner_fkey; Type: FK CONSTRAINT; Schema: storage; Owner: supabase_storage_admin 2030 -- 2031 2032 ALTER TABLE ONLY storage.objects 2033 ADD CONSTRAINT objects_owner_fkey FOREIGN KEY (owner) REFERENCES auth.users(id); 2034 2035 2036 -- 2037 -- Name: buckets; Type: ROW SECURITY; Schema: storage; Owner: supabase_storage_admin 2038 -- 2039 2040 ALTER TABLE storage.buckets ENABLE ROW LEVEL SECURITY; 2041 2042 -- 2043 -- Name: migrations; Type: ROW SECURITY; Schema: storage; Owner: supabase_storage_admin 2044 -- 2045 2046 ALTER TABLE storage.migrations ENABLE ROW LEVEL SECURITY; 2047 2048 -- 2049 -- Name: objects; Type: ROW SECURITY; Schema: storage; Owner: supabase_storage_admin 2050 -- 2051 2052 ALTER TABLE storage.objects ENABLE ROW LEVEL SECURITY; 2053 2054 -- 2055 -- Name: supabase_realtime; Type: PUBLICATION; Schema: -; Owner: postgres 2056 -- 2057 2058 CREATE PUBLICATION supabase_realtime WITH (publish = 'insert, update, delete, truncate'); 2059 2060 2061 ALTER PUBLICATION supabase_realtime OWNER TO postgres; 2062 2063 -- 2064 -- Name: SCHEMA auth; Type: ACL; Schema: -; Owner: supabase_admin 2065 -- 2066 2067 GRANT USAGE ON SCHEMA auth TO anon; 2068 GRANT USAGE ON SCHEMA auth TO authenticated; 2069 GRANT USAGE ON SCHEMA auth TO service_role; 2070 GRANT ALL ON SCHEMA auth TO supabase_auth_admin; 2071 GRANT ALL ON SCHEMA auth TO dashboard_user; 2072 GRANT ALL ON SCHEMA auth TO postgres; 2073 2074 2075 -- 2076 -- Name: SCHEMA extensions; Type: ACL; Schema: -; Owner: postgres 2077 -- 2078 2079 GRANT USAGE ON SCHEMA extensions TO anon; 2080 GRANT USAGE ON SCHEMA extensions TO authenticated; 2081 GRANT USAGE ON SCHEMA extensions TO service_role; 2082 GRANT ALL ON SCHEMA extensions TO dashboard_user; 2083 2084 2085 -- 2086 -- Name: SCHEMA graphql_public; Type: ACL; Schema: -; Owner: supabase_admin 2087 -- 2088 2089 GRANT USAGE ON SCHEMA graphql_public TO postgres; 2090 GRANT USAGE ON SCHEMA graphql_public TO anon; 2091 GRANT USAGE ON SCHEMA graphql_public TO authenticated; 2092 GRANT USAGE ON SCHEMA graphql_public TO service_role; 2093 2094 2095 -- 2096 -- Name: SCHEMA public; Type: ACL; Schema: -; Owner: pg_database_owner 2097 -- 2098 2099 GRANT USAGE ON SCHEMA public TO postgres; 2100 GRANT USAGE ON SCHEMA public TO anon; 2101 GRANT USAGE ON SCHEMA public TO authenticated; 2102 GRANT USAGE ON SCHEMA public TO service_role; 2103 2104 2105 -- 2106 -- Name: SCHEMA realtime; Type: ACL; Schema: -; Owner: supabase_admin 2107 -- 2108 2109 GRANT USAGE ON SCHEMA realtime TO postgres; 2110 2111 2112 -- 2113 -- Name: SCHEMA storage; Type: ACL; Schema: -; Owner: supabase_admin 2114 -- 2115 2116 GRANT ALL ON SCHEMA storage TO postgres; 2117 GRANT USAGE ON SCHEMA storage TO anon; 2118 GRANT USAGE ON SCHEMA storage TO authenticated; 2119 GRANT USAGE ON SCHEMA storage TO service_role; 2120 GRANT ALL ON SCHEMA storage TO supabase_storage_admin; 2121 GRANT ALL ON SCHEMA storage TO dashboard_user; 2122 2123 2124 -- 2125 -- Name: FUNCTION email(); Type: ACL; Schema: auth; Owner: supabase_auth_admin 2126 -- 2127 2128 GRANT ALL ON FUNCTION auth.email() TO dashboard_user; 2129 2130 2131 -- 2132 -- Name: FUNCTION jwt(); Type: ACL; Schema: auth; Owner: supabase_auth_admin 2133 -- 2134 2135 GRANT ALL ON FUNCTION auth.jwt() TO postgres; 2136 GRANT ALL ON FUNCTION auth.jwt() TO dashboard_user; 2137 2138 2139 -- 2140 -- Name: FUNCTION role(); Type: ACL; Schema: auth; Owner: supabase_auth_admin 2141 -- 2142 2143 GRANT ALL ON FUNCTION auth.role() TO dashboard_user; 2144 2145 2146 -- 2147 -- Name: FUNCTION uid(); Type: ACL; Schema: auth; Owner: supabase_auth_admin 2148 -- 2149 2150 GRANT ALL ON FUNCTION auth.uid() TO dashboard_user; 2151 2152 2153 -- 2154 -- Name: FUNCTION algorithm_sign(signables text, secret text, algorithm text); Type: ACL; Schema: extensions; Owner: postgres 2155 -- 2156 2157 GRANT ALL ON FUNCTION extensions.algorithm_sign(signables text, secret text, algorithm text) TO dashboard_user; 2158 2159 2160 -- 2161 -- Name: FUNCTION armor(bytea); Type: ACL; Schema: extensions; Owner: postgres 2162 -- 2163 2164 GRANT ALL ON FUNCTION extensions.armor(bytea) TO dashboard_user; 2165 2166 2167 -- 2168 -- Name: FUNCTION armor(bytea, text[], text[]); Type: ACL; Schema: extensions; Owner: postgres 2169 -- 2170 2171 GRANT ALL ON FUNCTION extensions.armor(bytea, text[], text[]) TO dashboard_user; 2172 2173 2174 -- 2175 -- Name: FUNCTION crypt(text, text); Type: ACL; Schema: extensions; Owner: postgres 2176 -- 2177 2178 GRANT ALL ON FUNCTION extensions.crypt(text, text) TO dashboard_user; 2179 2180 2181 -- 2182 -- Name: FUNCTION dearmor(text); Type: ACL; Schema: extensions; Owner: postgres 2183 -- 2184 2185 GRANT ALL ON FUNCTION extensions.dearmor(text) TO dashboard_user; 2186 2187 2188 -- 2189 -- Name: FUNCTION decrypt(bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2190 -- 2191 2192 GRANT ALL ON FUNCTION extensions.decrypt(bytea, bytea, text) TO dashboard_user; 2193 2194 2195 -- 2196 -- Name: FUNCTION decrypt_iv(bytea, bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2197 -- 2198 2199 GRANT ALL ON FUNCTION extensions.decrypt_iv(bytea, bytea, bytea, text) TO dashboard_user; 2200 2201 2202 -- 2203 -- Name: FUNCTION digest(bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2204 -- 2205 2206 GRANT ALL ON FUNCTION extensions.digest(bytea, text) TO dashboard_user; 2207 2208 2209 -- 2210 -- Name: FUNCTION digest(text, text); Type: ACL; Schema: extensions; Owner: postgres 2211 -- 2212 2213 GRANT ALL ON FUNCTION extensions.digest(text, text) TO dashboard_user; 2214 2215 2216 -- 2217 -- Name: FUNCTION encrypt(bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2218 -- 2219 2220 GRANT ALL ON FUNCTION extensions.encrypt(bytea, bytea, text) TO dashboard_user; 2221 2222 2223 -- 2224 -- Name: FUNCTION encrypt_iv(bytea, bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2225 -- 2226 2227 GRANT ALL ON FUNCTION extensions.encrypt_iv(bytea, bytea, bytea, text) TO dashboard_user; 2228 2229 2230 -- 2231 -- Name: FUNCTION gen_random_bytes(integer); Type: ACL; Schema: extensions; Owner: postgres 2232 -- 2233 2234 GRANT ALL ON FUNCTION extensions.gen_random_bytes(integer) TO dashboard_user; 2235 2236 2237 -- 2238 -- Name: FUNCTION gen_random_uuid(); Type: ACL; Schema: extensions; Owner: postgres 2239 -- 2240 2241 GRANT ALL ON FUNCTION extensions.gen_random_uuid() TO dashboard_user; 2242 2243 2244 -- 2245 -- Name: FUNCTION gen_salt(text); Type: ACL; Schema: extensions; Owner: postgres 2246 -- 2247 2248 GRANT ALL ON FUNCTION extensions.gen_salt(text) TO dashboard_user; 2249 2250 2251 -- 2252 -- Name: FUNCTION gen_salt(text, integer); Type: ACL; Schema: extensions; Owner: postgres 2253 -- 2254 2255 GRANT ALL ON FUNCTION extensions.gen_salt(text, integer) TO dashboard_user; 2256 2257 2258 -- 2259 -- Name: FUNCTION grant_pg_cron_access(); Type: ACL; Schema: extensions; Owner: postgres 2260 -- 2261 2262 GRANT ALL ON FUNCTION extensions.grant_pg_cron_access() TO dashboard_user; 2263 2264 2265 -- 2266 -- Name: FUNCTION grant_pg_net_access(); Type: ACL; Schema: extensions; Owner: postgres 2267 -- 2268 2269 GRANT ALL ON FUNCTION extensions.grant_pg_net_access() TO dashboard_user; 2270 2271 2272 -- 2273 -- Name: FUNCTION hmac(bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2274 -- 2275 2276 GRANT ALL ON FUNCTION extensions.hmac(bytea, bytea, text) TO dashboard_user; 2277 2278 2279 -- 2280 -- Name: FUNCTION hmac(text, text, text); Type: ACL; Schema: extensions; Owner: postgres 2281 -- 2282 2283 GRANT ALL ON FUNCTION extensions.hmac(text, text, text) TO dashboard_user; 2284 2285 2286 -- 2287 -- Name: FUNCTION pg_stat_statements(showtext boolean, OUT userid oid, OUT dbid oid, OUT toplevel boolean, OUT queryid bigint, OUT query text, OUT plans bigint, OUT total_plan_time double precision, OUT min_plan_time double precision, OUT max_plan_time double precision, OUT mean_plan_time double precision, OUT stddev_plan_time double precision, OUT calls bigint, OUT total_exec_time double precision, OUT min_exec_time double precision, OUT max_exec_time double precision, OUT mean_exec_time double precision, OUT stddev_exec_time double precision, OUT rows bigint, OUT shared_blks_hit bigint, OUT shared_blks_read bigint, OUT shared_blks_dirtied bigint, OUT shared_blks_written bigint, OUT local_blks_hit bigint, OUT local_blks_read bigint, OUT local_blks_dirtied bigint, OUT local_blks_written bigint, OUT temp_blks_read bigint, OUT temp_blks_written bigint, OUT blk_read_time double precision, OUT blk_write_time double precision, OUT temp_blk_read_time double precision, OUT temp_blk_write_time double precision, OUT wal_records bigint, OUT wal_fpi bigint, OUT wal_bytes numeric, OUT jit_functions bigint, OUT jit_generation_time double precision, OUT jit_inlining_count bigint, OUT jit_inlining_time double precision, OUT jit_optimization_count bigint, OUT jit_optimization_time double precision, OUT jit_emission_count bigint, OUT jit_emission_time double precision); Type: ACL; Schema: extensions; Owner: postgres 2288 -- 2289 2290 GRANT ALL ON FUNCTION extensions.pg_stat_statements(showtext boolean, OUT userid oid, OUT dbid oid, OUT toplevel boolean, OUT queryid bigint, OUT query text, OUT plans bigint, OUT total_plan_time double precision, OUT min_plan_time double precision, OUT max_plan_time double precision, OUT mean_plan_time double precision, OUT stddev_plan_time double precision, OUT calls bigint, OUT total_exec_time double precision, OUT min_exec_time double precision, OUT max_exec_time double precision, OUT mean_exec_time double precision, OUT stddev_exec_time double precision, OUT rows bigint, OUT shared_blks_hit bigint, OUT shared_blks_read bigint, OUT shared_blks_dirtied bigint, OUT shared_blks_written bigint, OUT local_blks_hit bigint, OUT local_blks_read bigint, OUT local_blks_dirtied bigint, OUT local_blks_written bigint, OUT temp_blks_read bigint, OUT temp_blks_written bigint, OUT blk_read_time double precision, OUT blk_write_time double precision, OUT temp_blk_read_time double precision, OUT temp_blk_write_time double precision, OUT wal_records bigint, OUT wal_fpi bigint, OUT wal_bytes numeric, OUT jit_functions bigint, OUT jit_generation_time double precision, OUT jit_inlining_count bigint, OUT jit_inlining_time double precision, OUT jit_optimization_count bigint, OUT jit_optimization_time double precision, OUT jit_emission_count bigint, OUT jit_emission_time double precision) TO dashboard_user; 2291 2292 2293 -- 2294 -- Name: FUNCTION pg_stat_statements_info(OUT dealloc bigint, OUT stats_reset timestamp with time zone); Type: ACL; Schema: extensions; Owner: postgres 2295 -- 2296 2297 GRANT ALL ON FUNCTION extensions.pg_stat_statements_info(OUT dealloc bigint, OUT stats_reset timestamp with time zone) TO dashboard_user; 2298 2299 2300 -- 2301 -- Name: FUNCTION pg_stat_statements_reset(userid oid, dbid oid, queryid bigint); Type: ACL; Schema: extensions; Owner: postgres 2302 -- 2303 2304 GRANT ALL ON FUNCTION extensions.pg_stat_statements_reset(userid oid, dbid oid, queryid bigint) TO dashboard_user; 2305 2306 2307 -- 2308 -- Name: FUNCTION pgp_armor_headers(text, OUT key text, OUT value text); Type: ACL; Schema: extensions; Owner: postgres 2309 -- 2310 2311 GRANT ALL ON FUNCTION extensions.pgp_armor_headers(text, OUT key text, OUT value text) TO dashboard_user; 2312 2313 2314 -- 2315 -- Name: FUNCTION pgp_key_id(bytea); Type: ACL; Schema: extensions; Owner: postgres 2316 -- 2317 2318 GRANT ALL ON FUNCTION extensions.pgp_key_id(bytea) TO dashboard_user; 2319 2320 2321 -- 2322 -- Name: FUNCTION pgp_pub_decrypt(bytea, bytea); Type: ACL; Schema: extensions; Owner: postgres 2323 -- 2324 2325 GRANT ALL ON FUNCTION extensions.pgp_pub_decrypt(bytea, bytea) TO dashboard_user; 2326 2327 2328 -- 2329 -- Name: FUNCTION pgp_pub_decrypt(bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2330 -- 2331 2332 GRANT ALL ON FUNCTION extensions.pgp_pub_decrypt(bytea, bytea, text) TO dashboard_user; 2333 2334 2335 -- 2336 -- Name: FUNCTION pgp_pub_decrypt(bytea, bytea, text, text); Type: ACL; Schema: extensions; Owner: postgres 2337 -- 2338 2339 GRANT ALL ON FUNCTION extensions.pgp_pub_decrypt(bytea, bytea, text, text) TO dashboard_user; 2340 2341 2342 -- 2343 -- Name: FUNCTION pgp_pub_decrypt_bytea(bytea, bytea); Type: ACL; Schema: extensions; Owner: postgres 2344 -- 2345 2346 GRANT ALL ON FUNCTION extensions.pgp_pub_decrypt_bytea(bytea, bytea) TO dashboard_user; 2347 2348 2349 -- 2350 -- Name: FUNCTION pgp_pub_decrypt_bytea(bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2351 -- 2352 2353 GRANT ALL ON FUNCTION extensions.pgp_pub_decrypt_bytea(bytea, bytea, text) TO dashboard_user; 2354 2355 2356 -- 2357 -- Name: FUNCTION pgp_pub_decrypt_bytea(bytea, bytea, text, text); Type: ACL; Schema: extensions; Owner: postgres 2358 -- 2359 2360 GRANT ALL ON FUNCTION extensions.pgp_pub_decrypt_bytea(bytea, bytea, text, text) TO dashboard_user; 2361 2362 2363 -- 2364 -- Name: FUNCTION pgp_pub_encrypt(text, bytea); Type: ACL; Schema: extensions; Owner: postgres 2365 -- 2366 2367 GRANT ALL ON FUNCTION extensions.pgp_pub_encrypt(text, bytea) TO dashboard_user; 2368 2369 2370 -- 2371 -- Name: FUNCTION pgp_pub_encrypt(text, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2372 -- 2373 2374 GRANT ALL ON FUNCTION extensions.pgp_pub_encrypt(text, bytea, text) TO dashboard_user; 2375 2376 2377 -- 2378 -- Name: FUNCTION pgp_pub_encrypt_bytea(bytea, bytea); Type: ACL; Schema: extensions; Owner: postgres 2379 -- 2380 2381 GRANT ALL ON FUNCTION extensions.pgp_pub_encrypt_bytea(bytea, bytea) TO dashboard_user; 2382 2383 2384 -- 2385 -- Name: FUNCTION pgp_pub_encrypt_bytea(bytea, bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2386 -- 2387 2388 GRANT ALL ON FUNCTION extensions.pgp_pub_encrypt_bytea(bytea, bytea, text) TO dashboard_user; 2389 2390 2391 -- 2392 -- Name: FUNCTION pgp_sym_decrypt(bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2393 -- 2394 2395 GRANT ALL ON FUNCTION extensions.pgp_sym_decrypt(bytea, text) TO dashboard_user; 2396 2397 2398 -- 2399 -- Name: FUNCTION pgp_sym_decrypt(bytea, text, text); Type: ACL; Schema: extensions; Owner: postgres 2400 -- 2401 2402 GRANT ALL ON FUNCTION extensions.pgp_sym_decrypt(bytea, text, text) TO dashboard_user; 2403 2404 2405 -- 2406 -- Name: FUNCTION pgp_sym_decrypt_bytea(bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2407 -- 2408 2409 GRANT ALL ON FUNCTION extensions.pgp_sym_decrypt_bytea(bytea, text) TO dashboard_user; 2410 2411 2412 -- 2413 -- Name: FUNCTION pgp_sym_decrypt_bytea(bytea, text, text); Type: ACL; Schema: extensions; Owner: postgres 2414 -- 2415 2416 GRANT ALL ON FUNCTION extensions.pgp_sym_decrypt_bytea(bytea, text, text) TO dashboard_user; 2417 2418 2419 -- 2420 -- Name: FUNCTION pgp_sym_encrypt(text, text); Type: ACL; Schema: extensions; Owner: postgres 2421 -- 2422 2423 GRANT ALL ON FUNCTION extensions.pgp_sym_encrypt(text, text) TO dashboard_user; 2424 2425 2426 -- 2427 -- Name: FUNCTION pgp_sym_encrypt(text, text, text); Type: ACL; Schema: extensions; Owner: postgres 2428 -- 2429 2430 GRANT ALL ON FUNCTION extensions.pgp_sym_encrypt(text, text, text) TO dashboard_user; 2431 2432 2433 -- 2434 -- Name: FUNCTION pgp_sym_encrypt_bytea(bytea, text); Type: ACL; Schema: extensions; Owner: postgres 2435 -- 2436 2437 GRANT ALL ON FUNCTION extensions.pgp_sym_encrypt_bytea(bytea, text) TO dashboard_user; 2438 2439 2440 -- 2441 -- Name: FUNCTION pgp_sym_encrypt_bytea(bytea, text, text); Type: ACL; Schema: extensions; Owner: postgres 2442 -- 2443 2444 GRANT ALL ON FUNCTION extensions.pgp_sym_encrypt_bytea(bytea, text, text) TO dashboard_user; 2445 2446 2447 -- 2448 -- Name: FUNCTION sign(payload json, secret text, algorithm text); Type: ACL; Schema: extensions; Owner: postgres 2449 -- 2450 2451 GRANT ALL ON FUNCTION extensions.sign(payload json, secret text, algorithm text) TO dashboard_user; 2452 2453 2454 -- 2455 -- Name: FUNCTION try_cast_double(inp text); Type: ACL; Schema: extensions; Owner: postgres 2456 -- 2457 2458 GRANT ALL ON FUNCTION extensions.try_cast_double(inp text) TO dashboard_user; 2459 2460 2461 -- 2462 -- Name: FUNCTION url_decode(data text); Type: ACL; Schema: extensions; Owner: postgres 2463 -- 2464 2465 GRANT ALL ON FUNCTION extensions.url_decode(data text) TO dashboard_user; 2466 2467 2468 -- 2469 -- Name: FUNCTION url_encode(data bytea); Type: ACL; Schema: extensions; Owner: postgres 2470 -- 2471 2472 GRANT ALL ON FUNCTION extensions.url_encode(data bytea) TO dashboard_user; 2473 2474 2475 -- 2476 -- Name: FUNCTION uuid_generate_v1(); Type: ACL; Schema: extensions; Owner: postgres 2477 -- 2478 2479 GRANT ALL ON FUNCTION extensions.uuid_generate_v1() TO dashboard_user; 2480 2481 2482 -- 2483 -- Name: FUNCTION uuid_generate_v1mc(); Type: ACL; Schema: extensions; Owner: postgres 2484 -- 2485 2486 GRANT ALL ON FUNCTION extensions.uuid_generate_v1mc() TO dashboard_user; 2487 2488 2489 -- 2490 -- Name: FUNCTION uuid_generate_v3(namespace uuid, name text); Type: ACL; Schema: extensions; Owner: postgres 2491 -- 2492 2493 GRANT ALL ON FUNCTION extensions.uuid_generate_v3(namespace uuid, name text) TO dashboard_user; 2494 2495 2496 -- 2497 -- Name: FUNCTION uuid_generate_v4(); Type: ACL; Schema: extensions; Owner: postgres 2498 -- 2499 2500 GRANT ALL ON FUNCTION extensions.uuid_generate_v4() TO dashboard_user; 2501 2502 2503 -- 2504 -- Name: FUNCTION uuid_generate_v5(namespace uuid, name text); Type: ACL; Schema: extensions; Owner: postgres 2505 -- 2506 2507 GRANT ALL ON FUNCTION extensions.uuid_generate_v5(namespace uuid, name text) TO dashboard_user; 2508 2509 2510 -- 2511 -- Name: FUNCTION uuid_nil(); Type: ACL; Schema: extensions; Owner: postgres 2512 -- 2513 2514 GRANT ALL ON FUNCTION extensions.uuid_nil() TO dashboard_user; 2515 2516 2517 -- 2518 -- Name: FUNCTION uuid_ns_dns(); Type: ACL; Schema: extensions; Owner: postgres 2519 -- 2520 2521 GRANT ALL ON FUNCTION extensions.uuid_ns_dns() TO dashboard_user; 2522 2523 2524 -- 2525 -- Name: FUNCTION uuid_ns_oid(); Type: ACL; Schema: extensions; Owner: postgres 2526 -- 2527 2528 GRANT ALL ON FUNCTION extensions.uuid_ns_oid() TO dashboard_user; 2529 2530 2531 -- 2532 -- Name: FUNCTION uuid_ns_url(); Type: ACL; Schema: extensions; Owner: postgres 2533 -- 2534 2535 GRANT ALL ON FUNCTION extensions.uuid_ns_url() TO dashboard_user; 2536 2537 2538 -- 2539 -- Name: FUNCTION uuid_ns_x500(); Type: ACL; Schema: extensions; Owner: postgres 2540 -- 2541 2542 GRANT ALL ON FUNCTION extensions.uuid_ns_x500() TO dashboard_user; 2543 2544 2545 -- 2546 -- Name: FUNCTION verify(token text, secret text, algorithm text); Type: ACL; Schema: extensions; Owner: postgres 2547 -- 2548 2549 GRANT ALL ON FUNCTION extensions.verify(token text, secret text, algorithm text) TO dashboard_user; 2550 2551 2552 -- 2553 -- Name: FUNCTION comment_directive(comment_ text); Type: ACL; Schema: graphql; Owner: supabase_admin 2554 -- 2555 2556 GRANT ALL ON FUNCTION graphql.comment_directive(comment_ text) TO postgres; 2557 GRANT ALL ON FUNCTION graphql.comment_directive(comment_ text) TO anon; 2558 GRANT ALL ON FUNCTION graphql.comment_directive(comment_ text) TO authenticated; 2559 GRANT ALL ON FUNCTION graphql.comment_directive(comment_ text) TO service_role; 2560 2561 2562 -- 2563 -- Name: FUNCTION exception(message text); Type: ACL; Schema: graphql; Owner: supabase_admin 2564 -- 2565 2566 GRANT ALL ON FUNCTION graphql.exception(message text) TO postgres; 2567 GRANT ALL ON FUNCTION graphql.exception(message text) TO anon; 2568 GRANT ALL ON FUNCTION graphql.exception(message text) TO authenticated; 2569 GRANT ALL ON FUNCTION graphql.exception(message text) TO service_role; 2570 2571 2572 -- 2573 -- Name: FUNCTION get_schema_version(); Type: ACL; Schema: graphql; Owner: supabase_admin 2574 -- 2575 2576 GRANT ALL ON FUNCTION graphql.get_schema_version() TO postgres; 2577 GRANT ALL ON FUNCTION graphql.get_schema_version() TO anon; 2578 GRANT ALL ON FUNCTION graphql.get_schema_version() TO authenticated; 2579 GRANT ALL ON FUNCTION graphql.get_schema_version() TO service_role; 2580 2581 2582 -- 2583 -- Name: FUNCTION increment_schema_version(); Type: ACL; Schema: graphql; Owner: supabase_admin 2584 -- 2585 2586 GRANT ALL ON FUNCTION graphql.increment_schema_version() TO postgres; 2587 GRANT ALL ON FUNCTION graphql.increment_schema_version() TO anon; 2588 GRANT ALL ON FUNCTION graphql.increment_schema_version() TO authenticated; 2589 GRANT ALL ON FUNCTION graphql.increment_schema_version() TO service_role; 2590 2591 2592 -- 2593 -- Name: FUNCTION graphql("operationName" text, query text, variables jsonb, extensions jsonb); Type: ACL; Schema: graphql_public; Owner: supabase_admin 2594 -- 2595 2596 -- GRANT ALL ON FUNCTION graphql_public.graphql("operationName" text, query text, variables jsonb, extensions jsonb) TO postgres; 2597 -- GRANT ALL ON FUNCTION graphql_public.graphql("operationName" text, query text, variables jsonb, extensions jsonb) TO anon; 2598 -- GRANT ALL ON FUNCTION graphql_public.graphql("operationName" text, query text, variables jsonb, extensions jsonb) TO authenticated; 2599 -- GRANT ALL ON FUNCTION graphql_public.graphql("operationName" text, query text, variables jsonb, extensions jsonb) TO service_role; 2600 2601 2602 -- 2603 -- Name: FUNCTION get_auth(p_usename text); Type: ACL; Schema: pgbouncer; Owner: postgres 2604 -- 2605 2606 REVOKE ALL ON FUNCTION pgbouncer.get_auth(p_usename text) FROM PUBLIC; 2607 GRANT ALL ON FUNCTION pgbouncer.get_auth(p_usename text) TO pgbouncer; 2608 2609 2610 -- 2611 -- Name: FUNCTION crypto_aead_det_decrypt(message bytea, additional bytea, key_uuid uuid, nonce bytea); Type: ACL; Schema: pgsodium; Owner: pgsodium_keymaker 2612 -- 2613 2614 GRANT ALL ON FUNCTION pgsodium.crypto_aead_det_decrypt(message bytea, additional bytea, key_uuid uuid, nonce bytea) TO service_role; 2615 2616 2617 -- 2618 -- Name: FUNCTION crypto_aead_det_encrypt(message bytea, additional bytea, key_uuid uuid, nonce bytea); Type: ACL; Schema: pgsodium; Owner: pgsodium_keymaker 2619 -- 2620 2621 GRANT ALL ON FUNCTION pgsodium.crypto_aead_det_encrypt(message bytea, additional bytea, key_uuid uuid, nonce bytea) TO service_role; 2622 2623 2624 -- 2625 -- Name: FUNCTION crypto_aead_det_keygen(); Type: ACL; Schema: pgsodium; Owner: supabase_admin 2626 -- 2627 2628 GRANT ALL ON FUNCTION pgsodium.crypto_aead_det_keygen() TO service_role; 2629 2630 2631 -- 2632 -- Name: FUNCTION extension(name text); Type: ACL; Schema: storage; Owner: supabase_storage_admin 2633 -- 2634 2635 GRANT ALL ON FUNCTION storage.extension(name text) TO anon; 2636 GRANT ALL ON FUNCTION storage.extension(name text) TO authenticated; 2637 GRANT ALL ON FUNCTION storage.extension(name text) TO service_role; 2638 GRANT ALL ON FUNCTION storage.extension(name text) TO dashboard_user; 2639 GRANT ALL ON FUNCTION storage.extension(name text) TO postgres; 2640 2641 2642 -- 2643 -- Name: FUNCTION filename(name text); Type: ACL; Schema: storage; Owner: supabase_storage_admin 2644 -- 2645 2646 GRANT ALL ON FUNCTION storage.filename(name text) TO anon; 2647 GRANT ALL ON FUNCTION storage.filename(name text) TO authenticated; 2648 GRANT ALL ON FUNCTION storage.filename(name text) TO service_role; 2649 GRANT ALL ON FUNCTION storage.filename(name text) TO dashboard_user; 2650 GRANT ALL ON FUNCTION storage.filename(name text) TO postgres; 2651 2652 2653 -- 2654 -- Name: FUNCTION foldername(name text); Type: ACL; Schema: storage; Owner: supabase_storage_admin 2655 -- 2656 2657 GRANT ALL ON FUNCTION storage.foldername(name text) TO anon; 2658 GRANT ALL ON FUNCTION storage.foldername(name text) TO authenticated; 2659 GRANT ALL ON FUNCTION storage.foldername(name text) TO service_role; 2660 GRANT ALL ON FUNCTION storage.foldername(name text) TO dashboard_user; 2661 GRANT ALL ON FUNCTION storage.foldername(name text) TO postgres; 2662 2663 2664 -- 2665 -- Name: TABLE audit_log_entries; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2666 -- 2667 2668 GRANT ALL ON TABLE auth.audit_log_entries TO dashboard_user; 2669 GRANT ALL ON TABLE auth.audit_log_entries TO postgres; 2670 2671 2672 -- 2673 -- Name: TABLE identities; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2674 -- 2675 2676 GRANT ALL ON TABLE auth.identities TO postgres; 2677 GRANT ALL ON TABLE auth.identities TO dashboard_user; 2678 2679 2680 -- 2681 -- Name: TABLE instances; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2682 -- 2683 2684 GRANT ALL ON TABLE auth.instances TO dashboard_user; 2685 GRANT ALL ON TABLE auth.instances TO postgres; 2686 2687 2688 -- 2689 -- Name: TABLE mfa_amr_claims; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2690 -- 2691 2692 GRANT ALL ON TABLE auth.mfa_amr_claims TO postgres; 2693 GRANT ALL ON TABLE auth.mfa_amr_claims TO dashboard_user; 2694 2695 2696 -- 2697 -- Name: TABLE mfa_challenges; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2698 -- 2699 2700 GRANT ALL ON TABLE auth.mfa_challenges TO postgres; 2701 GRANT ALL ON TABLE auth.mfa_challenges TO dashboard_user; 2702 2703 2704 -- 2705 -- Name: TABLE mfa_factors; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2706 -- 2707 2708 GRANT ALL ON TABLE auth.mfa_factors TO postgres; 2709 GRANT ALL ON TABLE auth.mfa_factors TO dashboard_user; 2710 2711 2712 -- 2713 -- Name: TABLE refresh_tokens; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2714 -- 2715 2716 GRANT ALL ON TABLE auth.refresh_tokens TO dashboard_user; 2717 GRANT ALL ON TABLE auth.refresh_tokens TO postgres; 2718 2719 2720 -- 2721 -- Name: SEQUENCE refresh_tokens_id_seq; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2722 -- 2723 2724 GRANT ALL ON SEQUENCE auth.refresh_tokens_id_seq TO dashboard_user; 2725 GRANT ALL ON SEQUENCE auth.refresh_tokens_id_seq TO postgres; 2726 2727 2728 -- 2729 -- Name: TABLE saml_providers; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2730 -- 2731 2732 GRANT ALL ON TABLE auth.saml_providers TO postgres; 2733 GRANT ALL ON TABLE auth.saml_providers TO dashboard_user; 2734 2735 2736 -- 2737 -- Name: TABLE saml_relay_states; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2738 -- 2739 2740 GRANT ALL ON TABLE auth.saml_relay_states TO postgres; 2741 GRANT ALL ON TABLE auth.saml_relay_states TO dashboard_user; 2742 2743 2744 -- 2745 -- Name: TABLE schema_migrations; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2746 -- 2747 2748 GRANT ALL ON TABLE auth.schema_migrations TO dashboard_user; 2749 GRANT ALL ON TABLE auth.schema_migrations TO postgres; 2750 2751 2752 -- 2753 -- Name: TABLE sessions; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2754 -- 2755 2756 GRANT ALL ON TABLE auth.sessions TO postgres; 2757 GRANT ALL ON TABLE auth.sessions TO dashboard_user; 2758 2759 2760 -- 2761 -- Name: TABLE sso_domains; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2762 -- 2763 2764 GRANT ALL ON TABLE auth.sso_domains TO postgres; 2765 GRANT ALL ON TABLE auth.sso_domains TO dashboard_user; 2766 2767 2768 -- 2769 -- Name: TABLE sso_providers; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2770 -- 2771 2772 GRANT ALL ON TABLE auth.sso_providers TO postgres; 2773 GRANT ALL ON TABLE auth.sso_providers TO dashboard_user; 2774 2775 2776 -- 2777 -- Name: TABLE users; Type: ACL; Schema: auth; Owner: supabase_auth_admin 2778 -- 2779 2780 GRANT ALL ON TABLE auth.users TO dashboard_user; 2781 GRANT ALL ON TABLE auth.users TO postgres; 2782 2783 2784 -- 2785 -- Name: TABLE pg_stat_statements; Type: ACL; Schema: extensions; Owner: postgres 2786 -- 2787 2788 GRANT ALL ON TABLE extensions.pg_stat_statements TO dashboard_user; 2789 2790 2791 -- 2792 -- Name: TABLE pg_stat_statements_info; Type: ACL; Schema: extensions; Owner: postgres 2793 -- 2794 2795 GRANT ALL ON TABLE extensions.pg_stat_statements_info TO dashboard_user; 2796 2797 2798 -- 2799 -- Name: SEQUENCE seq_schema_version; Type: ACL; Schema: graphql; Owner: supabase_admin 2800 -- 2801 2802 GRANT ALL ON SEQUENCE graphql.seq_schema_version TO postgres; 2803 GRANT ALL ON SEQUENCE graphql.seq_schema_version TO anon; 2804 GRANT ALL ON SEQUENCE graphql.seq_schema_version TO authenticated; 2805 GRANT ALL ON SEQUENCE graphql.seq_schema_version TO service_role; 2806 2807 2808 -- 2809 -- Name: TABLE decrypted_key; Type: ACL; Schema: pgsodium; Owner: supabase_admin 2810 -- 2811 2812 GRANT ALL ON TABLE pgsodium.decrypted_key TO pgsodium_keyholder; 2813 2814 2815 -- 2816 -- Name: TABLE masking_rule; Type: ACL; Schema: pgsodium; Owner: supabase_admin 2817 -- 2818 2819 GRANT ALL ON TABLE pgsodium.masking_rule TO pgsodium_keyholder; 2820 2821 2822 -- 2823 -- Name: TABLE mask_columns; Type: ACL; Schema: pgsodium; Owner: supabase_admin 2824 -- 2825 2826 GRANT ALL ON TABLE pgsodium.mask_columns TO pgsodium_keyholder; 2827 2828 2829 -- 2830 -- Name: TABLE buckets; Type: ACL; Schema: storage; Owner: supabase_storage_admin 2831 -- 2832 2833 GRANT ALL ON TABLE storage.buckets TO anon; 2834 GRANT ALL ON TABLE storage.buckets TO authenticated; 2835 GRANT ALL ON TABLE storage.buckets TO service_role; 2836 GRANT ALL ON TABLE storage.buckets TO postgres; 2837 2838 2839 -- 2840 -- Name: TABLE migrations; Type: ACL; Schema: storage; Owner: supabase_storage_admin 2841 -- 2842 2843 GRANT ALL ON TABLE storage.migrations TO anon; 2844 GRANT ALL ON TABLE storage.migrations TO authenticated; 2845 GRANT ALL ON TABLE storage.migrations TO service_role; 2846 GRANT ALL ON TABLE storage.migrations TO postgres; 2847 2848 2849 -- 2850 -- Name: TABLE objects; Type: ACL; Schema: storage; Owner: supabase_storage_admin 2851 -- 2852 2853 GRANT ALL ON TABLE storage.objects TO anon; 2854 GRANT ALL ON TABLE storage.objects TO authenticated; 2855 GRANT ALL ON TABLE storage.objects TO service_role; 2856 GRANT ALL ON TABLE storage.objects TO postgres; 2857 2858 2859 -- 2860 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: auth; Owner: supabase_auth_admin 2861 -- 2862 2863 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_auth_admin IN SCHEMA auth GRANT ALL ON SEQUENCES TO postgres; 2864 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_auth_admin IN SCHEMA auth GRANT ALL ON SEQUENCES TO dashboard_user; 2865 2866 2867 -- 2868 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: auth; Owner: supabase_auth_admin 2869 -- 2870 2871 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_auth_admin IN SCHEMA auth GRANT ALL ON FUNCTIONS TO postgres; 2872 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_auth_admin IN SCHEMA auth GRANT ALL ON FUNCTIONS TO dashboard_user; 2873 2874 2875 -- 2876 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: auth; Owner: supabase_auth_admin 2877 -- 2878 2879 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_auth_admin IN SCHEMA auth GRANT ALL ON TABLES TO postgres; 2880 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_auth_admin IN SCHEMA auth GRANT ALL ON TABLES TO dashboard_user; 2881 2882 2883 -- 2884 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: graphql; Owner: supabase_admin 2885 -- 2886 2887 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON SEQUENCES TO postgres; 2888 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON SEQUENCES TO anon; 2889 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON SEQUENCES TO authenticated; 2890 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON SEQUENCES TO service_role; 2891 2892 2893 -- 2894 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: graphql; Owner: supabase_admin 2895 -- 2896 2897 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON FUNCTIONS TO postgres; 2898 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON FUNCTIONS TO anon; 2899 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON FUNCTIONS TO authenticated; 2900 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON FUNCTIONS TO service_role; 2901 2902 2903 -- 2904 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: graphql; Owner: supabase_admin 2905 -- 2906 2907 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON TABLES TO postgres; 2908 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON TABLES TO anon; 2909 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON TABLES TO authenticated; 2910 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql GRANT ALL ON TABLES TO service_role; 2911 2912 2913 -- 2914 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: graphql_public; Owner: supabase_admin 2915 -- 2916 2917 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON SEQUENCES TO postgres; 2918 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON SEQUENCES TO anon; 2919 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON SEQUENCES TO authenticated; 2920 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON SEQUENCES TO service_role; 2921 2922 2923 -- 2924 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: graphql_public; Owner: supabase_admin 2925 -- 2926 2927 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON FUNCTIONS TO postgres; 2928 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON FUNCTIONS TO anon; 2929 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON FUNCTIONS TO authenticated; 2930 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON FUNCTIONS TO service_role; 2931 2932 2933 -- 2934 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: graphql_public; Owner: supabase_admin 2935 -- 2936 2937 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON TABLES TO postgres; 2938 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON TABLES TO anon; 2939 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON TABLES TO authenticated; 2940 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA graphql_public GRANT ALL ON TABLES TO service_role; 2941 2942 2943 -- 2944 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: pgsodium; Owner: supabase_admin 2945 -- 2946 2947 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA pgsodium GRANT ALL ON SEQUENCES TO pgsodium_keyholder; 2948 2949 2950 -- 2951 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: pgsodium; Owner: supabase_admin 2952 -- 2953 2954 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA pgsodium GRANT ALL ON TABLES TO pgsodium_keyholder; 2955 2956 2957 -- 2958 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: pgsodium_masks; Owner: supabase_admin 2959 -- 2960 2961 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA pgsodium_masks GRANT ALL ON SEQUENCES TO pgsodium_keyiduser; 2962 2963 2964 -- 2965 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: pgsodium_masks; Owner: supabase_admin 2966 -- 2967 2968 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA pgsodium_masks GRANT ALL ON FUNCTIONS TO pgsodium_keyiduser; 2969 2970 2971 -- 2972 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: pgsodium_masks; Owner: supabase_admin 2973 -- 2974 2975 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA pgsodium_masks GRANT ALL ON TABLES TO pgsodium_keyiduser; 2976 2977 2978 -- 2979 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: public; Owner: postgres 2980 -- 2981 2982 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON SEQUENCES TO postgres; 2983 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON SEQUENCES TO anon; 2984 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON SEQUENCES TO authenticated; 2985 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON SEQUENCES TO service_role; 2986 2987 2988 -- 2989 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: public; Owner: supabase_admin 2990 -- 2991 2992 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON SEQUENCES TO postgres; 2993 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON SEQUENCES TO anon; 2994 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON SEQUENCES TO authenticated; 2995 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON SEQUENCES TO service_role; 2996 2997 2998 -- 2999 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: public; Owner: postgres 3000 -- 3001 3002 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON FUNCTIONS TO postgres; 3003 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON FUNCTIONS TO anon; 3004 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON FUNCTIONS TO authenticated; 3005 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON FUNCTIONS TO service_role; 3006 3007 3008 -- 3009 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: public; Owner: supabase_admin 3010 -- 3011 3012 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON FUNCTIONS TO postgres; 3013 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON FUNCTIONS TO anon; 3014 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON FUNCTIONS TO authenticated; 3015 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON FUNCTIONS TO service_role; 3016 3017 3018 -- 3019 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: public; Owner: postgres 3020 -- 3021 3022 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON TABLES TO postgres; 3023 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON TABLES TO anon; 3024 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON TABLES TO authenticated; 3025 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA public GRANT ALL ON TABLES TO service_role; 3026 3027 3028 -- 3029 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: public; Owner: supabase_admin 3030 -- 3031 3032 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON TABLES TO postgres; 3033 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON TABLES TO anon; 3034 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON TABLES TO authenticated; 3035 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA public GRANT ALL ON TABLES TO service_role; 3036 3037 3038 -- 3039 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: realtime; Owner: supabase_admin 3040 -- 3041 3042 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA realtime GRANT ALL ON SEQUENCES TO postgres; 3043 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA realtime GRANT ALL ON SEQUENCES TO dashboard_user; 3044 3045 3046 -- 3047 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: realtime; Owner: supabase_admin 3048 -- 3049 3050 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA realtime GRANT ALL ON FUNCTIONS TO postgres; 3051 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA realtime GRANT ALL ON FUNCTIONS TO dashboard_user; 3052 3053 3054 -- 3055 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: realtime; Owner: supabase_admin 3056 -- 3057 3058 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA realtime GRANT ALL ON TABLES TO postgres; 3059 ALTER DEFAULT PRIVILEGES FOR ROLE supabase_admin IN SCHEMA realtime GRANT ALL ON TABLES TO dashboard_user; 3060 3061 3062 -- 3063 -- Name: DEFAULT PRIVILEGES FOR SEQUENCES; Type: DEFAULT ACL; Schema: storage; Owner: postgres 3064 -- 3065 3066 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON SEQUENCES TO postgres; 3067 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON SEQUENCES TO anon; 3068 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON SEQUENCES TO authenticated; 3069 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON SEQUENCES TO service_role; 3070 3071 3072 -- 3073 -- Name: DEFAULT PRIVILEGES FOR FUNCTIONS; Type: DEFAULT ACL; Schema: storage; Owner: postgres 3074 -- 3075 3076 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON FUNCTIONS TO postgres; 3077 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON FUNCTIONS TO anon; 3078 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON FUNCTIONS TO authenticated; 3079 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON FUNCTIONS TO service_role; 3080 3081 3082 -- 3083 -- Name: DEFAULT PRIVILEGES FOR TABLES; Type: DEFAULT ACL; Schema: storage; Owner: postgres 3084 -- 3085 3086 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON TABLES TO postgres; 3087 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON TABLES TO anon; 3088 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON TABLES TO authenticated; 3089 ALTER DEFAULT PRIVILEGES FOR ROLE postgres IN SCHEMA storage GRANT ALL ON TABLES TO service_role; 3090 3091 3092 -- 3093 -- Name: issue_graphql_placeholder; Type: EVENT TRIGGER; Schema: -; Owner: supabase_admin 3094 -- 3095 3096 CREATE EVENT TRIGGER issue_graphql_placeholder ON sql_drop 3097 WHEN TAG IN ('DROP EXTENSION') 3098 EXECUTE FUNCTION extensions.set_graphql_placeholder(); 3099 3100 3101 ALTER EVENT TRIGGER issue_graphql_placeholder OWNER TO supabase_admin; 3102 3103 -- 3104 -- Name: issue_pg_cron_access; Type: EVENT TRIGGER; Schema: -; Owner: postgres 3105 -- 3106 3107 CREATE EVENT TRIGGER issue_pg_cron_access ON ddl_command_end 3108 WHEN TAG IN ('CREATE SCHEMA') 3109 EXECUTE FUNCTION extensions.grant_pg_cron_access(); 3110 3111 3112 ALTER EVENT TRIGGER issue_pg_cron_access OWNER TO postgres; 3113 3114 -- 3115 -- Name: issue_pg_graphql_access; Type: EVENT TRIGGER; Schema: -; Owner: supabase_admin 3116 -- 3117 3118 CREATE EVENT TRIGGER issue_pg_graphql_access ON ddl_command_end 3119 WHEN TAG IN ('CREATE FUNCTION') 3120 EXECUTE FUNCTION extensions.grant_pg_graphql_access(); 3121 3122 3123 ALTER EVENT TRIGGER issue_pg_graphql_access OWNER TO supabase_admin; 3124 3125 -- 3126 -- Name: issue_pg_net_access; Type: EVENT TRIGGER; Schema: -; Owner: postgres 3127 -- 3128 3129 CREATE EVENT TRIGGER issue_pg_net_access ON ddl_command_end 3130 WHEN TAG IN ('CREATE EXTENSION') 3131 EXECUTE FUNCTION extensions.grant_pg_net_access(); 3132 3133 3134 ALTER EVENT TRIGGER issue_pg_net_access OWNER TO postgres; 3135 3136 -- 3137 -- Name: pgrst_ddl_watch; Type: EVENT TRIGGER; Schema: -; Owner: supabase_admin 3138 -- 3139 3140 CREATE EVENT TRIGGER pgrst_ddl_watch ON ddl_command_end 3141 EXECUTE FUNCTION extensions.pgrst_ddl_watch(); 3142 3143 3144 ALTER EVENT TRIGGER pgrst_ddl_watch OWNER TO supabase_admin; 3145 3146 -- 3147 -- Name: pgrst_drop_watch; Type: EVENT TRIGGER; Schema: -; Owner: supabase_admin 3148 -- 3149 3150 CREATE EVENT TRIGGER pgrst_drop_watch ON sql_drop 3151 EXECUTE FUNCTION extensions.pgrst_drop_watch(); 3152 3153 3154 ALTER EVENT TRIGGER pgrst_drop_watch OWNER TO supabase_admin; 3155 3156 -- 3157 -- PostgreSQL database dump complete 3158 -- 3159 3160 DROP EXTENSION pg_graphql; CREATE EXTENSION pg_graphql WITH SCHEMA graphql; 3161 RESET ALL;