Skip to content

Commit

Permalink
Merge pull request #20 from tomroh/devel
Browse files Browse the repository at this point in the history
version 0.4.0
  • Loading branch information
tomroh authored Jan 16, 2023
2 parents 12aa0b7 + 112c142 commit 293b762
Show file tree
Hide file tree
Showing 37 changed files with 2,303 additions and 989 deletions.
2 changes: 2 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@
_pkgdown.yml
^pkgdown/
^inst/tests$
TODO.md
^.lintr$
9 changes: 9 additions & 0 deletions .lintr
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
linters: linters_with_defaults(
line_length_linter(80),
single_quotes_linter = NULL,
object_name_linter = object_name_linter("camelCase")
)
encoding: "UTF-8"
exclusions: list(
"inst/"
)
8 changes: 5 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
Package: bcputility
Type: Package
Title: Wrapper for SQL Server bcp Utility
Version: 0.3.1
Version: 0.4.0
Authors@R: person("Thomas", "Roh", email = "[email protected]", role = c("aut", "cre"))
Description: Provides functions to utilize a command line utility that does bulk inserts and exports from SQL Server databases.
License: MIT + file LICENSE
Encoding: UTF-8
RoxygenNote: 7.2.0
RoxygenNote: 7.2.2
SystemRequirements: bcp Utility
Imports: data.table, DBI, odbc, sf
Depends: R (>= 3.5.0)
Imports: data.table, sf, methods
Suggests: blob
URL: https://bcputility.roh.engineering, https://github.com/tomroh/bcputility
BugReports: https://github.com/tomroh/bcputility/issues
10 changes: 10 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,13 @@

export(bcpExport)
export(bcpImport)
export(bcpVersion)
export(checkTableExists)
export(createTable)
export(dropTable)
export(int)
export(makeConnectArgs)
export(mapDataTypes)
export(sqlcmdVersion)
export(varBinary)
export(varChar)
39 changes: 38 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,41 @@
# bcputility 0.3.1
# bcputility 0.4.0

* Override/set path to sqlcmd with
`options(bcputility.sqlcmd.path = "<path-to-sqlcmd>")`

* Added `bcpVersion` and `sqlcmdVersion` to check versions.

* Specify tables without schema strictly as a character vector of size 1 e.g.
```"<schema>.<table>"```. The schema and table will be quoted although special
characters are not recommended except for "_".

* Tests have been added that can run against a local instance of SQL Server.
These do not work without it as SQL Server is a client/server configuration.

* The README has been updated for new syntax and updated benchmarks.

* `bcpImport` and `bcpExport` gain a bcpOptions argument that allows the user
to include any options from the CLI. See documentation for formatting and
specification.

* The connections arguments for `bcpImport` and `bcpExport` have been
deprecated--server, database, username, password, trustedconnection. Use
`makeConnectArgs` for the connectargs argument which adds Azure AD
authentication and the option to disregard the trust server certificate.

* The "DBI" dependency has been dropped and all SQL Server queries are run
using bcp or sqlcmd.

* `mapDataTypes` is a convenience function to determine SQL Server data type
conversions. The defaults attempt to determine the smallest type size for
each column.

* `createTable`, `dropTable`, and `checkTableExists` have been added for
internals and convenience. The primary purpose would be to define an empty
table with user-defined types that `bcpImport` could append to.

* logicals no longer need to be converted from `FALSE/TRUE` to `0/1` before
importing in-memory data.

* The argument azure was added to `bcpImport` and `bcpExport` for Azure
Active Directory authentication. This only works for username and password
Expand Down
Loading

0 comments on commit 293b762

Please sign in to comment.