Subscribe

Countries

  1. 2010-04-16 00:05:31 PDT
    Different countries have different types of food, even different i big chains Mc Donalds. So i wonder if it's possible to add different databases for different countries? This will also make it better with translations. I have a Norwegian list here (Navn=name, Fett=fat, Karbo=carbo) List
  2. 2010-04-27 08:40:57 PDT
    Hi Sjano, I commented on your feature request, but I'll add it here to. Yes it is possible to do it. Our initial source is an SQL database from which we generate a serialized tree for speed and size purposes. That being said there is no easy import mechanism at the moment. In our food database we have much more detail than what we show (fat,prot,carb and cal). We have the data for vitamins, sub carbs (like fiber, sugars), sub fats (mono, poly, saturated etc), sodium, cholesterol etc., and we are planning to add all that info to the screen. So if we decide to add more data for different countries we will have to work a bit on the logic for missing data. I will take a look if we can add a user side import so that anyone can give a csv or xml file of nutrients and create their own category in the food database. Best, Georgi T.
  3. nobody

    2010-08-18 03:48:19 PDT
    I would like to parse some web about food from my country (CZ) and add it to database, I looked into .jar archive and there is food.db and it is serialized... is it possible to deserialize and add some things? Or the import feature is on the way? Petr Thank you!
  4. 2010-08-18 10:01:22 PDT
    Hi, Yes, the database is serialized for speed and size. We have a separate project in the source code that just generates the food db: http://idiet.svn.sourceforge.net/viewvc/idiet/iDiet%20Database/ Since the USDA provides their information in a DB, we just load it with sql in our tree object and serialize it out. Currently this is the only way to modify the main food.db. In the webstart version of idiet, the import/export feature is implemented. If you don't use the WS version just update to this jar: http://idiet.sourceforge.net/ws/iDiet.jar The features allow you to export/import custom meals. Unfortunately that will not be very useful if you have a big source that you want to add in bulk. For that we'll have to work out a custom import just for your source. Hope that gives you some idea of how the DB is handled. Let me know if I can help with anything more. Georgi T.
  5. nobody

    2010-08-18 11:36:36 PDT
    Ok man, I am not very familiar with Java, but I found in your sourcodes this: CREATE TEXT TABLE food_desc (NDB_No INTEGER PRIMARY KEY, FdGrp_Cd INTEGER, Long_Desc VARCHAR(200)," + "Shrt_Desc VARCHAR(60), ComName VARCHAR(100) DEFAULT NULL, ManufacName VARCHAR(65) DEFAULT NULL," + "Survey CHAR(1) DEFAULT NULL, Ref_desc VARCHAR(135) DEFAULT NULL, Refuse DECIMAL DEFAULT NULL," + "SciName VARCHAR(65) DEFAULT NULL, N_Factor DECIMAL DEFAULT NULL, Pro_Factor DECIMAL DEFAULT NULL," + "Fat_Factor DECIMAL DEFAULT NULL, CHO_Factor DECIMAL DEFAULT NULL)" > For that we'll have to work out a custom import just for your source. I am able to transform the source to any format you need I hope, so for both of us the SQL would be the best? So could you send me the sql file with the USDA sources and I will add here food from "my" sources? Or any other way, I just do not want you add you work... I downloaded the new version, there is import function, but what is the format of the importing file? Thank you! Petr
  6. 2010-10-08 13:46:28 PDT
    Petr, The USDA sources are here: http://www.ars.usda.gov/Services/docs.htm?docid=8964 . I get the ASCII CSV files, load them in a HSQLDB text DB and then extract the info from there. Georgi T.
Jump To:
< Previous | 1 | Next >

Add a Reply

This forum does not allow anonymous participation.

Log in to add a reply. Not registered? Create an account to participate and receive email updates when replies are posted to this topic.