Moving to juliadb from dataframes and getting error joining tables, dataframes join ok

bww00
Thu, 07 Jul 2022 13:32:33 +0000
General Usage

Moving to juliadb from dataframes and getting error joining 2 tables.
ERROR: LoadError: UndefRefError: access to undefined reference

error is on the join statement

tables load ok.
Any help appreciated

code and error below

load juliadb table from csv

join inventory, ops and da2

using Pkg

pkg.add(“DataFrames”)

using DataFrames

pkg.add(“CSVFiles”)

using CSVFiles

using Dates

import Dates

Pkg.add(“MD5”)

using MD5

Pkg.add(“SHA”)

using SHA

using Pkg

Pkg.add(“JuliaDB”)

using JuliaDB

Pkg.add(“JuliaDBMeta”)

#######################

load da2

#cclops_unique =DataFrame(load(“C:\Users\bwwebb\Downloads\uniqops_2022_06_29_sv.csv”))

load inventory

#cclinvent =DataFrame(load(“w:\bwdata_c_bwdata\bw_copy_ccl_inentory_2022_06_10_09_44_sv.csv”))

load DA2 unique

#cclda2 = DataFrame(load(“w:\bwdata_c_bwdata\bw_ccl_DA2_unique_2022_06_29_09_44_sv.csv”))

load smart templates, ge view, labels

#cclst = DataFrame(load(“w:\bwdata_c_bwdata\bw_ccl_unique_smart_temp_labels_22022_07_06_sv.csv”))

join on OBJECT_NAME from ops and da2 Jays new file combined ops da2

#bwjoinout_inv_ops_da2 = outerjoin(cclda2,cclops_unique,cclst,cclinvent, on=:OBJECT_NAME,makeunique=true)

save dataframe

save(“w:\bwdata_c_bwdata\bwjoinout_inv_ops_da2_sv.csv”, bwjoinout_inv_ops_da2)

#bwjoinout_1_2_3_4_obj_prgonly =DataFrame(load(“c:\bwdata\bwjoinout_1_2_3_4_obj_prgonly_aft_match_sv.csv”))

#bwjoinout_obj_stmplt = outerjoin(bwjoinout_1_2_3_4_obj_prgonly,cclst, on=:OBJECT_NAME,makeunique=true)

save(“w:\bwdata_c_bwdata\bwjoinout_obj_stmplt_sv.csv”, bwjoinout_obj_stmplt)

try juliadb

cclst_jdbt = loadtable(“w:\bwdata_c_bwdata\bw_ccl_unique_smart_temp_labels_22022_07_06_sv.csv”)

bwjoinout_1_2_3_4_obj_prgonly_jdbt = loadtable(“c:\bwdata\bwjoinout_1_2_3_4_obj_prgonly_aft_match_sv.csv”)

println(cclst_jdbt)

join(bwjoinout_1_2_3_4_obj_prgonly_jdbt, cclst_jdbt; how = :outer, lkey=:OBJECT_NAME, rkey=:OBJECT_NAME)

#bwjoinout_obj_stmplt_jdbt = outerjoin(bwjoinout_1_2_3_4_obj_prgonly,cclst, on=:OBJECT_NAME,makeunique=true)

