HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Search
-
Re: SQL fetching advice needed.
Another perhaps silly question I have 20 items that need to be found either item1 or item2 or item3 or item4 or ..... or item20. these items are all a value in one column of the database. e.g. col 2 is identified as a primary key A ) is it better to do a prepare on select * from mytable where col2 = $itemnumber loop… -
Re: SQL fetching advice needed.
-
Re: SQL fetching advice needed.
why? seems like a straightforward question with all relevant info expressed. perhaps the question is more of one of resource usage and memory base on the result of sql selection. I have one table (just one table with 20 columns). I am not asking how to break up table or index or any table optimization. I am going to make a… -
Re: SQL fetching advice needed.
Thank you @businessdad summing up. so even 20 ors make not much difference thanks. a join it is then based on my data data might not be in table 1 or table2 (but this rare). I understand how to write queries syntactically - but I don't understand performance issues or optimization of queries, thanks for the article - will… -
Re: SQL fetching advice needed.
The way i do is, i always off load the processing to DB, incase there will be a perfomance hit, I troubleshoot the query (especially if there are a lot of joins), then if can't be fine tuned, i use the application level which is what you mentioned loop "through the 20 $itemnumbers" for your second question, case to case… -
SQL fetching advice needed.
If anyone can lend some advice. I've got a database table with about 10,000 records. with 20 columns (2 columns are 40 characters in length and the other 18 columns are 5 characters in length). A user will select based on criteria that may result in 5 and Wheres the results could return a count of potentially 1000 records… -
Re: SQL fetching advice needed.
thank you hbf ok thats a good answer. which leads to another off-topic question is there any kind of tool in php that examines resource usage or profiles. I can certainly put timing in, but I was wondering, if there is something that shows, memory used by an object or any array or memory left. I haven't researched any…
7 results