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

    Dembe

    06/10/2022, 1:28 PM
    When I have images in storage, how can I reach them in my frontend?
    Copy code
    export async function getStaticProps() {
      let { data } = await supabaseAdmin.storage.from("gallery").select("*");
      return {
        props: {
          images: data,
        },
      };
    }
    This doesnt work.
    n
    g
    • 3
    • 6
  • s

    Shoki

    06/10/2022, 1:49 PM
    hello, in local development (with docker) where i can enter Google credentials ?
    n
    s
    • 3
    • 6
  • l

    Lesourdingo

    06/10/2022, 2:08 PM
    Hello, I added a unique constraint to a column via the SQL editor but I don't know how to delete it. any help?
    n
    g
    • 3
    • 27
  • d

    Dembe

    06/10/2022, 2:39 PM
    Hi sorry for creating one more post, got awesome help but i struggle a bit with a thing.
    Copy code
    export async function getStaticProps() {
      const { data, error } = await supabaseAdmin.storage
        .from("gallery")
        .list("categories/sport", {
          limit: 100,
          offset: 0,
        });
      return {
        props: {
          images: data,
        },
      };
    }
    in this code in sport folder i have two sub folders, football and golf with images in those subfolder. how could I retrive all the images from each subfolder into categories/sport? so when i go to sport i want to retrive all the images from sports subfolders images if you understand me! 😄
    n
    • 2
    • 1
  • e

    ekko

    06/10/2022, 3:25 PM
    hey, experiencing extremely slow loading times/timeouts on my supabase instance on a app running right now which is in production. is there anyone i can speak to to trouble shoot this issue?
    n
    o
    • 3
    • 2
  • b

    Bryan K.

    06/10/2022, 5:41 PM
    If I run the following function through the JS library, and the email address does not exist in the Auth table, shouldn't I get an error back? let { data, error } = await supabase.auth.api.resetPasswordForEmail(email)
    n
    c
    +2
    • 5
    • 10
  • k

    Kiwi

    06/10/2022, 6:13 PM
    Hey guys, is it possible to do nested queries using the js client?
    n
    g
    • 3
    • 3
  • b

    Bryan K.

    06/10/2022, 9:35 PM
    Is there a way to see a log of Custom SMTP actions? I am trying to figure out why I am not getting email with the Custom SMTP setup.
    n
    • 2
    • 1
  • j

    Jenaro Calvino

    06/10/2022, 11:03 PM
    Hey everyone, I'm the worst at SQL and I'm trying to create a RLS policy as follows: Plan ---- id, isPublic, ... PlansOnUsers ---- planId, userId Grant access to Plans only when plan isPublic = true or when user is accessing a plan with their own userId, does that make any sense? Is it possible?
    n
    g
    • 3
    • 6
  • c

    coinmaster47

    06/11/2022, 2:11 AM
    Hi Jon, in regard to this tut https://leveluptutorials.com/tutorials/realtime-remix-with-supabase/create-a-higher-order-function-helper-for-serverside-supabase-queries I'm getting an Error: Cannot initialize 'routeModules'. This normally occurs when you have server code in your client modules.
    n
    • 2
    • 1
  • b

    Big Bird

    06/11/2022, 7:38 AM
    Hey feeling like I'm blind here. With the following query `data === []`:
    Copy code
    console.log('getOneJobFromDb', jobAddress)
    let { data, error } = await supabase
        .from('jobs')
        .select('*')
        .ilike('address', jobAddress) // using ilike to manage case-insensitive search
    if (error) {console.log('eerrrororor', error)}
    console.log('DATA',data)
    I expect to receive ONE hit. Because when I copy paste the value of
    jobAddress
    into the filter in the table exploration of app.supabase.com, it yields the expected result:
    n
    g
    • 3
    • 4
  • u

    <Ocean />

    06/11/2022, 9:08 AM
    For some reason supabase is not adding site url there (Docker)
    n
    s
    • 3
    • 14
  • r

    Rickert

    06/11/2022, 10:25 AM
    Anyone have an idea how to resolve the following error? First time trying to do this. I'm running on an m1 pro machine and did a fresh docker install.. supabase start Error restoring branch main: Branch was not dumped. Error: Error response from daemon: error creating overlay mount to /var/lib/docker/overlay2/bef748b6cfd52bcbc9b6c5394f41dbc99f732cda25be0afa6844c7496ece2de7-init/merged: too many levels of symbolic links
    n
    s
    • 3
    • 2
  • r

    Rickert

    06/11/2022, 11:28 AM
    I managed to fix it myself. I removed all the images. Probably got corrupted at the first attempt.
    n
    • 2
    • 2
  • d

    DesertRodent

    06/11/2022, 1:14 PM
    hey guys! Supabase newbie here. I have just done a 'login' page and now trying to retrive data from the fetch API. When i try this i get an error: "permission denied for table [name]" code 42501. Do you need to pass in any clever credentials or is it smart enough to cover the auth tokens etc? RLS is disabled so not sure how to resolve.
    n
    g
    • 3
    • 12
  • h

    Haus Of Alejandro

    06/11/2022, 3:46 PM
    Hello everyone! I was wondering what is the best way possible today for executing different writes from an action?, a transaction-like process. To be more specific, when I create a user (auth), I want to create a row linked to this user in different tables in public database (ex. wallet, profile, etc). I was thinking about create a trigger, which calls a function, that function will handle the insert in different tables and it would work. But I was thinking... what if some of these inserts fails for any reason, will I end up with inconsistent data? with partial inserts or any thing like that?, if so... there's any way to avoid that risk? thanks a lot in advance
    n
    g
    • 3
    • 4
  • n

    Niclas

    06/11/2022, 4:38 PM
    Hello, is there any article or documentation on the upgrade process of a self hosted supabase docker image to prevent downtime? I did not find any guideline on upgrading the self hosted supabase instance at all, thanks in advance.
    n
    s
    • 3
    • 2
  • m

    Mike_

    06/11/2022, 5:45 PM
    Not sure if this is a feature or a bug, but - When I try to create a column in the supabase UI like "postIds" which is an array of uuids that are meant to reference records in another table - I'm only able to create it if I don't include a foreign key relation. Is this just just a Postgres limitation, or...?
    n
    g
    • 3
    • 6
  • j

    Josh Adams

    06/11/2022, 5:50 PM
    I deployed supabase via the helm chart in the fork of the most recent PRs on the community helm chart repo. It comes up fine but when i try to connect to 'default project' in studio the api call to the rest service fails with a 401
    n
    • 2
    • 7
  • g

    Gubo

    06/11/2022, 7:30 PM
    Hello. Not sure what is the issue, but I cannot sign up to Supabase. I clicked "Start your project" and then signed in to my Github account, but this is the error that is displayed in the address bar: #error=unauthorized_client&error_code=401&error_description=Unverified+email+with+github I haven't receive any confirmation email (besides the one from Github informing me that I am sharing data with Supabase)... Did I do anything wrong? (Edge browser arm64, macOS)
    n
    s
    • 3
    • 2
  • d

    Dembe

    06/11/2022, 7:44 PM
    Hi, in my storage I have categories/sport/football and inside football i have 2 images, and in sport folder i have a also a subfolder, golf with 1 image. But could I somehow grab that sport folder and get back all the images from each subfolder from sport folder?
    Copy code
    const { data, error } = await supabaseAdmin.storage
        .from("gallery")
        .list("categories/sport", {
          limit: 100,
          offset: 0,
        });
    Wiht this i just get back the folder, but not the images or subfolder. Is this possible?
    n
    g
    • 3
    • 13
  • j

    Josh Adams

    06/11/2022, 8:33 PM
    I have supabase running now and have been able to use it, but I only have the 'default project' and I don't see how to create new projects
    n
    g
    • 3
    • 3
  • j

    jar

    06/11/2022, 9:25 PM
    can i read a json response in sql editor without just saying [object Object] ...
    n
    s
    • 3
    • 3
  • h

    Haus Of Alejandro

    06/11/2022, 11:03 PM
    Hello everyone! does anyone knows how can I set the limit for the records to INSERT for a particular table?, what I want to achieve is to prevent the user to be able to INSERT multiple rows in a single call. I can do that from the front-end but of course I would like to ensure that from the DB itself for security reasons. Thanks in advance!
    n
    g
    • 3
    • 10
  • o

    owyah

    06/12/2022, 1:57 AM
    Hi everyone, does anyone knows about raw query feature in javascript version?
    n
    g
    s
    • 4
    • 20
  • b

    Bicijay

    06/12/2022, 2:09 AM
    My database is getting reseted (all data is getting deleted) when i run supabase stop and supabase start again on my local environment, how do i fix it?
    n
    s
    • 3
    • 5
  • j

    jar

    06/12/2022, 3:52 AM
    Can I getPublicUrl from sql?
    select publicURL from storage.objects where id = '...'
    something like this maybe. But i dont see a url in that so maybe something else
    n
    g
    • 3
    • 11
  • b

    Borisdm

    06/12/2022, 5:30 AM
    Hello, is their anyway to check a user input filed in rls policy. So what I want to achieve is to check in user profile if the location field id matches to a data which is coming from front end. Thanks
    n
    g
    s
    • 4
    • 4
  • t

    Tomasz SzczuciƄski

    06/12/2022, 1:33 PM
    Hello, I wanted to ask about triggers on delete event. Is there a way to use something like "new" keyword for removed row? It seems that if I'm using
    new
    in function triggered by on delete trigger, it's not working properly. Thanks for help 🙂
    n
    v
    h
    • 4
    • 6
  • b

    Big Bird

    06/12/2022, 1:40 PM
    Is there a way to limit rows from
    talents
    based on data from
    proposals
    table in this query? Like I only want rows from
    talents
    if if a match between
    talents.id
    and
    proposals.talent_id
    Copy code
    let { data, error } = await supabase
                .from('jobs')
                .select(`*, proposals(*), talents(*)`)
                .ilike('address', jobAddress)
    n
    g
    • 3
    • 3
1...283284285...316Latest