Ad Widget

Collapse

Query tabela history

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • brenoacp
    Junior Member
    • Jun 2016
    • 26

    #1

    Query tabela history

    Boa tarde a todos,
    pessoal, estou tentando fazer uma consulta na tabela history mais sem sucesso, não retorna valor nenhum.
    Já alterei a forma de passar a data e nada.
    Segue a consulta:

    SELECT itemid,
    from_unixtime(clock,'%d/%m/%Y') AS date_data,
    from_unixtime(clock,'%H:%i:%s') AS Time_data,
    VALUE
    FROM history
    WHERE clock >= FROM_UNIXTIME('01/02/2016') AND clock < FROM_UNIXTIME('01/01/2017')
    and itemid = 24661

    Onde poderia estar errando?

    Grato,
    Breno Padovan
Working...