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

    tijgersoftware

    08/04/2022, 10:23 AM
    Hi does someone know how I can make an stored procedure in the supabase cli using sql, or has a good reference where I can find that?
    n
    q
    • 3
    • 2
  • r

    red

    08/04/2022, 2:59 PM
    Hi, how many simultaneous realtime connections can the free db hold ?
    n
    g
    • 3
    • 4
  • r

    regisin

    08/04/2022, 4:59 PM
    What's the difference between having user profile data stored in the "user_metadata" vs a 'profile' table?
    n
    g
    q
    • 4
    • 5
  • j

    Joyboy

    08/04/2022, 5:43 PM
    Hi, I'm new to this kind of SaaS apps, I try a few things with the documentation and I found myself limited very soon, I was trying to make a UI for my web game where my registered users can change their avatar ( a field in his row in the profile table), choosing one from X existent avatars. The thing is, I don't want the user to be able to update all the row, but just a few field like the already mentined avatar. Other fields in the profile table may be acquired by microtransactions like premium currency amount. Should I make a backend API to handle this with service_role tokens instead of letting the user interact directly with the tables?
    n
    o
    • 3
    • 3
  • t

    Twisted Chaz

    08/04/2022, 6:03 PM
    Hey! Is it possible to create DB schemas in code and then push them to supabase? I'm looking for something similar to Laravels DB migrations but within a React ecosystem
    n
    m
    s
    • 4
    • 4
  • l

    Lukas V

    08/04/2022, 6:46 PM
    Hi, I have a json file that has 7000 ingredients, I looped through all of them and tried to write to supabase database, however for some reason 70% of the writes fail?
    Copy code
    const writeData = async () => {
          const { data, error } = await supabase.from('ingredientsjson').insert({
            productName: newIngredient.productName
          });
          if (error) {
            console.log(`${newIngredient.productName} document failed to write`);
          }
        };
        writeData();
    What is the reason for this, how can I even properly populate my database?
    g
    s
    +3
    • 6
    • 13
  • m

    maiikol1192

    08/04/2022, 7:25 PM
    Good afternoon to all, sorry for the inconvenience, I am trying to use realtime in my project, my intention is to be able to show alerts or database changes through a notification, I am using JS and I have not been able to make changes directly from the database so I can print something by console, I use VUE as a framework and I am bringing through a method that runs on the mounted but I do not receive any information, any help would be wonderful, thank you very much and happy day.
    n
    g
    • 3
    • 2
  • b

    bent

    08/04/2022, 7:37 PM
    How would I write this query with the querybuilder?
    select credit, website from collaborators, "participations-in-collabs", collabs where collaborators.id = "participations-in-collabs".collaborator and "participations-in-collabs".collab = collabs.id and collabs.id = SOME VARIABLE
    I tried
    Copy code
    js
    const {data, error} = await supabase.from('collabs').select(`
    collaborators (
      credit,
      website
    )`).eq('collabs.id', id);
    but I'm getting the following error:
    Copy code
    null {
      code: 'PGRST108',
      details: null,
      hint: "Verify that 'collabs' is included in the 'select' query parameter.",
      message: "Cannot apply filter because 'collabs' is not an embedded resource in this request"
    }
    n
    g
    • 3
    • 7
  • r

    regisin

    08/04/2022, 8:19 PM
    Any chance I could change the redirect url for auth actions? I want to handle such requests on my server, but can't parse the query parameters because supabase uses
    #
    instead of
    ?
    (For example:
    http://localhost:8000/endpoint#error=unauthorized_client&error_code=401&error_description=Email+link+is+invalid+or+has+expired
    ) Can I change somehow to be a valid query param url?
    n
    g
    • 3
    • 2
  • d

    Dillxn

    08/04/2022, 8:31 PM
    I have a unique authentication / authorization set up that I'd like to implement with Supabase. It will include multi-level authorization, so that a computer can be "logged in" to the system, and employees can "clock in" and have their own profiles underneath it. Employees won't stay logged in, but will enter a personal 4-digit code to authorize actions against the DB. Is this kind of set up possible with Supabase?
    n
    • 2
    • 1
  • s

    SchneckchenAndy

    08/04/2022, 9:11 PM
    Is there any info on when supabase realtime will work with views? The only workaround I found is making a new table that "syncs" with the view using a trigger and then subscribing to that table.
    n
    • 2
    • 1
  • l

    lopezjurip

    08/04/2022, 9:20 PM
    how can I check my current PostgREST version? I know you can get psql version with
    SELECT version();
  • c

    cptCrunch

    08/04/2022, 9:28 PM
    How do I resolve a 400 error when I'm testing a password reset action?
    n
    • 2
    • 1
  • a

    AlanK

    08/04/2022, 9:53 PM
    I have my database set up with a mix of email/password & invitation signup and I'm looking for inspiration: What kind of strategy do people suggest for periodically cleaning out the Users table of rows that are still awaiting confirmation after the link has expired?
    n
    • 2
    • 1
  • d

    Dillxn

    08/04/2022, 11:08 PM
    Can you authorize a DB query based on a value passed to the DB in addition to the JWT?
  • d

    Domcario

    08/05/2022, 2:08 AM
    is there a way to internally loop while doing bulk inserts? right now i'm just doing a for loop
    n
    • 2
    • 1
  • 49Ryann (2022-08-05)
    n

    Needle

    08/05/2022, 3:57 AM
    Hello @49Ryann! This thread has been automatically created from your message in #843999948717555735 a few seconds ago. We have already mentioned the @User so that they can see your message and help you as soon as possible! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ``...`` menu) and select "Leave Thread" to unsubscribe from future updates. Want to change the title? Use the ``/title`` command! We have solved your problem? Click the button below to archive it.
  • u

    49Ryann

    08/05/2022, 4:32 AM
    Is there anyway to autopopulate profile data into the logged user instead of a secondary call?
    n
    g
    • 3
    • 2
  • u

    49Ryann

    08/05/2022, 4:45 AM
    Does anyone know of a tutorial/guidance on handling multiple users under a main account table? I basically need users signed up and invited. That would be listed in an account table,
    n
    s
    • 3
    • 6
  • Absol (2022-08-05)
    n

    Needle

    08/05/2022, 4:51 AM
    Hello @TypeNull! This thread has been automatically created from your message in #843999948717555735 a few seconds ago. We have already mentioned the @User so that they can see your message and help you as soon as possible! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ``...`` menu) and select "Leave Thread" to unsubscribe from future updates. Want to change the title? Use the ``/title`` command! We have solved your problem? Click the button below to archive it.
    t
    o
    • 3
    • 2
  • u

    49Ryann

    08/05/2022, 7:12 AM
    Does anyone know if we have access to the user metadata when using a database function & trigger? Having a hard time finding that documented. When Signing up a user.
    n
    • 2
    • 1
  • c

    cryptic

    08/05/2022, 7:31 AM
    I am trying to get
    supabase/postgres
    running in k8s but every it starts, it fails and then says that I don't have permission to the directory. If I turn off persistent volume claims, it's fine. Any idea why?
    n
    • 2
    • 1
  • t

    TheOnlyTails

    08/05/2022, 10:18 AM
    I set up auth with the discord provider, and I was wondering if there's a way to get the discord API token to make requests?
    n
    • 2
    • 1
  • j

    Julien

    08/05/2022, 10:32 AM
    Is there a way to perform a transaction with a database insert and a file insert in a storage bucket? If not, I could maybe simulate it. Create a table which records file insert (table name: file_insert). When I'm going to insert a file in the storage bucket, I add a row in the table with the file path, file name and date of insertion (date of insertion is the date it tried to insert the file in case of failure). When the file insert is done, I perform a transaction which does the insert I want in the db and remove the corresponding record in the file_insert table. If the transaction fails, it's not a problem. I will have a function called each day that will look into the file_insert table for rows where the date of insertion is > than a given threshold. If the date of insertion is > than the given threshold, it means that the insertion in the storage bucket either succeed or failed but for sure the insertion in the db failed. In this case, I can delete the file from the storage bucket (if it exist in the storage bucket). Hence, it's similar to a transaction which includes the db insert and the file insert, right?
    n
    • 2
    • 1
  • j

    Jan Tennert

    08/05/2022, 12:47 PM
    I'm trying to update the auth token in a realtime subscription. Is that payload wrong? I'm getting phx_error when sending this:
    Copy code
    json
    {
      "topic": "realtime:public:products",
      "event": "access_token",
      "payload": {
        "access_token": "token"
      },
      "ref": null
    }
    n
    • 2
    • 1
  • 🆕 garyaustin (2022-08-05)
    n

    Needle

    08/05/2022, 1:08 PM
    Hello @garyaustin! This thread has been automatically created from your message in #843999948717555735 a few seconds ago. We have already mentioned the @User so that they can see your message and help you as soon as possible! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ``...`` menu) and select "Leave Thread" to unsubscribe from future updates. Want to change the title? Use the ``/title`` command! We have solved your problem? Click the button below to archive it.
  • d

    dhruv_casa

    08/05/2022, 2:34 PM
    Is supabase down? My project and dashboard are both not opening
    n
    g
    +2
    • 5
    • 4
  • c

    CodeCo

    08/05/2022, 3:15 PM
    This isn't related to Supabase. Does anyone know how I can style the gesture bar on Chrome for Android? The meta theme color only does the top bar, as shown.
    n
    • 2
    • 1
  • k

    Kiteflow

    08/05/2022, 3:31 PM
    Hi, is it possible to set the current date as the default value of a column?
    n
    s
    • 3
    • 2
  • g

    gel

    08/05/2022, 5:15 PM
    hey all -- getting a 504 error for my supabase project. cant connect to my project in the dashboard either.
    n
    g
    • 3
    • 9
1...312313314315316Latest