Skip to content

Need some more documentation #45

Answered by maxtoroq
ensemblebd asked this question in Q&A
Discussion options

You must be logged in to vote

SQL.INSERT_INTO() is just a shortcut to new SqlBuilder().INSERT_INTO().

About executing, you can choose different levels to work at:

1. ADO.NET: You can use CreateCommand(DbConnection, SqlBuilder) or CreateCommand(DbProviderFactory, SqlBuilder) to turn the SqlBuilder into a DbCommand. From that point on, you are responsible for opening the connection and calling ExecuteNonQuery.

2. Database class: The Database class makes things easier. You can call the Execute method like in your example. Database creates a connection when you pass a connection string in the constructor, or you can provide your own DbConnection. Database always uses the same connection, which opens and closes as necessar…

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by maxtoroq
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #45 on December 08, 2020 23:45.