|
More site info...
|
|
Forum profile page for Database on http://www.phpbuilder.com.
This report page is the aggregated overview from a single forum: Database, located on the Message Board at http://www.phpbuilder.com.
This forum profile page summarizes the general forum statistics such as: Users Activity, Forum Activity, and Top Authors, which are reported in either a table or graph below for a given reporting time period.
Additional forum profile information for "Database" on the Message Board at http://www.phpbuilder.com is also shown in the following ways:
1) Latest Active Threads
2) Hot Threads for Last Week
Warning: These statistics are generated using 'best efforts' and can experience delays and reporting errors at times. Please note that such statistics do not constitute a forum's popularity and/or exact posting volumes at any given reporting period.
|
|
|
|
|
Posting activity on Database:
|
|
Week
|
Month
|
3 Months
|
|
Threads:
|
38
|
180
|
526
|
|
Post:
|
83
|
503
|
1,387
|
|
|
Database Posting activity graph:
|
Top authors during last week:
user's latest post:
generate row number dynamically...
Published (2009-11-07 01:34:00)
Whatever happened to the edit button? Can't even correct my spelling any more I realise that I did not answer your question fully sneakyimp. The COUNT has to be run of course, but it is the GROUP BY that create the overhead in a query like this and that is quite normal no matter what method one uses.
user's latest post:
Selecting most recent row....
Published (2009-11-03 15:07:00)
Quote: Originally Posted by Roger Ramjet But not MySQL. sonny100 did not state what database system was used, so MySQL is just an assumption, although it is probably the best assumption to make when you have no other information Checking the MySQL documentation, can anyone confirm that AUTO_INCREMENT for MySQL does not allow reuse of ids even for deleted rows? The part about "this happens even for MyISAM tables, for which...
user's latest post:
odbc sql php pagination query
Published (2009-11-05 19:02:00)
It is not clear on my part when I get partial code back from you to put it in the correct place. It might be helpful if the entire code with updates was returned. I am having trouble putting it all together when it is returned. The code below has error: Undefined index: submit on line 21. Thank you in advance for your help. PHP Code: <?php $db = odbc_connect ( '' , '' , '' ); //put your...
user's latest post:
Comparing an Array against a DB
Published (2009-11-08 22:10:00)
Your foreach line has the potential to break something: $tag and $tag is being used to mean two different things at the same time. PHP Code: foreach( $tag as $key => $value ) { $tag [ $key ] = "'" . mysql_real_escape_string ( $value ). "'" ; } $query = "Select tag_name from tags where tag_name in (" . join ( ',' , $tags )....
user's latest post:
Creating Table from input
Published (2009-10-30 02:18:00)
Obviously not, or it would work. It should work with rincewind's suggested changes. What does your code look like now?
user's latest post:
[RESOLVED] SQL syntax error
Published (2009-10-30 14:36:00)
And i figured it out...i had to change to call the $shout in two other places.
user's latest post:
[RESOLVED] Can Someone Explain...
Published (2009-11-03 16:49:00)
Answering my own question. Great post! codinghorror.com/blog/archives/000976.html Hot diggity that Google is slicker than whale snot in an ice flow!
user's latest post:
difference on two queries which...
Published (2009-11-03 12:32:00)
sql 1 PHP Code: $SQL == "select table1.* , table2.* from table1 left join table2 on (table2.id = table1.foreignkey) where table1.idsofmulitiple = whateveralue and table2.fieldsofidentity = whateveralue " ; vs sql2 PHP Code: $SQL == "select table1.* , table2.* from table1 left join table2 on...
user's latest post:
InnoDB, foreign keys, cascade...
Published (2009-10-30 11:01:00)
I'm not sure if I can do this with relations and CASADE functions etc. So for now I'm calling an extra query to DELETE orphan tags; Code: DELETE t.* FROM tags AS t LEFT JOIN tags2img AS t2i ON t.tID = t2i.tID WHERE t2i.tID IS NULL "; Is there a better way to do this?
user's latest post:
[RESOLVED] Joining 3 Tables...
Published (2009-10-31 09:39:00)
tomhath, I tried the NOT EXISTS. I can see why this is a faster way of doing it, but it's simply not giving me the results that I'm looking for. I'm looking to pinpoint which 'rid' values are in the clearance table. When I do a NOT EXISTS, it's basically kicking out a TRUE value if any value exists in the query and giving me an 'all or nothing'. Perhaps it's the way I have the rest of the query...
|
|
|
|
Latest active threads on Database::
Started 1 day, 23 hours ago (2009-11-08 22:10:00)
by Weedpacket
Your foreach line has the potential to break something: $tag and $tag is being used to mean two different things at the same time.
PHP Code:
foreach( $tag as $key => $value ) { $tag [ $key ] = "'" . mysql_real_escape_string ( $value ). "'" ; } $query = "Select tag_name from tags where tag_name in (" . join ( ',' , $tags ). ")"...
Started 2 days, 18 hours ago (2009-11-08 03:53:00)
by Weedpacket
Have a look at the link provided in this FAQ post .
Started 1 week ago (2009-11-03 14:48:00)
by Roger Ramjet
Well if you are using crap MickeySoft databases like Access/JET then you can not paginate this way because they only have TOP n with no chance of an offset.
What you will have to do is to keep track of the first and last PRIMARY KEY on each page displayed. Then your query would be
PHP Code:
// next 5
SELECT TOP 5 * FROM table WHERE id > $lastid ...
Started 6 days, 7 hours ago (2009-11-04 14:50:00)
by dagon
SELECT @row :=0;# Rows: 1
SELECT @row := @row +1 AS rowNumber, t1.foo, t2.bar FROM table1 t1, table2 t2
Started 4 days, 5 hours ago (2009-11-06 16:19:00)
by Lars Berg
Code:
select `start`,
`end`
from t
where $number between `start`and `end`
Started 4 days, 15 hours ago (2009-11-06 06:29:00)
by Lars Berg
Code:
select bmsaid,
sum(islead),
sum(lead)
from leads
where bmsaid = $myid
or bmsaid in
(select bmsaid
from users
where parent = $myid)
group by bmsaid
Started 4 days, 21 hours ago (2009-11-06 00:24:00)
by Weedpacket
What are the errors that you get?
Started 5 days, 13 hours ago (2009-11-05 09:01:00)
by Roger Ramjet
Probably because your form data is being sent from any browser on any operating system, probably IE on winders. What you need is to set the form data to utf8 as well
|
|
Hot threads for last week on Database::
Started 1 week ago (2009-11-03 14:48:00)
by Roger Ramjet
Well if you are using crap MickeySoft databases like Access/JET then you can not paginate this way because they only have TOP n with no chance of an offset.
What you will have to do is to keep track of the first and last PRIMARY KEY on each page displayed. Then your query would be
PHP Code:
// next 5
SELECT TOP 5 * FROM table WHERE id > $lastid ...
Started 6 days, 7 hours ago (2009-11-04 14:50:00)
by dagon
SELECT @row :=0;# Rows: 1
SELECT @row := @row +1 AS rowNumber, t1.foo, t2.bar FROM table1 t1, table2 t2
Started 1 week, 6 days ago (2009-10-28 04:51:00)
by sonny100
Been having more of a dig around, could this work?
PHP Code:
SELECT * FROM ( SELECT string , MAX ( time ) as maxtime FROM message GROUP BY string ) WHERE userid = $username
Started 5 days, 13 hours ago (2009-11-05 09:01:00)
by Roger Ramjet
Probably because your form data is being sent from any browser on any operating system, probably IE on winders. What you need is to set the form data to utf8 as well
Started 4 days, 21 hours ago (2009-11-06 00:24:00)
by Weedpacket
What are the errors that you get?
Started 1 day, 23 hours ago (2009-11-08 22:10:00)
by Weedpacket
Your foreach line has the potential to break something: $tag and $tag is being used to mean two different things at the same time.
PHP Code:
foreach( $tag as $key => $value ) { $tag [ $key ] = "'" . mysql_real_escape_string ( $value ). "'" ; } $query = "Select tag_name from tags where tag_name in (" . join ( ',' , $tags ). ")"...
Started 2 days, 18 hours ago (2009-11-08 03:53:00)
by Weedpacket
Have a look at the link provided in this FAQ post .
Started 2 years, 7 months ago (2007-04-06 08:56:00)
by bogu
http://mobile.de/
now = at the present moment; "goods now on sale";
know = be cognizant or aware of a fact or a specific piece of information; possess knowledge or information about; "I know that the President lied to the people";
Started 1 week, 2 days ago (2009-11-01 17:20:00)
by jdelagoutte
pdo but no pdo installed...
Hi Guys,
I'm trying to use the Matrix MySource CMS ( http://matrix.squiz.net/ ) on a shared hosting environment;
This CMS is open source, and is relying on PDO to access a pgsql database.
But, pdo_pgsql is not installed on my hosting environment, and I can't have it installed.
Does any one now ...
Started 5 days, 13 hours ago (2009-11-05 08:44:00)
by Roger Ramjet
If you don't want a page reload then use AJAX (search for it).
If you don't want to use AJAX then you are going to have to store the value and use it to dynamically generate the form with the item set to selected=selected.
|
|