i need to connect mysql server from other new server, the IP address of the new server is in UK. please reply me is there any possibility to connect the new one?
I'm running program at apache tomcat server, that should be on permanently, but every morning(the client part isn't accessible at night) i receive error message (in apache tomcat console) that MySQL server is off. So is there any way to prevent this?
Thanks in advance!
i want to create a table :
products
which looks like
(these are columns name)
Id Name Category-id Description
now Category-id column gets the values from another table
category
which looks like
Id Name Description
now category.Id is used in products.Category-id
how to do this in mySQL
Hi,
I'm trying to make a Tag cloud for every user in own page, I'm using PHP5 and Mysql, My table named "tags" and I want to make a array but in short way. The table like below,
The array can be like
for user1 array={[car,1],[cat,null],[pen,1],[dvd,1],[cd,null]}
Username totaltag tag1 tag2 tag3 tag4 tag5
admin 5 car cat pen dvd cd
user1 1 1 1
user2 1 2 12 1
user3 3 2 10 1
How to connect to MYSQL DB from Java, create table, insert data, retrieve it with datatypes.
How to make use of the data to/from in Flex application.
plz help me out..
i have basic knowledge in sending and receiving messages using BlazeDS.
and calling JAVA METHODS USING ...
I am torn between postgreSQL and MySQL but I am forced to install the choosen one on windows. I especially need asp.net membership and i will be installing NHibernate as well.
I have a mysql query where a subquery is:
BETWEEN '5.00' AND '10.00'
And this returns no results.
However when I use Floats or Ints:
BETWEEN 5 and 10
it works
The BETWEEN query also works for other values AS strings, but just not for 5 and 10.
EG:
BETWEEN '4' AND '5'
works.
How could this be?
My current process for debugging stored procedures is very simple. I create a table called "debug" where I insert variable values from the stored procedure as it runs. This allows me to see the value of any variable at a given point in the script, but is this is there a better way to debug MySQL stored procedures?
I'm working with python and mysql and I want to verify that a certain entry is compressed in the db. Ie:
cur = db.getCursor()
cur.execute('''select compressed_column from table where id=12345''')
res = cur.fetchall()
at this point I would like to verify that the entry is compressed (ie in order to work with the data you would have to use select uncompress(compressed_column)..). Ideas?
I am building a PHP and MySQL search as so
SELECT * FROM Properties WHERE Locaion = 'Liverpool'
I want to count how many of each property type there are and display them at the side of the page to use as filters (like Rightmove.co.uk).
This is what I am have come up with but can't get it to work
SELECT *,
count(PropertyType = 'house') AS HouesTotal,
count(PropertyType = 'Apartment') AS ApartmentTotal
FROM Properties WHERE Location = 'Liverpool'
Can anyone help?
Is it possible to assign php array in MySQL IN() function? for example,
$numbers = array('8001254656','8886953265','88864357445','80021536245');
$sql = mysql_query("SELECT * FROM `number_table` WHERE `number` IN ($numbers)");
Any Ideas?
Thanks,
So,
I can run the following statements from within mysql itself successfully.
SET @fname = 'point1';
SELECT * FROM country WHERE name=@fname;`
But when I try to pass the query through php like this and run it, I get an error on the second line
$query = "SET @fname = 'point1';";
$query .= "SELECT * FROM country WHERE name=@fname;";
When i run a mysql select statement, it takes very long because i have already previously deleted a very large number of rows.
Is there a way for the table to start scanning from the bottom, as opposed to from the top?
I have this mysql table called comments which looks like this:
commentID parentID type userID date comment
The commentID is set as Primary key, but most of the time I fetch the data using the parentID. How should I set my indexes?
Should I just add an index on parentID and let commentID be the primary key?
All,
I have a database table in mysql with a field that is of "TIMESTAMP" type. I need help writing the SQL query to update the field with the current timestamp.
UPDATE tb_Test set dt_modified = ?????
Thanks,
I had the below query working in mysql 4.1, but does not in 5.0:
SELECT * FROM email e, event_email ee
LEFT JOIN member m on m.email=e.email
WHERE ee.email_id = e.email_id
The error:
1054 (Unknown column 'e.email' in 'on clause')
I have "tasks" table with 3 fields:
date
priority (0,1,2)
done (0,1)
What I am trying to achieve is with the whole table sorted by done flag, tasks that are not done should be sorted by priority, while tasks that are done should be sorted by date:
Select * from tasks order by done asc
If done=0 additionally order by priority desc
If done=1 additionally order by date desc
Is it possible to do this in MySQL without unions?
Thanks.
In one of my forms I use the rich text editor from Yahoo!.
Now i want to store the data from that textarea in a MySQL database.
The user can enter anything in that textarea, e.g. many double or single quotes.
How can I store that data?
Normally we store by adding that data in one variable and then put that in sql, but the quotes cause problems.
This is the best way I could come up with to convert a MySQL GUID/UUID generated by UUID() to a binary(16):
UNHEX(REPLACE(UUID(),'-',''))
And then storing it in a BINARY(16)
Are there any implications of doing it this way that I should know of?
Is there an easy way (without downloading any plugins) to connect to a MySQL database in Python?
Also, what would be the difference from calling a PHP script to retrieve the data from the database and hand it over to Python and importing one of these third-parties plugins that requires some additional software in the server.
is there a way to have a mysql select statement return fully qualified column names like "table.field" without using AS for every single field?
like so:
SELECT *
FROM table1
LEFT JOIN table2 on table1.f_ID = table2.ID
and the result would be:
"table1.ID", "table1.name", "table2.ID", "table2.name", ...