csv - Is it possible for python to read a column and assign every row in that column a separate variable? -
i don't have code right now, if possible, start after inputting csv file?
maybe there's easier way of doing this, once can assign each cell own variable i'd use pyad validate if variable disabled or enabled in python against active directory
decided turn comment answer.
you need "assign every row in column separate variable", hence assume want every cell in column own separate variable
i not sure how use pyad
, logically if need access each row name, recommend using python dictionary accomplish task.
before beginning read through csv file, create empty dictionary; read through column, create new entries in dictionary key variable name wanted, , value value of cell. can access values regularly instead of variable_name
need use dict_name["variable_name"]
.
Comments
Post a Comment