Skip to content

Instantly share code, notes, and snippets.

@igo
igo / fixed-migration.sql
Last active February 12, 2022 13:25
Prisma next-auth SQL migration v3 to v4
-- DropForeignKey
ALTER TABLE "Account" DROP CONSTRAINT "Account_userId_fkey";
-- DropForeignKey
ALTER TABLE "Session" DROP CONSTRAINT "Session_userId_fkey";
-- DropIndex
DROP INDEX "Account_providerId_providerAccountId_key";
-- DropIndex
# Bulk API design
# test
# resources :posts
class PostsController < ActiveController::Base
# GET /posts/1,4,50,90
# post_url([ @post, @post ])
def show_many
@posts = Post.find(params[:ids])
end
@igo
igo / init.yml
Created October 11, 2013 17:42 — forked from renoirb/init.yml
#
# How to install automatically Oracle Java 7 under Salt Stack
#
# Thanks Oracle for complicating things :(
#
# 1. Create a java/ folder in your salt master
# 2. Paste this file in init.sls
# 3. salt '*' state.sls java
#
# Source: