Database schema initially not designed for scaling, how to optimize it? I developped 2 years ago a back office for helping a logistic company to manage the deliveries.
At this time, the company only had one "partner" (let's call it Partner A).

The main table is delivery_note. 

I tried to design the database to be the more generic as possible. 
So I decided to put all the partner related fields in a dedicated table.

But two years later, we have 5 partners (and more are incoming) and I don't like to add a new FK in delivery_note each time we add a new partner.

The relation between a delivery_note and a partner is 1 1 (optional). In practice a delivery_note can be linked to only one partner.

The schema looks like:



Do you know any pattern or way to design a more flexible schema to handle this case ?

Thank you
I find your design a bit backword, can a delivery_note_partner_A exist without a corresponding delivery_note?
Assuming that is not the case, I would suggest:
CREATE TABLE delivery_note
( delivery_note_id ... NOT NULL PRIMARY KEY
, ...
); 

Depending on how much processing of the notes for each partner you are going to do, you may consider something like:
CREATE TABLE delivery_note_partner
( delivery_note_partner_id ... NOT NULL PRIMARY KEY
, delivery_note_id ... NOT NULL REFERENCES delivery_note (delivery_note_id)
, delivery_note JSON NOT NULL
); 

Whether the partner should reside in the JSON doc or as an attribute is a decision to make
EDIT:
After some discussion in a separate thread, this is the suggestion I proposed:
-- removed attributes delivery_not_parter_X
CREATE TABLE delivery_note (
 delivery_note_id int(11) NOT NULL AUTO_INCREMENT,
`status` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
...
PRIMARY KEY (delivery_note_id),
UNIQUE KEY `UNIQ_1E21328E551F0F81` (`order_number`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

-- sample data with above attributes removed
INSERT INTO `delivery_note` (`delivery_note_id`, `status`, `seller_name`, `first_name`, `last_name`, `email`, `street`, `street_extra`, `post_code`, `city`, `lat`, `lng`, `phone_number`, `phone_number2`, `residential_type`, `floor`, `elevator`, `service_type`, `order_number`, `order_picker_name`, `order_flow_origin`, `delivery_day`, `delivery_hour_start`, `delivery_hour_end`, `observation`, `internal_observation`, `created_at`, `updated_at`, `delivered_at`, `route_plan_order_id`, `route_customer_id`, `route_route_id`, `delivery_dday`) VALUES
(1, 'delivered',    'Sauvage',  'Adrien',   'Thibault', 'spotier@wanadoo.fr',   '16 rue des violettes', NULL,   '77500',    'Chelles',  48.89320500,    2.59495500, '0476134831',   NULL,   'house',    'fourth',   0,  'comfort',  '32027253', NULL,   'store_order',  '2020-01-02 00:46:52',  '2019-12-30 15:23:47',  '2019-12-30 16:45:03',  NULL,   NULL,   '2019-12-30 12:11:31',  '2019-12-30 12:11:31',  NULL,   93004,  8782,   NULL,   0),
...);    
-- new table
CREATE TABLE delivery_note_partner 
( delivery_note_partner_id int(11) NOT NULL AUTO_INCREMENT
, delivery_note_id int(11) NOT NULL
, delivery_note JSON NOT NULL
  -- example of generated column, for indexing purposes
, payment_method varchar(20) generated always as (delivery_note -&gt;&gt; '$.payment_method')
,     CONSTRAINT PK_DELIVERY_NOTE_PARTNER  
          PRIMARY KEY (delivery_note_partner_id)
,     CONSTRAINT AK1_DELIVERY_NOTE_PARTNER 
          UNIQUE (delivery_note_id)
,     CONSTRAINT FK_DELIVERY_NOTE 
          FOREIGN KEY (delivery_note_id)
          REFERENCES delivery_note (delivery_note_id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

-- Since MySQL does not support indexes on JSON, this is an example of an index for attributes that are used in predicates

CREATE INDEX X01_DELIVERY_NOTE_PARTNER ON delivery_note_partner (payment_method);

-- some migrated sample data for new table
INSERT INTO delivery_note_partner (delivery_note_id, delivery_note)
VALUES (1, '{ &quot;payment_method&quot;:&quot;credit_card&quot;, &quot;total_price_amount&quot;: 6500, &quot;total_price_currency&quot;:&quot;EUR&quot; }')
    ,  (12, '{ &quot;client_account_number&quot;:&quot;ACC605739261&quot; }')
    ,  (17, '{ &quot;sum_owed_amount&quot;:7500, &quot;sum_owed_currency&quot;:&quot;EUR&quot;, &quot;delivery_price_amount&quot;:2500, &quot;delivery_price_currency&quot;:&quot;EUR&quot; }');