-1
我使用find()函數在MongoDB中並在下面的格式獲取最後一行MongoDB中
Array
(
[_id] => MongoId Object
(
[$id] => 52a561ea78e9288b568b4567
)
[friendID] => 1
[name] => Shobhit Srivastav
[senderID] => 2
[receiverID] => 1386570218
[receiverType] => TW
[receiverUserID] => 3
[status] => 0
)
Array
(
[_id] => MongoId Object
(
[$id] => 52a5623178e928d8568b4567
)
[friendID] => 2
[name] => Sachin Tendulkar
[senderID] => 2
[receiverID] => 1386570289
[receiverType] => TW
[receiverUserID] => 3
[status] => 0
)
得到了一個紀錄,但我想這是在表中插入最後一行的記錄。我怎麼找到?
在此先感謝!
顯示正常mondodb輸出,而不是你的php的print_r的 –