importData: importData: Import views directly from NETN forest database

Description Usage Arguments Value Examples

View source: R/importData.R

Description

This function imports all views in the ANALYSIS schema of the NETN_Forest backend. Each view is added to a VIEWS_NETN environment in your workspace, or to your global environment based on whether new_env = TRUE or FALSE.

Usage

1
2
3
4
5
6
importData(
  instance = c("local", "server"),
  server = "localhost",
  name = "NETN_Forest",
  new_env = TRUE
)

Arguments

instance

Specify whether you are connecting to the local instance or server.

"local"

Default. Connects to local install of backend database

"server"

Connects to main backend on server. Note that you must have permission to access the server, and connection speeds are likely to be much slower than the local instance. You must also be connected to VPN or NPS network.

server

Quoted name of the server to connect to. Valid inputs are your computer name or "localhost" (default) for the local instance, or the server address (currently "INP2300VTSQL16\IRMADEV1") to connect to the main database.

name

Character. Specifies the name of the database. Default is "NETN_Forest"

new_env

Logical. Specifies which environment to store views in. If TRUE(Default), stores views in VIEWS_NETN environment. If FALSE, stores views in global environment

Value

NETN database views in specified environment

Examples

1
2
3
4
5
6
7
8
# Import using default settings of local instance, server = 'localhost' and add VIEWS_NETN environment
importData()

# Import using computer name (# should be real numbers)
importData(server = "INPNETN-######", new_env = TRUE)

# Import from main database on server
importData(server = "INP2300VTSQL16\\IRMADEV1", instance = "server", new_env = TRUE)

KateMMiller/forestNETN documentation built on May 30, 2021, 6:39 a.m.