Hi,
I've been developing an application on my desktop that uses MySQL. However, I travel to and from different locations all the time and I'd like to develop on my laptop.
Is there a way I can continue to develop without leaving on my desktop turned on and connecting in remotely?
...
Hi to all,
Actually I was confused to give the title for this question. I have condition like this.
When we get record from database using limit like select * from table_name limit 0,5 we get the data from 0 to 5 and when we use limit 5,10 we get 10 records from 5... Is it possible to display that particular index of the record...
My sys admin has me working on a server with Plesk, which requires me to have a unique username/password for each MySQL database I create. This is very annoying, does anyone know how to create a universal username login?
...
Hi Guys,
Lemme explain the scenario:
I need to fetch all the Metadata of Files, i.e., Title, author, subject.. and Custom Attributes.( Custom attributes are not fixed, they are not fixed and can be of any numbers).
Now to Store this Struvture I have Designed a DB like :
MainTable:
FileID, FileName, Title, Author, Subject
and To Store C...
To search the database for rows that have both keywords "foo" AND "bar" in any of the columns "foo_desc" and "bar_desc", I would do something like:
SELECT * FROM t1 WHERE MATCH (t1.foo_desc, t2.bar_desc) AGAINST ('+foo* +bar*' IN BOOLEAN MODE)
or
SELECT * FROM t1 WHERE (CONCAT(t1.foo_desc, t2.bar_desc) LIKE '%foo%') AND (CONCAT(t1.foo...
According to the documentation, joins, when used with the update statement, work in the same way as when used in selects.
For example, if we have these two tables:
mysql> SELECT * FROM orders;
+---------+------------+
| orderid | customerid |
+---------+------------+
| 1 | 1 |
| 2 | 2 |
| 3 | ...
Hello;
This is the scenario:
I have a MySQL server with a database, let's call it consolidateddb. This database a consolidation of several tables from various databases
I have another MySQL server, with the original databases, these databases are production databases and are updates daily.
The company wants to copy each update/insert/...
Hi,
After performing EXPLAIN on a query:
explain
select name from t1 where name like '%smthing%'
UNION ALL
select name from t2 where name like '%smthing%'
UNION ALL
select name from t3 where name like '%smthing%'
UNION ALL
select name from t4 where name like '%smthing%'
composed by the UNION of 4 tables I get this:
id select_type...
Inside MySQL I have written a Procedure where I want to run a loop like this:
While (Cond) Do
...(Body1)
...
If (Condition2)
continue ;
...(Body2)
...
end while ;
Under the while loop I want the full body to run in case where Condition2 is not met (ie Body1 and Body2).
Currently, when Condition 2 is met, it just execut...
I'm having trouble finding a better way to search MySQL for a pair of values in a table. I have the value pairs in an array, and would like to duplicate the IN() function, but for more than 1 value.
For example purposed; I have the following 3 pairs:
foo,1
boo,2
goo,3
The current solution puts me at:
SELECT * FROM [table] WHERE
(co...
Hi, I'm new to PHP/MySQL and super-new to CodeIgniter..
I have information in many MySQL tables. I want to retrieve it with JOIN where the tables primary keys are equal to $variable... How can I do it and get all the fields without the primary key field???
What I'm doing now is this (only two tables joined here):
function getAll($id) {...
This is almost similar question to this one: -
http://stackoverflow.com/questions/346770/dealing-with-timezones-in-php
I read that thread, and have some more issues, and not sure of how to elegantly build timezone support in PHP/MySQL application.
I am writing an application in PHP, where users can select their timezone.
Here, all ti...
Given my two db tables aliases and subscriber have entries like this:
aliases.username = '5551234567'
aliases.contact = 'sip:[email protected]'
subscriber.username = 'a_sip_username'
I'd like to select only the matching rows that have subscriber.username within the aliases.contact field. This was my first attem...
Does this cause a race condition with MySQL (InnoDB):
Start Transaction.
Try to get record.
If record doesn't exist, return.
If record exists, delete it and add a log entry saying that is was deleted.
End Transaction (commit/rollback).
Is it possible for another process to start just before the delete step in 2b, detect the presence ...
I get the error when trying to run this:
<?php
require_once('includes/DbConnector.php');
$connector = new DbConnector();
$result = $connector->query('SELECT title,content FROM staff_vacancies ORDER BY ordering LIMIT 0,100');
// Get an array containing the results.
// Loop for each item in that array
while ($row = $connector->fetchArray(...
hi...
i want to get the data of five table having a common id from one query can we do this ,
for example tbl_student,tbl_batch,tbl_section,tbl_level,tbl_faculty all have a common id
college_id
how can i get all the tables value with one query
if anybody can help me i would be greatful
...
I am working on search functionality in my website. I want to provide a best search mechanism to users. I am using PHP/MYSQL.
Let's say user searched for "sport".
I have 30 records having word "sport" and 5 records having word "sports" but when I am searching for sport then following query only returns the result 30 who have the word ...
HI,
I have written a program in Perl using the DBI module. Can I display the output of MySQL using CGI? If so please help me.
program:
#!/usr/bin/perl -w
use DBI;
print "Content-type:text/html\n\n";
$db_handle = DBI->connect("dbi:mysql:database=CYP1B1;host=localhost:192.168.3.93;")
or die "Couldn't connect to database: $DBI::e...
I am trying to set the permissions for a MySQL user using the following command.
GRANT ALL ON joomla.* to user@localhost;
I have tried so many versions but they all return:
ERROR 1044 (42000): Access denied for user ''@'localhost' to database 'joomla2'
Which seems to indicate that the username "user" is not getting passed? I have trie...
I want to reset stop word list in mysql for FULLTEXT search. I have installed WAMP Server in my system which have phpmyadmin to access mysql. But I dont know how to reset stop word in phpmyadmin. Can anyone please tell me how to do that.
I also http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html#sysvar_ft_stopword_file r...