<commit_before><?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateAddressTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('address', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('user_id')->unsigned();
            $table->string('name');
            $table->string('street');
            $table->string('postcode');
            $table->integer('city_id')->unsigned();
            $table->string('email');
            $table->string('phone');
            $table->timestamps();

            $table->unique(['user_id','name', 'street', 'city_id']);

            $table->foreign('user_id')->references('id')->on('user')->onDelete('cascade');<commit_msg>Database: use index instead of unique for address columns<commit_after><?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateAddressTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('address', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('user_id')->unsigned();
            $table->string('name');
            $table->string('street');
            $table->string('postcode');
            $table->integer('city_id')->unsigned();
            $table->string('email');
            $table->string('phone');
            $table->timestamps();

            $table->index(['user_id', 'name', 'street', 'city_id']);

            $table->foreign('user_id')->references('id')->on('user')->onDelete('cascade');
{'fraction_non_alphanumeric': 0.17899891186071817, 'fraction_numerical': 0.0, 'mean_word_length': 2.6488095238095237, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 35, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4440287', 'n_tokens_mistral': 503, 'n_tokens_neox': 506, 'n_words': 80}