https://supabase.com/ logo
Join Discord
Powered by
# help
  • w

    wario

    12/02/2021, 9:38 PM
    I basically want to make my webapp invite-only. I implemented a workaround like this: https://github.com/supabase/supabase/discussions/3208 but I would love to be able to make unique invite tokens that people can just paste in and I verify if they exist in my db, then set to used or something. but how can I do that without making that table public (where someone could just select * tokens lol)
  • e

    Eduardo Lopez

    12/03/2021, 2:08 AM
    Hi everyone! hey, quick q, I need to give read-only access to my database to some team members. I tried adding. CREATE USER "[user]" WITH PASSWORD '[password]'; GRANT CONNECT ON DATABASE postgres TO "[user]"; GRANT USAGE ON SCHEMA public TO "[user]"; GRANT SELECT ON ALL TABLES IN SCHEMA public TO "[user]"; But the last step fails
  • e

    Eduardo Lopez

    12/03/2021, 2:09 AM
    I think it is related to my user not having full access to the DB supabase provides, does anyone knows how to fix this?
  • u

    user

    12/03/2021, 2:21 AM
    hey guys, is realtime rls available for old proyects? i been trying the whole day got get it working in a proyect I already have, but I couldn't. It didn't give any errors, but I wasn't receiving any updates either. Then I started a new proyect with the bare minumun necessary and just worked.
  • u

    user

    12/03/2021, 2:21 AM
    I also compared my settings and every seems to be the same
  • f

    fayaz

    12/03/2021, 7:46 AM
    Where can I see supabase db logs? I wrote a trigger and a function on auth user created event. It just returns β€œDatabase error”
  • c

    chipilov

    12/03/2021, 7:56 AM
    I don't think you can do that at the moment
  • w

    wiesson

    12/03/2021, 8:38 AM
    Does anyone know if I can disable that app.supabase.io stays in sync on all tabs? I have multiple tabs open and I want to copy security rules but the page always changes πŸ˜‚
  • w

    wiesson

    12/03/2021, 8:39 AM
    I guess it looks very magical πŸ¦„ - if everything is in sync, but the route should not change if you ask me
  • e

    ekko

    12/03/2021, 8:56 AM
    is it possible to run arbitrary select requests using the supabase-js client? the sql-editor within the supabase app seems to support any type of query. but an 'x-connection-encrypted' header is required to make the calls. i'm trying to create a complex query with joins, filtering by joined columns and to order the results from a foreign table column. how do other people perform complex queries?
    t
    • 2
    • 2
  • x

    Xyo

    12/03/2021, 10:33 AM
    I was going mad because of that haha, at some point I disabled networking in one tab
  • b

    batuhanbilginn

    12/03/2021, 11:41 AM
    Is there anyone having problem with "Email Confirmation"? When I create user on the server supabase forces them to confirm their email adress even if it's disabled from the settings...
  • e

    egnus

    12/03/2021, 12:33 PM
    Yeah this will ok, but since you are referencing
    auth.users
    and in that table there is no reference to this, you will be creating a relationship of many to 1, which means that when querying from users to get integrations you (might) get an array of 1 item. Instead of an object directly. But still, you are safe to know that the array will be always one item (perhaps you get an object with the query and not an array, this is only my assumption with what I know today)
  • m

    Mathel

    12/03/2021, 1:10 PM
    Hey πŸ‘‹ I just posted a question related to Supabase on Stackoverflow to be searchable in the future. Maybe someone here have an idea πŸ™‚ https://stackoverflow.com/questions/70214826/creating-nested-relationships-with-supabase
    m
    • 2
    • 1
  • c

    cookie mob

    12/03/2021, 1:59 PM
    can i get only the last entry from table with .single() ?
  • c

    cookie mob

    12/03/2021, 2:38 PM
    okay, figured it out
  • i

    itsnotyalc

    12/03/2021, 3:07 PM
    How would I get multiple users by id? I've tried a few things but unsure
    Copy code
    const { data: users, error } = await supabase
          .from('users')
          .select('*')
          .in('id', userIds);
  • g

    garyaustin

    12/03/2021, 3:18 PM
    As long as userIds is an array of user id that should work. Assuming, if you have RLS on, you allow any id to be read.
  • t

    Thomas B

    12/03/2021, 6:28 PM
    Anyone else where RLS with Realtime still doesn't work where the primary key is a
    uuid
    , or am I under the wrong impression that it was actually fixed a couple of hours ago? πŸ™‚ - JS client verison: 1.28.5
  • g

    garyaustin

    12/03/2021, 6:52 PM
    Seems like they have to role it out into the servers. 1.28.5 addressed some of the issue, but appears the realtime server has fixes also. https://github.com/supabase/supabase/issues/4201 note the description is outdated as PG13 has issues too, pointed out further in the reply chain.
  • t

    Thomas B

    12/03/2021, 7:05 PM
    Thx bud, thought it was a client issue overall - just gotta give them some time then I guess. πŸ™‚ (I'm on PG13)
  • t

    Thomas B

    12/03/2021, 7:09 PM
    At least until we are able to upgrade easily ourselves hehe
  • b

    Barba

    12/03/2021, 8:35 PM
    Hey guys! all goes well 😊, Quick (noob) question. What would be the right/best way to request data and subscribe to new data using nextjs? The idea I have in mind is a kind of setTimeout.. and Im 99% sure there is a better/simple way to do this with nextjs and supabase, thanks. I saw some documentation on the website, so I tried this:
    Copy code
    const todos = supabase
          .from('todos')
          .on('*', payload => {
            console.log('Change received!', payload)
          })
          .subscribe()
    but its not working.. but a simple request is working fine:
    Copy code
    const { data: todos, error } = await supabase.from('todos').select('*')
    so why is not working the subscribe and second thing, where is the rigth place to place this peace of code on nextjs. Thanks!
  • t

    Thomas B

    12/03/2021, 8:59 PM
    https://supabase.com/docs/guides/api#managing-realtime - Done this? :)
  • u

    user

    12/03/2021, 10:05 PM
    Hey I'm trying to toy about with Supabase in local dev but struggling to get storage working. It seems that running the docker image runs with a configuration that has storage disabled and using the cli/`supabase init` just hangs indefinitely for me
  • u

    user

    12/03/2021, 10:05 PM
    Is there some way to configure storage when running with docker-compose?
  • u

    user

    12/03/2021, 10:13 PM
    Alternatively, is there any way to run
    supabase init
    in a verbose manner to see if anything is occurring or if it's hanging immediately?
  • t

    Tobbe

    12/03/2021, 11:06 PM
    Hi. I'm using Prisma with my supabase database. I'm having problems with a migration script it generated. It has a bunch of SQL statements that run just fine. But then it comes to index renaming, and it just fails.
    ALTER INDEX "E1spCarCategoryCount.carInfoId_categoryId_unique" RENAME TO "E1spCarCategoryCount_carInfoId_categoryId_key";
    That's an example of a rename that fails. Should this be supported? Does it look wrong in any way?
  • t

    Tobbe

    12/03/2021, 11:08 PM
    I've connected to my DB with a gui db admin tool, and can see the index
  • t

    Tobbe

    12/03/2021, 11:09 PM
    The error I'm getting is "An I/O error occurred while sending to the backend."
1...150151152...316Latest