|
|
|
|
|
by bvrmn
563 days ago
|
|
How SQLc would solve following issue. For example I have original query: SELECT * from users where following_count > $1 and followers_count < $2;
Then some refactoring later it becomes: SELECT * from users where enabled and followers_count < $1 and following_count > $2;
As I understand go API would not change it still query(int, int). |
|
More likely you would introduce a new query that would get a new function call.
usersWithCountBetween(a, b)
vs
enabledUsersWithCountBetween(a,b)
If you mean, how to handle the addition of a new enabled flag that is passed in, that too would either require refactoring or a new function.
These aren't really things I would consider a problem but maybe I'm missing something?
Oh and you can configure the number of params before it replaces the params with an interface so things like this are easier to manage over time.