Forum: MySQL Nov 12th, 2009 |
| Replies: 3 Views: 539 SELECT
elec.sum(votes) as votes,
stat.sum(rating) as rating,
votes/rating as percentage
FROM elec, stat
WHERE YEAR=2009
Only thing I'm not sure about is the YEAR = 2009 in the... |
Forum: MySQL Nov 9th, 2009 |
| Replies: 4 Views: 460 No, use phpMyAdmin to export your database to an .sql file. It is a text file containing all queries to recreate your database. |
Forum: MySQL Nov 5th, 2009 |
| Replies: 2 Views: 420 Something like this:
select * from product where id not in (select product_id from discount) |
Forum: MySQL Oct 30th, 2009 |
| Replies: 1 Views: 436 $strSQL = "SELECT DISTINCT area FROM hospital where area like '%$strSearchVal' "; |
Forum: MySQL Oct 29th, 2009 |
| Replies: 2 Views: 531 You can insert a datefield as '1971-10-28'. The data you are trying to insert does not fit in the date column. |
Forum: MySQL Oct 13th, 2009 |
| Replies: 2 Views: 417 This will help:
http://dev.mysql.com/doc/refman/5.0/en/storage-requirements.html |
Forum: MySQL Oct 8th, 2009 |
| Replies: 9 Views: 471 |
Forum: MySQL Oct 8th, 2009 |
| Replies: 9 Views: 471 $sql="SELECT * FROM $tbl1_name WHERE sex='$show_all' AND age BETWEEN '$from' AND '$to'"; |
Forum: MySQL Sep 23rd, 2009 |
| Replies: 6 Views: 483 1. He could poll the database to see if there have been any changes.
2. He could write a specific page which you can trigger. |
Forum: MySQL Sep 17th, 2009 |
| Replies: 5 Views: 464 insert into table (mycolumn) values (encode('myvalue', 'mykey'))
select decode(mycolumn, 'mykey') from table |
Forum: MySQL Sep 16th, 2009 |
| Replies: 5 Views: 464 http://dev.mysql.com/doc/refman/5.1/en/encryption-functions.html |
Forum: MySQL Aug 27th, 2009 |
| Replies: 8 Views: 579 Hmm. The error points to typo's or too long identifiers.
http://www.dba-oracle.com/t_ora_00904_string_invalid_identifier.htm |
Forum: MySQL Aug 27th, 2009 |
| Replies: 8 Views: 579 EUIPMENT_FEATURES_MVIEW
shouldnt that be
EQUIPMENT_FEATURES_MVIEW |
Forum: MySQL Aug 27th, 2009 |
| Replies: 8 Views: 579 I think your group by and where are in the wrong order. |
Forum: MySQL Aug 26th, 2009 |
| Replies: 8 Views: 462 SELECT * FROM products,images WHERE products.id = images.product_id GROUP BY products.id |
Forum: MySQL Aug 25th, 2009 |
| Replies: 8 Views: 462 select * from products,images where products.id = images.product_id |
Forum: MySQL Aug 24th, 2009 |
| Replies: 5 Views: 521 Don't understand what you are trying to achieve. |
Forum: MySQL Aug 24th, 2009 |
| Replies: 5 Views: 521 select name,score from scores where name = 'jen140' |
Forum: MySQL Aug 17th, 2009 |
| Replies: 2 Views: 389 Yes, you can, but mysql won't accept the double quotes. If the id field is an integer, you can remove them. If it is a string field, use single quotes instead.
There may be an issue when the id... |
Forum: MySQL Jul 16th, 2009 |
| Replies: 2 Views: 284 If you are trying to update the same column to different values on different conditions, then you'll have to use two separate queries. |
Forum: MySQL Jul 16th, 2009 |
| Replies: 8 Views: 653 add
extension=php_mysql.dll
to the php.ini
http://www.bicubica.com/apache-php-mysql/index.php |
Forum: MySQL Jul 15th, 2009 |
| Replies: 8 Views: 653 mysql is not enabled. check your php.ini file.
http://nl.php.net/manual/en/mysql.installation.php |
Forum: MySQL Jul 2nd, 2009 |
| Replies: 8 Views: 782 Since you mention Joomla, it is possible that this is Joomla's way of storing e-mail addresses. You could use a regular expression to strip all unnecessary code, but there could be a lot of... |
Forum: MySQL Dec 4th, 2008 |
| Replies: 14 Views: 1,438 Have a look at this, it may get you started:
http://forums.mysql.com/read.php?52,48678,48684#msg-48684
http://dev.mysql.com/doc/refman/5.0/en/string-functions.html#function_find-in-set |
Forum: MySQL Nov 7th, 2008 |
| Replies: 2 Views: 1,055 Do you have a timestamp column ? Then sort descending and limit 10 on that column. |
Forum: MySQL Oct 16th, 2008 |
| Replies: 1 Views: 805 You could create a table that contains a users id and a headline's id. If the record is in there, he already voted. Both fields can function as a single unique primary key, so speed should not be an... |
Forum: MySQL Sep 25th, 2008 |
| Replies: 2 Views: 742 WHERE '%$searchstring%' = ID is rather tricky. If a user enters ID = 1 then every ID with a 1 in it is returned. 1, 10, 11, and so on. If you remove the % signs, it will search for an exact match. |
Forum: MySQL Aug 21st, 2008 |
| Replies: 2 Views: 1,925 It's all here: http://nl2.php.net/mysql_fetch_assoc
$sql = "SELECT DISTINCT year(date) AS 'year' FROM news ";
$result = mysql_query($sql);
while ($row = mysql_fetch_assoc($result)) {
echo... |
Forum: MySQL Aug 16th, 2008 |
| Replies: 10 Views: 1,193 Well, in my opinion hire/find someone who can show you what went wrong, so someone you can sit down with. |
Forum: MySQL Aug 15th, 2008 |
| Replies: 10 Views: 1,193 If you have for example CPanel access to your account, than you can enable remote mysql access from there. |
Forum: MySQL Aug 14th, 2008 |
| Replies: 10 Views: 1,193 phpmyadmin indeed has a config file where you can set user/password. it is supposed to be in the phpmyadmin folder. |
Forum: MySQL Aug 13th, 2008 |
| Replies: 10 Views: 1,193 In config files used by your php files somewhere the user and pass is defined. This depends on your software, can't tell you where it is.
SSH access depends on your provider. Some have it, some... |
Forum: MySQL Aug 12th, 2008 |
| Replies: 10 Views: 1,193 Is the SQL db the same, e.g. both mysql ? Can you use the same user, with the same password ? Is the PHP version the same, as of version 5, mysql extension is not automatically activated. Are you... |
Forum: MySQL Jun 12th, 2008 |
| Replies: 9 Views: 4,657 Your values are string, and therefor all need to be in separate quotes whithin the IN (...). I was expecting id's (integers) and then they are not needed. My apologies. |
Forum: MySQL Jun 10th, 2008 |
| Replies: 9 Views: 4,657 Can you tell me what's not working ?
If nothing is displayed, perhaps because you need to
<?php echo $newArray["BNF_Name"]; ?>
I don't know if your site is setup to use <?= as a short... |
Forum: MySQL Jun 10th, 2008 |
| Replies: 9 Views: 4,657 Do you want a single query where the values in your array are in the where ? Like this:
$values = implode(",", $your_array);
$query = "SELECT * FROM table WHERE column IN ($values)" |
Forum: MySQL Feb 15th, 2008 |
| Replies: 2 Views: 1,588 Try TOAD, it's free (toadsoft.com). Navicat is my tool of choice, but this one is commercial (navicat.com). |