Hi
I have json file::
---------------------------------------------------------------------------------------------------------------------------------------------------------------------
{
"employees":
[
{ "Name":"John ssd" , "ID":"52" , "Department":"Graphics" },
{ "Name":"james Stone" , "ID":"45" , "Department":"Accounts" },
{ "Name":"fre rank" , "ID":"65" , "Department":"sales" }
]
}
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
I want's to load it into a DiscoDB
So I used this code
file_json_data = open("json", "r")
lines = file_json_data.read().replace("\n", "").replace("\t", "").replace(" ", "")
tup = ast.literal_eval(lines)
db = DiscoDB(tup)
it's saying error as ""TypeError: must be string or read-only buffer, not dict"
is it stores json files?