Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0 votes
0 answers
184 views

MAMP PRO 6.9, PHP 8.2.0, Mac 14.21 and Mongo DB - Apache Fails

Have been trying to get MongoDB installed on MAMP PRO 6.9, PHP 8.2.0, Mac 14.21 via PECL but after a successful install and enabling the extension, when restarting MAMP Pro, Apache fails and none of ...
Nigel McLaughlin's user avatar
1 vote
0 answers
369 views

MongoDB / PHP - How to change data type for every occurrence of field in a document

I'm trying to learn how to use MongoDB with PHP. I Have built a web application that loads data from database etc. The issue I am having is that when I import my data from a .CSV using MongoDB Compass,...
rodgersteez's user avatar
0 votes
1 answer
1k views

Mongodb find() not working as expected, PHP [closed]

Mongodb find() seems Not to work, I have tried all I could and nothing works so far. using PHP7+ I have a Document in the strure like the image below In SQL I could do something like:SELECT....... ...
ErickBest's user avatar
  • 113
0 votes
1 answer
354 views

Tracking MongoDB execution times using PHP

I am currently working on a project using PHP, I have done research and found that microtime() helps with tracking the time of a query in a MySQL database.. how do I do the same for MongoDB, I have ...
Robert's user avatar
  • 1
3 votes
1 answer
11k views

MongoDb max timeout for all queries

I am using MongoDb/PHP on a Linux server. The problem is that, if a query takes too long to execute, the mongo server stop (apache keeps running). So is there any way ,so that I can limit the time for ...
Mohammad Qasim's user avatar
0 votes
1 answer
22 views

Are my MongoDB servers right in setting?

I have a small web site, so I used two servers. A: master 4G Ram, 96G SSD B: slave 2G RAM, 96G SSD The B server is always for backup, no read, no write. In my application, many users can (and will) ...
newbie's user avatar
  • 1
3 votes
2 answers
7k views

MongoDB/MySQL - auto increment vs object ID

I am in the process of evaluating MongoDB and writing some basic PHP applications around it. Typically in my PHP/MySQL applications, I would create an ID field and set it to auto-increment on each row ...
Darius's user avatar
  • 273
2 votes
1 answer
2k views

MongoDB performance problem

I have a MongoDB for storing result like this {_id, type, imei, lat, lng, spd, dir, time} {_id, type, imei, lac, cid, time} If type is f first one is used and if it is l second one is used. Here is ...
vfsoraki's user avatar
  • 167
0 votes
2 answers
2k views

1 million strings and exact match search

I need to chose the best solution (software and algorithm) to solve my problem. I need to store up to million strings and data associated with them. Strings are search queries and data is cached ...
yefrem's user avatar
  • 123
1 vote
1 answer
2k views

PHP/MongoDB: Unset all fields in a document

I want to use PHP to remove documents from a MongoDB collection, but it's a capped collection (and it's stuck that way until I can get more memory), which means I can't remove documents. I have to do ...
Qaz's user avatar
  • 213
2 votes
0 answers
165 views

mysql vs mongodb cache/load balancing

I have a system where users can 'like' content. There will likely be many hundreds of these likes going on at once. I'd like it to be AJAX driven so you get an immediate response. At the moment I ...
Tim's user avatar
  • 21
0 votes
1 answer
1k views

MongoDB shell version error (Server has startup warnings)

I installed MongoDB under Ubuntu server and when inter to MongoDB shell i got this error and warnings. MongoDB shell version: 2.4.7 connecting to: test Server has startup warnings: Sun Oct 27 09:58:...
Osama Jetawe's user avatar
0 votes
1 answer
135 views

Is Index Used for This Query

If so, which one? How do we know? I have 3 indexes in a query. Actually only the first 2 should be useful { "v": NumberInt(1), "key": { "LongitudeLatitude": "2d", "Prominent"▼: ...
user4951's user avatar
  • 1,355
3 votes
1 answer
3k views

Mongo connection failing with 'Transport endpoint is not connected'

I have a 2 server installation. A web server with Apache and a DB server with MongoDB. I am load testing it, and on ~300 RPS I am getting this error: PHP Fatal error: Uncaught exception '...
Alex Frenkel's user avatar