Skip to content

Timeuuid to Timestamp support? #83

Description

@ptcarino

Framework: Laravel 5.2
Cassandra version: 3.9

I managed to use the timeuuid function toTimestamp(now()) on my insert statements but when I used it on a select statement I got this error:

Invalid: Invalid call to function totimestamp, none of its type signatures match (known type signatures: system.totimestamp : (date) -> timestamp, system.totimestamp : (timeuuid) -> timestamp)

The select statement I've used is as follows:
SELECT room_id, username, mac, message, toTimestamp(created_at), ts_created FROM chat

and for the insert statement that worked for me:
INSERT INTO chat (room_id, username, mac, message, created_at, ts_created) VALUES (bbbcb63c-027e-427b-a6e5-b575a79de797, '$name', '$mac', '$msg', now(), toTimestamp(now()))

EDIT:
I'm trying to return the result of the querySync in my situation on this issue.

$response = $connection->querySync($statement);
$result = $response->fetchAll();

return $result;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions