Questions tagged [tinydb]

TinyDB is document oriented database written in pure Python.

TinyDB is a query processing system for extracting information from a network of TinyOS sensors.

Unlike existing solutions for data processing in TinyOS, TinyDB does not require you to write embedded C code for sensors. Instead, TinyDB provides a simple, SQL-like interface to specify the data you want to extract, along with additional parameters, like the rate at which data should be refreshed -- much as you would pose queries against a traditional database.

http://telegraph.cs.berkeley.edu/tinydb/

98 questions
0
votes
2 answers

How to extract single field from Tiny DB search

I populate my db, then make a search, I can print the results but I want extract the fields to populate labels or entries, how can I do it ? This is my code from tinydb import TinyDB, Query, where db = TinyDB('rubrica.json') def populate(): …
patel
  • 430
  • 1
  • 4
  • 9
0
votes
1 answer

TinyDB insert in between table rows

The only way I can find of adding new data to a TinyDB table is with the table.insert() method. However this appends the entry to the end of the table, but I would like to maintain the sequence of entries and sometimes I need to insert into an…
Spencer
  • 1,931
  • 1
  • 21
  • 44
0
votes
1 answer

TinyDB on MIT App Inventor won't save data between screens

I'm a teacher of a CS class at a high school, and I don't have a ton of programming background, but my students are running into this issue: They want to make an app that keep a username and password in a TinyDB so they can log in between screens.…
0
votes
1 answer

How to delete something in Tinydb/python in command line python

Hey i have here my code: elif command == 'del' or command == 'delete': Cat_Del = input('Which Category do you wanna delete: ') Name_Del = input('Whats the name ') Category = Query() Name = Query() Every_Del =…
0
votes
1 answer

How do i remove "default"?

i have been having some problems understanding where i went wrong in my codes. I have been trying to print out the output of my codes into a json file but apparently, my list is empty because it has this "default" thing printed out. How do i change…
DanielWinser
  • 151
  • 1
  • 3
  • 8
0
votes
1 answer

How do I print it into an organised json file?

I need help with the output of my json file. I'm trying to print out the keys in a list called keypairs. I have to generate 60 keys, which i have included in the (count<60) part of my code (which isnt here). Im just showing the exporting part of my…
meh
  • 53
  • 1
  • 7
0
votes
0 answers

Unable to import tinyDB python

i'm currently facing an issue with importing the tinyDB python package into python. These are the steps I did to install tinyDB in raspbian. 1. Running the command: sudo pip3 install tinydb Output says: Requirement already satisfied (use --upgrade…
JasonSmith
  • 27
  • 1
  • 7
0
votes
0 answers

Retrieve image from TinyDB via a Python function

I know TinyDB can't store images but you can store the image file path. I have done that and I want to make my application display an image when a button is clicked. I have successfully added the file path to the database and I have tested the…
RedCode
  • 363
  • 1
  • 6
  • 23
0
votes
2 answers

sharedpreferences : Save to ListView

I have no problem to save list in sharedpreferences and show it in list view but my problem is when i restart the app and try to add items to listview old stored items removed . there is my code: public void SaveDatesToList(){ list.add(i+""); …
user2764693
  • 33
  • 1
  • 8
0
votes
1 answer

Call Function in if-Statement/ evoke call with print() - good practice?

Using tinydb i have an object for database operations like this: #database.py class DataBase(object): """CRUD access to database.""" def __init__(self): """Initialize database.""" self.db = TinyDB('/db.json') def…
Raggamuffin
  • 699
  • 1
  • 6
  • 19
0
votes
1 answer

TinyDB search an object imbedded in a list

How do I search an object imbedded in a list? The user needs to be able to search for a title's text. Here's the JSON: "titles": [ { "languageCode": "da", "text": "Odysseus" } ], Here's the code: from tinydb import TinyDB,…
0
votes
1 answer

App Inventor choose background color from list in TinyDB

I am trying to make an app using App Inventor. The app has more functions, but I am stuck at the I would say "basic" one. What I want to do is basically change the background color (or color of any element) by calling the color from list stored in…
Jorge
  • 27
  • 1
  • 8
0
votes
1 answer

TinyDB - SharedPreferences - getting: Forgot to register a type adapter?

I just discovered TinyDB which seems quite useful to handle object storage into the SharedPreferences. I'm almost there but I'm getting an error: Forgot to register a type adapter? Note that the GSON library from Google is used together with…
Isabelle
  • 1,457
  • 5
  • 19
  • 44
0
votes
1 answer

How to install tinydb in App directory

I am creating an app using python and kivy using from tinydb import TinyD, Query to import the tinydb module. This works completely fine when testing my python and kivy code. After using buildozer to create an apk and debugging, it is saying that it…
Azaro
  • 53
  • 1
  • 12
0
votes
2 answers

How to check if a tinyDB tag has any attributes in App Inventor

I need a little help with an issue in App Inventor 2. The case is that I have a JSON result that is parsed, and then have it stored in a tinyDB tag as a list (storeparseData). Problem is that, I have this function done as screen initiates, so to…
CodeBugging
  • 321
  • 12
  • 28