Closed RyanCLuis closed 9 months ago
Can you look at your actual database in neon and see what the columns are named - is there a dog column?
but in the models i have
Try to make migrations and then run them
would that have something to do with i created dog_id first and in my migrations i save it. so i would have to delete the database and set it up over again?
still the same error
You could try dropping the database and migrating again
do i need to delete all my migrations before? ie 0001_init___ 0002 xxxxx 0003xxxxx?
i delete the database and re migrate i had to recreate the superuser, but i can still add a pet. when i click on detail i get the same error, just a little different
This error is saying that your photo table does not exist. When you ran makemigrations, did it make any migration files or did it tell you there were no changes to be made?
it said no changed made
Describe the bug A clear and concise description of what the bug is. when i try and add a photo to the page, and error pops up saying "column main_app_photo.pet_id does not exist" but also gives me a hint of "HINT: Perhaps you meant to reference the column "main_app_photo.dog_id"." so somewhere it is trying to get a dog_id but i have nothing in my code the references dog_id. Before, when writing the code we started with dog to make things easier, then we switched over to pet.
What is the problem you are trying to solve? the dtails page wont show a picture.
Expected behavior A clear and concise description of what you expected to happen. when the page renders it is suppose to show no photo has been added, but instead it throws that error
What is the actual behavior? A clear and concise description of what actually happened.
Post any code you think might be relevant (one fenced block per file)
What is your best guess as to the source of the problem? im thinking maybe in the migrations somewhere it still has a dog_id and have no way of deleting that id
What things have you already tried to solve the problem? ive tried deleting all my migrations and migrating again and still throws up the same errors
Additional context Add any other context about the problem here.
Paste a link to your repository here the error is on my branch so inst on the repo https://github.com/RyanCLuis/Fur-Ever-Friends