Skip to content

Difficulty storing nested date fields like ISODate in MongoDB using Laravel #2807

Closed Answered by ednermoya
ednermoya asked this question in Q&A
Discussion options

You must be logged in to vote

I solved the problem as follows:

//Esta inserção é realizada diretamente no MongoDB
        $getUpdateDocumento = MongodbValoresSensoresColetados::Where("_id", $documento->_id)
                                                        ->Where('sensores.sensorId', $sensorRecebido->sensores_id)
                                                        ->update([
                                                            '$set' => [
                                                                'utilizado' => 1,
                                                            ],
                                                            '$addToSet' => [
                                            …

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by ednermoya
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants