The first thing you mention in your reply is worth adding to the post, I'll update it right away.
About point 2, I think the same, it's better to take advantage of strongly typed things when possible since you can detect bugs earlier in your development process.
I didn't know about point 3, super useful information thank you for bringing in it up!
I think we are on the same page though since in the next line I'm assigning the SQL type explicitly through:
I'm glad I could help.
About AddWithValue - yes, you can use it like you've done.
Personally, I find using Add more readable - but that's probably a personal preference.
Cheers!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Thank you for your reply.
The first thing you mention in your reply is worth adding to the post, I'll update it right away.
About point 2, I think the same, it's better to take advantage of strongly typed things when possible since you can detect bugs earlier in your development process.
I didn't know about point 3, super useful information thank you for bringing in it up!
I think we are on the same page though since in the next line I'm assigning the SQL type explicitly through:
So I think it does the same as your line, please correct me if I'm wrong.
I'm glad I could help.
About
AddWithValue
- yes, you can use it like you've done.Personally, I find using
Add
more readable - but that's probably a personal preference.Cheers!