All Questions
8 questions
0
votes
2
answers
119
views
Filter one record in table with Request ID
I have tabel request_process as follows:
requestID Status
1 0
1 1
1 2
2 0
2 1
I want to get one row per request with maximum status but only ...
0
votes
1
answer
245
views
Get Array values from Recursive function using php
I am trying to find out the parents of a new member till root. For this, I have written a recursive function in PHP that is expected to work, but results are not as expected.
$parlist=array();
...
0
votes
0
answers
169
views
Deep Search with relationships eloquent models
I'm trying to build a dynamic search by searching a model and specific columns in it's relationships and nested relationship. So far this is the code i've come up with
The class I created has a ...
0
votes
1
answer
644
views
Find all middle categories from nth child to top level in PHP recursion
I have category table:
Category table:
cat_id cat_pid cat_name
1 0 Women's Fashion
2 1 Women Accessories
3 2 Wallets & ...
0
votes
2
answers
4k
views
Get all children of a nested tree recursively
Thanks everyone
I have a JSON nested tree that I want to retrieve only ids.
This is the result of my query.
My goal is to call a recusrive function and give it the parent id and it will return all ...
0
votes
2
answers
830
views
recursive menu causing fatal error: Allowed memory size exhausted
I'm not sure what's happening here, I tested this code on localhost but now that I’ve tried going live I’m getting this error message:
Fatal error: Allowed memory size of 67108864 bytes exhausted (...
2
votes
1
answer
101
views
What's the most elegant way to do this recursive many-to-many database lookup?
I have a MySQL table which contains many-to-many data about users:
username (PK) ip (PK) machine_id (PK)
--------------------------------------------------
tester1 1.2.3.4 ...
1
vote
1
answer
6k
views
Recursive php mysql query/function for tree of categories
I have an oscommerce set up and have decided to add a "most popular" product in each category. I need to query all child categories so that I can then query for the most popular product in the list ...