You need to select the company1 .. company3 in three separate queries and concatenate those using UNION. then you need to generate a new sequence number using your existing sequence number. To keep the rows in order so company1 records come first and company3 records come last you need to add one more identifier for precedence. Then you feed both to ROW_NUMBER() and you are done.
WITH cte AS
(
SELECT 1 AS SrNrGroup, SrNr, Company1 AS Company FROM yourtable WHERE Company1 IS NOT NULL
UNION ALL
SELECT 2 AS SrNrGroup, SrNr, Company2 FROM yourtable WHERE Company2 IS NOT NULL
UNION ALL
SELECT 3 AS SrNrGroup, SrNr, Company3 FROM yourtable WHERE Company3 IS NOT NULL
)
SELECT ROW_NUMBER() OVER(ORDER BY SrNrGroup, SrNr) AS SrNr, Company FROM cte