Python Forum
Database Submit Entry Syntax Error
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Database Submit Entry Syntax Error
#26
buran Wrote:@Denni, obviously you don't know what you are talking about. I don't care what you do in your code base, but don't confuse and mislead other users.
Actually @buran your response shows that you are the one that is clueless passing a parameterized list (aka sting) inserting variables (that could be strings) is exactly the same as concatenating a string within a string and thus creates the same issue -- further the documentation you quote does not take into the fact that would only be the case if the data had not already been scrubbed prior to being passed to the database class -- which is how it ought to be handled -- meaning that by the time I get to the actual database where I am building the data I am guaranteed that the data has nothing in it that would be dangerous including things that would simply cause a query to choke without it being an actual injection attack. Further due to the lameness of this response I am going to guess I have far more years of experience under my belt in a professional capacity than you do.

Still again since you seem to be rather slow on the pick up -- if you handle the data properly the threat of injection has already been dealt with long before you get to the where you create the database query because it has already been completely validated and scrubbed but if you are concerned that this is not the case then you add a validator/scrubber -- which by the way you cannot do using the methodology you are using but I can -- by simply passing the values into a validator/scrubber prior to concatenating them to the string query that is being built -- but then again I have already handled this long before I get to my actual database class as that kind of manipulation takes place in the controller

@Melford frustration is not okay if your object is to help someone as this frustration is most often due to the fact that the tutor is not communicating the information clearly as is the case with buran -- not only that he is instructing you improperly on how you ought to be doing this. Have you ever heard of MVC?

Also big note -- the only bad or stupid question is the unasked one if you are truly wanting to learn -- so always ask if you find your tutor is inadequate then find another one that can explain it to you -- but always be leery as not everyone knows how to code properly and they propagate a lot of misinformation because they have a false sense of superiority about themselves

If you would care to dial back a bit and look at my example you will find that it covers all the bits and pieces you need -- further it implements debugging prints to help you ascertain perhaps where something is being done not as you expect it would be done.
Reply


Messages In This Thread
Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 03:02 AM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 05:10 AM
RE: Database Submit Entry Syntax Error - by Denni - Jan-22-2020, 03:11 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 03:12 PM
RE: Database Submit Entry Syntax Error - by Denni - Jan-22-2020, 03:19 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 03:20 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 03:23 PM
RE: Database Submit Entry Syntax Error - by Denni - Jan-22-2020, 03:35 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 03:40 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 03:47 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 04:04 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 04:08 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 04:13 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 05:04 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 05:08 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 05:28 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 05:41 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 05:41 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 05:50 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 05:55 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 07:21 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 07:29 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 07:40 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-22-2020, 07:41 PM
RE: Database Submit Entry Syntax Error - by Melford - Jan-22-2020, 07:49 PM
RE: Database Submit Entry Syntax Error - by Denni - Jan-22-2020, 09:28 PM
RE: Database Submit Entry Syntax Error - by buran - Jan-23-2020, 04:15 AM
RE: Database Submit Entry Syntax Error - by Denni - Jan-27-2020, 04:20 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  [Tkinter] Error verify data in database TomasSanchexx 2 913 Aug-11-2023, 12:37 PM
Last Post: TomasSanchexx
  [PyGUI] Invalid command error with Entry object eliqm 8 2,221 May-18-2023, 10:14 PM
Last Post: eliqm
  [Tkinter] Trying to add data into a shelf from a submit button TWB 8 1,879 Jan-06-2023, 11:30 PM
Last Post: TWB
  Usborne Coding for Beginners using Python 'Dodge the Bombs' Syntax Error CMSheWolfe 5 3,920 Jun-18-2020, 09:41 PM
Last Post: deanhystad
  Transfer Toplevel window entry to root window entry with TKinter HBH 0 4,483 Jan-23-2020, 09:00 PM
Last Post: HBH
  Problem with Submit button Tkinter Reldaing 2 3,683 Jan-05-2020, 01:58 AM
Last Post: balenaucigasa
  [Tkinter] how to get the entry information using Entry.get() ? SamyPyth 2 3,515 Mar-18-2019, 05:36 PM
Last Post: woooee

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020