SupabaseS
Supabase•3y ago
Argzon

How to create a new entry on the user_logs table on each user login?

Hi everybody. I have a table named user_logs with columns: user_id, first_name, last_name, email, last_login, ip_address. I need to create a function that will insert auth user data to this table on each login. Please check the attached image of what I'm trying to achieve. Thank you in advance 😊

***
btw: im using Nextjs and cookies for login session
accounts_table.png
Was this page helpful?