Work
Founder & Leadership
Badges



Maker History
Forums
Do you ever find yourself worrying about not being the first to come up with or try something new?
I ve been thinking about starting a blog for a while, but today I saw a blog on a similar topic and thought, There are already so many blogs out there. Why would anyone want to read mine if I write one? I m actively working on getting past these feelings and have started trying out a few strategies. 1. Finding my own unique perspective: I realised that even if i'm not the first one to come up with an idea, my unique approach and perspective can add value to it which people may love and support. 2. Shifting my mindset from competition to collaboration: Seeing the people who have done something similar to me as potential collaborators and learning from each other's mistakes. 3. Celebrating small wins: I think this is important in any aspect of our lives. It helps us to stay motivated and recognize our hard work to date. 4. Enjoying the journey instead of obsessing over the destination: I m focusing more on the journey itself, which makes the whole process more rewarding than just reaching the end goal. What about you? Any tips that have worked for you? I'd love to hear them! Posting again cause I want to know all of your thoughts on this :)
Are you tired of writing boilerplate code when building dynamic SQL queries? Check my idea!
Suppose I need to build a dynamic WHERE clause:
StringJoiner sql = new StringJoiner(" AND ", "WHERE", ""); List<Object> args = new ArrayList<>(); if (ageGt != null) { sql.add("age > ?"); args.add(ageGt); } if (ageGe != null) { sql.add("age >= ?"); args.add(ageGe); } if (ageLt != null) { sql.add("age < ?"); args.add(ageLt); } // ... return sql.toString();There will be more and more if statements to meet new requirements and all the if statements share the same structure: check if the value is not null and append the query condition if true. It's kinda boilerplate and also a signal for refactoring code in software engineering. We just put the parameters together as the article said and build the SQL in the reflection way will save me a lot of time to write the IFs.
public class UserQuery { private Integer ageGt; // age > ? private Integer ageGe; // age >= ? private Integer ageLt; // age < ? }
I need advice. Help me out :)
Do you face workload issues in your software QA testing methods? What's the best strategy?