Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

114
Visualizações
Adding named constrained mysqli with a variable reference table name

I am trying to create a table with a named constrained, however it is not being created. I tracked the problem to be in this line:

CONSTRAINT $fk_post_id_lik FOREIGN KEY(post_id) REFERENCES $posts (global_id)

where $posts is the name of a table created before. Does anyone know what could be wrong?

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

Turns out the table $posts was being created AFTER this one, for which, when this table was being created, it did not find the required table. Silly mistake.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda