Create One To Many Database Relationship - Flask Fridays #28

Поделиться
HTML-код
  • Опубликовано: 30 сен 2024

Комментарии • 30

  • @Codemycom
    @Codemycom  3 года назад +1

    ▶️ Watch Entire Flask Friday Playlist ✅ Subscribe To My RUclips Channel:
    bit.ly/3ig2eJn bit.ly/2IGzvOR
    ▶️ See More At: ✅ Join My Facebook Group:
    Codemy.com bit.ly/2GFmOBz
    ▶️ Learn to Code at Codemy.com ✅ Buy a Codemy T-Shirt!
    Take $30 off with coupon code: youtube1 bit.ly/2VC9WUN
    ▶️ Get The Code
    bit.ly/2L1jBl5

  • @lewis_online
    @lewis_online 2 года назад +5

    Can I just say, I'm building my first big project with Python and Flask, and these videos have been a god send. Thank you so much.

  • @BlackMountStreet88
    @BlackMountStreet88 2 года назад +1

    Is there any way Limiting the number of the Many in a one-to-many relationship
    e.g.
    1 user may have only 5 posts ??

  • @georgiyveter6391
    @georgiyveter6391 Год назад

    Two tables are created in sqlalchemy, relationship 1:1 (primary key of the first table is the foreign and also the primary key in the second table). When a child is created in the second table, then I can't change (and delete) the parent record. Why it doesn't update cascade?

  • @Kennethlumor
    @Kennethlumor 2 года назад

    Sir please and please what I mean is a separate database('double') that will have separate (db.Model, UserMixin) not to inherent from User

  • @Kennethlumor
    @Kennethlumor 2 года назад

    Because let's assume I want to create different databases for supper admin and User but should be separate

  • @theninjew9971
    @theninjew9971 2 года назад

    How redirect to new created article after creation new article?

  • @wordwonders365
    @wordwonders365 2 года назад

    Please my code is saying current_user is not defined in my routes.py. please what's the solution?

    • @Codemycom
      @Codemycom  2 года назад +2

      Rewatch the video and try to determine what you missed

  • @georlybibas5846
    @georlybibas5846 Год назад

    Good day, John. This series has been a great help this week and Imma finished this through. Just got a question. In my case, even if I delete all of my users and posts before migrating and upgrading like you did in the video, my database still had the previous id, what I mean by that is that if let's say the last user I created and deleted is user 18, after migrating and upgrading, if I make a new user, it's id is 19, so why is that? While yours resets at user 1?

    • @Codemycom
      @Codemycom  Год назад

      You did something differently from the video...

  • @peterkaranja60
    @peterkaranja60 2 года назад

    how do you separate user accounts in a way that user A can not view user B data and vice-versa assuming I want to build an e-commerce site. Any help on this would be much appreciated.

    • @Codemycom
      @Codemycom  2 года назад

      The authentication system does that by default.

  • @spectrum8200
    @spectrum8200 2 года назад

    hi
    when flask db upgrade
    there is ERROR [flask_migrate] Error: No support for ALTER of constraints in SQLite dialect. Please refer to the batch mode feature which allows for SQLite migrations using a copy-and-move strategy.
    so i try to use batch mode
    migrate = Migrate(app, db, render_as_batch=True)
    but there is ValueError: Constraint must have a name
    what can i do to resolve?

    • @Codemycom
      @Codemycom  2 года назад +1

      no clue what you're doing or why. Sorry.

    • @liborhavranek2760
      @liborhavranek2760 Год назад

      I had the same problem if my code not working i copy code from githup and code work good. i dont know what misstake i did but if you copy that part of code from github it should work. Copy all class if i coppy only line of code it not working

  • @santiagoortiz7625
    @santiagoortiz7625 2 года назад

    life saver

  • @teclote
    @teclote 10 месяцев назад

    That backref is cool as heck.

  • @СанжарТокан-э2щ
    @СанжарТокан-э2щ Год назад

    that's amazing

  • @muntadher8087
    @muntadher8087 2 года назад

    Thank you so much

  • @shenseanchen
    @shenseanchen 2 года назад

    Incredible

  • @franzxavier7565
    @franzxavier7565 3 года назад +1

    Can you teach me a tutorial on how to make an essay paraphrase using tkinter

    • @Codemycom
      @Codemycom  3 года назад

      This is a Flask Series.

  • @Nixda200
    @Nixda200 2 года назад

    How about "bidirectional one to many" introduction? Would be great to see :)