News for hackers. Stuff that matters.
Re:SQL Tips and Tricks by adamzochowski on Wednesday September 25, 2024 @01:57AM (#41644122)
Can you expand on this? How is having

    WHERE 1=1
    AND ...[usual-where-clause]...
A performance and security compared to doing

    WHERE ...[usual-where-clause]...
Re:SQL Tips and Tricks by AtNightWeCode on Wednesday September 25, 2024 @11:27AM (#41648535)
If you use it in the same way you use trailing commas. Fair. But the site says to make it easier to add dynamic conditions. Which is a terrible idea in maybe not all but many SQL engines.