From 824ec8472761c1d3a68515a919a2150314e23eba Mon Sep 17 00:00:00 2001 From: Erik Loualiche Date: Tue, 30 Jan 2024 13:44:04 -0600 Subject: [PATCH] Password not printed --- src/ImportComp.jl | 4 ++-- src/Utilities.jl | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/src/ImportComp.jl b/src/ImportComp.jl index 98263d9..3829190 100644 --- a/src/ImportComp.jl +++ b/src/ImportComp.jl @@ -34,7 +34,7 @@ Import the funda file from CapitalIQ Compustat on WRDS Postgres server """ function import_Funda(wrds_conn::Connection; date_range::Tuple{Date, Date} = (Date("1900-01-01"), Dates.today()), - variables::Vector{String} = nothing, + variables::Union{Nothing, Vector{String}} = nothing, filter_variables = Dict(:CURCD=>"USD") # if you want something fanciers ... export variable and do it later ) @@ -79,7 +79,7 @@ end function import_Funda(; date_range::Tuple{Date, Date} = (Date("1900-01-01"), Dates.today()), - variables::String = nothing, + variables::Union{Nothing, Vector{String}} = nothing, filter_variables::Dict{Symbol, Any} = Dict(:CURCD=>"USD"), user::String = "", password::String = "") diff --git a/src/Utilities.jl b/src/Utilities.jl index a835e49..9297e04 100644 --- a/src/Utilities.jl +++ b/src/Utilities.jl @@ -32,10 +32,8 @@ end function open_wrds_pg() # prompt to input print("Enter WRDS username: ... ") - # Calling rdeadline() function user = readline() - print("Enter WRDS password: ... ") - password = readline() + password = read(Base.getpass("Enter WRDS password: ... "), String); return open_wrds_pg(user, password); end # ------------------------------------------------------------------------------------------