Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

101
Vistas
Column names from MySQL table in the right order

I am using the following SQL command to get all column names from my table in MySQL:

SELECT column_name FROM information_schema.columns where table_name = 'сведения о фильме' and table_schema = 'videokassety2';

It give me all column names in the table 'сведения о фильме', however it sorts the results and gives me the following:

ID Компании
Год выпуска
Название фильма
Номер фильма
Основные исполнители
Характер фильма

However, I do not need sorting, I need the order in which they appear in the table itself, like the following:

enter image description here

How can I get a list of column_nmaes without any sorting?

Thank you

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

The column ordinal_position has the original column ordering information:

SELECT column_name
FROM information_schema.columns 
WHERE table_name = 'сведения о фильме' AND table_schema = 'videokassety2'
ORDER BY ordinal_position;
over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda