GDL object + SQL

Home Forums Problems and solutions in GDL Others GDL object + SQL

Viewing 3 reply threads
  • Author
    Posts
    • #3528
      Matthias Weinlich
      Participant

      HI
      I want to use SQL to export a list of data without having to make a spreadsheet every time.
      I asked for “SELECT LIBRARY_PART_NAME, parameters FROM objects” ->works fine, but as soon as i want to look for just one parameter f.e. “NAME”
      “SELECT P.Library_part_name , OP.name FROM Objects P, objects.parameters OP”
      I get an error: unexpected token

      Can you help me with the right syntax?

      AC 20, Win 7, mac

    • #3540
      Matthias Weinlich
      Participant

      OK got it myself 😀

      SELECT OP.PARAMETERS.NAME, OP.PARAMETERS.VARIABLE_NAME, OP.PARAMETERS.TYPE, OP.PARAMETERS.VALUE FROM FLAT (OBJECTS, PARAMETERS) AS OP WHERE LIBRARY_PART_NAME=’Arbeitsplatz 001′

      AC 20, Win 7, mac

    • #3542
      Matthias Weinlich
      Participant

      grrr. does anyone has a documentation of usable SQL in Archicad? I tried to use Count and group.
      ” SELECT LIBRARY_PART_NAME, OP.PARAMETERS.NAME, COUNT (OP.PARAMETERS.VALUE) FROM FLAT (OBJECTS, PARAMETERS) AS OP
      WHERE LIBRARY_PART_NAME=’Arbeitsplatz 001′ AND OP.PARAMETERS.NAME =’MA 52′
      GROUP BY OP.PARAMETERS.NAME ”

      But it doesn’t work. Error ” the function COUNT is not defined ” OR ” unexpected token: GROUP ” Pleas help! I just want to have this short way to count different objects when I’m asked without the need of spreadsheets all the time!

      OR:
      Is there a way to export all generated data and put them into a database where I can use proper SQL? Maybe directly AC -> Database without an csv. in between….

      AC 20, Win 7, mac

    • #3550
      Joachim Sühlo
      Participant

      I have a document named “Graphisoft SQL Language Reference”, which I could send to you.

      GDL Object Developer
      b-prisma
      MAC OSx 10.14

Viewing 3 reply threads
  • The forum ‘Others’ is closed to new topics and replies.