save(bwjoinout_obj_stmplt_jdbt, “w:\bwdata_c_bwdata\bwjoinout_obj_stmplt_jdbt.jdb”)
ERROR: LoadError: UndefRefError: access to undefined reference
Stacktrace:
[1] getindex
@ C:\Users\bwwebb.julia\packages\WeakRefStrings\gPvrY\src\WeakRefStrings.jl:314 [inlined]
[2] copyto_unaliased!(deststyle::IndexLinear, dest::Vector{String}, srcstyle::IndexLinear, src::WeakRefStrings.StringVector{String})
@ Base .\abstractarray.jl:970
[3] copyto!
@ .\abstractarray.jl:950 [inlined]
[4] copyto_axcheck!(dest::Vector{String}, src::WeakRefStrings.StringVector{String})
@ Base .\abstractarray.jl:1056
[5] Array
@ .\array.jl:540 [inlined]
[6] convert
@ .\array.jl:532 [inlined]
[7] DataValueArray
@ C:\Users\bwwebb.julia\packages\DataValues\N7oeL\src\array\typedefs.jl:13 [inlined]
[8] DataValueArray
@ C:\Users\bwwebb.julia\packages\DataValues\N7oeL\src\array\constructors.jl:8 [inlined]
[9] (::IndexedTables.var"#287#289"{Vector{Bool}, Vector{Int64}})(col::WeakRefStrings.StringVector{String})
@ IndexedTables C:\Users\bwwebb.julia\packages\IndexedTables\Jw0SP\src\join.jl:462
[10] map(f::IndexedTables.var"#287#289"{Vector{Bool}, Vector{Int64}}, t::Tuple{WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}})
@ Base .\tuple.jl:226
[11] map(::Function, ::NamedTuple{(:match, :OBJECT, :CCLGROUP, :NODE_NAME, :BINARY_CNT, :CHECKSUM, :MAJOR_VERSION, :MINOR_VERSION, :UTC_TMP2_9, :USER_NAME, :UTC_TMP2_11, :UPDT_ID, :UPDT_TASK, :UPDT_CNT, :UPDT_APPLCTX, :TIMESTAMP_DT_TM, :UPDT_DT_TM, :OBJECT_1, :CCLGROUP_1, :NODE_NAME_1, :BINARY_CNT_1, :CHECKSUM_1, :MAJOR_VERSION_1, :MINOR_VERSION_1, :UTC_TMP2_9_1, :USER_NAME_1, :UTC_TMP2_11_1, :UPDT_ID_1, :UPDT_TASK_1, :UPDT_CNT_1, :UPDT_APPLCTX_1, :TIMESTAMP_DT_TM_1, :UPDT_DT_TM_1, :OBJECT_2, :CCLGROUP_2, :NODE_NAME_2, :BINARY_CNT_2, :CHECKSUM_2, :MAJOR_VERSION_2, :MINOR_VERSION_2, :UTC_TMP2_9_2, :USER_NAME_2, :UTC_TMP2_11_2, :UPDT_ID_2, :UPDT_TASK_2, :UPDT_CNT_2, :UPDT_APPLCTX_2, :TIMESTAMP_DT_TM_2, :UPDT_DT_TM_2, :OBJECT_3, :CCLGROUP_3, :NODE_NAME_3, :BINARY_CNT_3, :CHECKSUM_3, :MAJOR_VERSION_3, :MINOR_VERSION_3, :UTC_TMP2_9_3, :USER_NAME_3, :UTC_TMP2_11_3, :UPDT_ID_3, :UPDT_TASK_3, :UPDT_CNT_3, :UPDT_APPLCTX_3, :TIMESTAMP_DT_TM_3, :UPDT_DT_TM_3), Tuple{WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing,
Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}}})
@ Base .\namedtuple.jl:197
[12] join(f::typeof(IndexedTables.concat_tup), left::NextTable{Columns{NamedTuple{(:match, :OBJECT, :OBJECT_NAME, :CCLGROUP, :NODE_NAME, :BINARY_CNT, :CHECKSUM, :MAJOR_VERSION, :MINOR_VERSION, :UTC_TMP2_9, :USER_NAME, :UTC_TMP2_11, :UPDT_ID, :UPDT_TASK, :UPDT_CNT,
:UPDT_APPLCTX, :TIMESTAMP_DT_TM, :UPDT_DT_TM, :OBJECT_1, :CCLGROUP_1, :NODE_NAME_1, :BINARY_CNT_1, :CHECKSUM_1, :MAJOR_VERSION_1, :MINOR_VERSION_1, :UTC_TMP2_9_1, :USER_NAME_1, :UTC_TMP2_11_1, :UPDT_ID_1, :UPDT_TASK_1, :UPDT_CNT_1, :UPDT_APPLCTX_1, :TIMESTAMP_DT_TM_1, :UPDT_DT_TM_1, :OBJECT_2, :CCLGROUP_2, :NODE_NAME_2, :BINARY_CNT_2, :CHECKSUM_2, :MAJOR_VERSION_2, :MINOR_VERSION_2, :UTC_TMP2_9_2, :USER_NAME_2, :UTC_TMP2_11_2, :UPDT_ID_2, :UPDT_TASK_2, :UPDT_CNT_2, :UPDT_APPLCTX_2, :TIMESTAMP_DT_TM_2, :UPDT_DT_TM_2, :OBJECT_3, :CCLGROUP_3, :NODE_NAME_3, :BINARY_CNT_3, :CHECKSUM_3, :MAJOR_VERSION_3, :MINOR_VERSION_3, :UTC_TMP2_9_3, :USER_NAME_3, :UTC_TMP2_11_3, :UPDT_ID_3, :UPDT_TASK_3, :UPDT_CNT_3, :UPDT_APPLCTX_3, :TIMESTAMP_DT_TM_3, :UPDT_DT_TM_3), Tuple{String, String, String, Union{Missing, Int64}, String, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Missing, String,
Missing, Missing, Missing, Missing, Missing, String, String, String, Union{Missing, Int64}, String, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Missing, String, Missing, Missing, Missing, Missing, Missing, String, String, String, Union{Missing, Int64}, String, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Missing, String, Missing, Missing, Missing, Missing, Missing, String, String, String, Union{Missing, Int64}, String, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Union{Missing, Int64}, Missing, String, Missing, Missing, Missing, Missing, Missing, String, String}}, NamedTuple{(:match, :OBJECT, :OBJECT_NAME, :CCLGROUP, :NODE_NAME, :BINARY_CNT, :CHECKSUM, :MAJOR_VERSION, :MINOR_VERSION, :UTC_TMP2_9, :USER_NAME, :UTC_TMP2_11, :UPDT_ID, :UPDT_TASK, :UPDT_CNT, :UPDT_APPLCTX, :TIMESTAMP_DT_TM, :UPDT_DT_TM, :OBJECT_1, :CCLGROUP_1, :NODE_NAME_1, :BINARY_CNT_1, :CHECKSUM_1, :MAJOR_VERSION_1, :MINOR_VERSION_1, :UTC_TMP2_9_1, :USER_NAME_1, :UTC_TMP2_11_1, :UPDT_ID_1, :UPDT_TASK_1, :UPDT_CNT_1, :UPDT_APPLCTX_1, :TIMESTAMP_DT_TM_1, :UPDT_DT_TM_1, :OBJECT_2, :CCLGROUP_2, :NODE_NAME_2, :BINARY_CNT_2, :CHECKSUM_2, :MAJOR_VERSION_2, :MINOR_VERSION_2, :UTC_TMP2_9_2, :USER_NAME_2, :UTC_TMP2_11_2, :UPDT_ID_2, :UPDT_TASK_2, :UPDT_CNT_2, :UPDT_APPLCTX_2, :TIMESTAMP_DT_TM_2, :UPDT_DT_TM_2, :OBJECT_3, :CCLGROUP_3, :NODE_NAME_3, :BINARY_CNT_3, :CHECKSUM_3, :MAJOR_VERSION_3, :MINOR_VERSION_3, :UTC_TMP2_9_3, :USER_NAME_3, :UTC_TMP2_11_3, :UPDT_ID_3, :UPDT_TASK_3, :UPDT_CNT_3, :UPDT_APPLCTX_3, :TIMESTAMP_DT_TM_3, :UPDT_DT_TM_3), Tuple{WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Missing}, WeakRefStrings.StringVector{String}, Vector{Missing}, Vector{Missing}, Vector{Missing}, Vector{Missing}, Vector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Missing}, WeakRefStrings.StringVector{String}, Vector{Missing}, Vector{Missing}, Vector{Missing}, Vector{Missing}, Vector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Missing}, WeakRefStrings.StringVector{String}, Vector{Missing}, Vector{Missing},
Vector{Missing}, Vector{Missing}, Vector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, WeakRefStrings.StringVector{String}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Union{Missing, Int64}}, Vector{Missing}, WeakRefStrings.StringVector{String}, Vector{Missing}, Vector{Missing}, Vector{Missing}, Vector{Missing}, Vector{Missing}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}}}}}, right::NextTable{Columns{NamedTuple{(:DA2LIT, :OBJECT_NAME, :CDF_MEANING, :CODE_SET, :CODE_VALUE, :CKI, :DEFINITION), Tuple{String, String, String, Int64, Int64, String, String}}, NamedTuple{(:DA2LIT, :OBJECT_NAME, :CDF_MEANING, :CODE_SET, :CODE_VALUE, :CKI, :DEFINITION), Tuple{WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}, Vector{Int64}, Vector{Int64}, WeakRefStrings.StringVector{String}, WeakRefStrings.StringVector{String}}}}}; how::Symbol, group::Bool, lkey::Symbol, rkey::Symbol, lselect::NTuple{65, Int64}, rselect::NTuple{6, Int64}, name::Nothing, keepkeys::Bool, init_group::Nothing, accumulate::Nothing, cache::Bool)
@ IndexedTables C:\Users\bwwebb.julia\packages\IndexedTables\Jw0SP\src\join.jl:458
[13] #join#291
@ C:\Users\bwwebb.julia\packages\IndexedTables\Jw0SP\src\join.jl:504 [inlined]
[14] top-level scope
@ \hnas1-users\USERS\bwwebb\My Documents\bwwdata\juliacode\bw_load_juliadb_from_csv.jl:56
in expression starting at \hnas1-users\USERS\bwwebb\My Documents\bwwdata\juliacode\bw_load_juliadb_from_csv.jl:56

2 posts - 2 participants