- Original Message -
> From: "Sergei Petrunia"
>
> Create index on (importance, company_id) (or
> (company_id,importance), should
> not matter). When that index is present, the query should use ref
> access on it using both key parts (if by some crazy reason it doesn't, use
> FORCE
> IN
On Wed, Oct 19, 2011 at 05:09:13PM +1100, Wayne W wrote:
> Hi,
>
> I asked this question over on stackoverflow - basically I have a query
> and when using EXPLAIN I see that around 2400 rows are still being
> scanned. I'd added various indexes but it cannot make it perform any
> better.
>
> I wou
c...@hosting4days.com wrote:
:Newbie:
Short Question: Is it possible to create an inner join (or another join)
with multiple tables?
something like
$query_list1 = "SELECT table1.id,table1.status, table2.id, table3.id
(more here - etc.) FROM table1
INNER JOIN table2 ON table1.id = table2.id
I don't see why not, but another choice is to create a view that encompasses
all these tables and Select * From my_view.
Arthur
On Fri, Sep 25, 2009 at 11:28 PM, c...@hosting4days.com <
c...@hosting4days.com> wrote:
> :Newbie:
> Short Question: Is it possible to create an inner join (or another j
I have a column which contains a list of IDs separated by commas. How
can I take the content of this column, and insert it into a temporary
table so that each ID is on a separate row? Can this be done using
SQL?
Can be done in a stored procedure, or (more easily) in an application
language.
: Is it possible to either update or insert in a single query?
This part of the manual might be of use to you:
REPLACE [LOW_PRIORITY | DELAYED]
[INTO] tbl_name [(col_name,...)]
VALUES ({expr | DEFAULT},...),(...),...
Or:
REPLACE [LOW_PRIORITY | DELAYED]
[INTO] tbl_name
SET
You could try a stored procedure that either inserts a new row or
updates an existing row:
CREATE PROCEUDRE InsertOrUpdateRecord(IN NewID INT, ... other params ...
)
BEGIN
IF NOT EXISTS (SELECT ID FROM myTable WHERE ID = NewID) THEN
BEGIN
INSERT INTO myTable ()
END;
ELSE
> REPLACE is a MySQL extension to the SQL standard. It either inserts, or
> deletes and inserts. For another MySQL extension to standard SQL — that
> either inserts or updates — see Section 13.2.4.3, “INSERT ... ON DUPLICATE
> KEY UPDATE Syntax”.
Take note!!
If you're using triggers, foreign key
This part of the manual might be of use to you:
REPLACE [LOW_PRIORITY | DELAYED]
[INTO] tbl_name [(col_name,...)]
VALUES ({expr | DEFAULT},...),(...),...
Or:
REPLACE [LOW_PRIORITY | DELAYED]
[INTO] tbl_name
SET col_name={expr | DEFAULT}, ...
Or:
REPLACE [LOW_PRIORITY | DELAYED]
Have you look at replace ?
http://dev.mysql.com/doc/refman/5.0/en/replace.html
Carlos
Douglas Pearson wrote:
Apologies if this is a dumb question, but is it possible to write a single
query that either updates certain columns in a row, or adds an entirely new
row if there is none already?
I s
In the last episode (Jul 19), Cheng-Lin Yang said:
> I'd like to know if it's possbile to make MySQL auth the account
> through system account via NIS? I want the user in my system who can
> automatically have their own mysql account by using the same password
> on the system. Please kindly help me
I'm far from an expert on the subject, but judging by a quick Google
search for 'NIS mysql backend', people have been able to do this via
OpenLDAP. I just thought I'd send you a starting point.
On 7/19/06, Cheng-Lin Yang <[EMAIL PROTECTED]> wrote:
Hi all,
I'd like to know if it's possbile to ma
zzapper <[EMAIL PROTECTED]> wrote:
> Is it possible to have undeletable/unmodifiable records in a table of otherwise
> modifiable &
> deleteable & createable records?
>
> At present I do it at the Update/Delete level where I have clauses which prevent
> certain records
> being changed. I suppo
Wesley Furgiuele wrote:
I don't think so. I think your current method of either storing it in
the query or with a boolean field is your best bet. What I've seen
done in the past is that records get marked with a user level and
there is either one or a group of users who are allowed to delete or
mo
I don't think so. I think your current method of either storing it in
the query or with a boolean field is your best bet. What I've seen
done in the past is that records get marked with a user level and
there is either one or a group of users who are allowed to delete or
modify those otherwise per
Yea do a search on the mysql.com web site for "date functions" (or just
click here http://dev.mysql.com/doc/mysql/en/Date_and_time_functions.html )
its loaded with many examples and descriptions of useful functions.
Built in date calculations are one thing I really enjoy with mysql.
Best,
Yoed
-
To get the current year, use:
SELECT DATE_FORMAT(NOW(), '%Y');
Basically you can use the DATE_FORMAT to show the present time as
desired.
--bmansell
-Original Message-
From: Greg Hosler [mailto:[EMAIL PROTECTED]
Sent: Friday, April 23, 2004 5:08 PM
To: [EMAIL PROTECTED]
Subject:
Boy do I feel dumb. :^)
-Original Message-
From: Chris [mailto:[EMAIL PROTECTED]
Sent: Monday, February 09, 2004 4:54 PM
To: [EMAIL PROTECTED]
Subject: RE: is it possible...
UPDATE EMAIL_TEST_LIST SET EMAIL_DATE = curdate();
-Original Message-
From: Ligaya Turmelle [mailto
UPDATE EMAIL_TEST_LIST SET EMAIL_DATE = curdate();
-Original Message-
From: Ligaya Turmelle [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 08, 2004 10:42 PM
To: [EMAIL PROTECTED]
Subject: is it possible...
Is it possible to have an update statement that uses curdate()?
Example:
UPDATE
Carlonie,
Use the UPDATE. I assume you mean by "database" here you mean the database table
named "members"... if so, try the following query.
UPDATE members SET user_name = 'john_doe' WHERE user_name = 'John Doe';
--
MikeBlezien
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Thunder Rain Internet Publ
ROTECTED]>
Sent: Thursday, December 18, 2003 11:28 AM
Subject: Re: Is It Possible To Change the Value of A Particular Field
Manually?
>
> Caroline Jen wrote:
> > Hi, I am not a database person. I have a database
> > called "members". One of the fields in this databa
Caroline Jen wrote:
Hi, I am not a database person. I have a database
called "members". One of the fields in this database
is "user_name". There are a number of records in
this database. Under the field user_name, I would
like to make some changes manually; for example, I
want to change
John D
Eugene R. Miller wrote:
This is kind of a silly question is there an easy way to ...
SELECT Status, rating, COUNT(*) FROM song GROUP BY pldupldqd, rating ORDER BY
Status, rating DESC
This gives me all the information I need ...
What I would like to do is something... like
SELECT rating, count(
At 21:26 -0400 9/3/03, Dan Anderson wrote:
I'm writing a search engine to query a database to my site. I know how
to use a WHERE product_name = "foo" if somebody enters the exact product
name, but how could I do something like: WHERE product_name = "*foo*" so
all results containing "foo" in produc
Use LOAD DATA INFILE if you want to import it from the filesystem or use
INSERT/UPDATE if you do it from an application (e.g. perl, php). Make
sure that the column which stores them is defined as BLOB and not as
TEXT. Look up the BLOB definition for size limitation and variations on
BLOBs.
For get
Yes it is. If you are using VB look at
www.vbmysql.com/articles/blobaccessvb.html
Regards,
Mike Hillyer
www.vbmysql.com
> -Original Message-
> From: Dan Anderson [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, July 09, 2003 8:49 AM
> To: [EMAIL PROTECTED]
> Subject: Is it possible to dump
take a look at:
http://www.php4.com/forums/viewtopic.php?t=6
or search the mailing list archive.. there are plenty of threads talking
about this:
For list archives: http://lists.mysql.com/mysql
On Wed, 9 Jul 2003, Dan Anderson wrote:
> Can anyone point me to a reference on how to insert ima
On Fri, 2003-06-20 at 12:16, Barbara Andrew wrote:
> I have three books on mySQL, they all talk about how to
> construct SQL statements and I'm fine with that. What I can't figure out is
> how to get those statements to the right place without having to do it
> manually.
This would be the domai
Hi Edward,
Thanks for the info, but I tried setting the avg_row_length
with no effect - I'm pretty sure you only need that for
dynamic format tables (with varchars and text). My table is
fixed format, and the table does claim to get around the
2/4GB limit.
My problem is the maximum number of r
Sorry, I meant to include this link, too.
http://www.mysql.com/doc/en/Table_size.html
Edward Dudlik
Becoming Digital
www.becomingdigital.com
- Original Message -
From: "Martin Waite" <[EMAIL PROTECTED]>
To: "MySQL List" <[EMAIL PROTECTED]>
Sent: Monday, 09 June, 2003 04:45
Subject: is i
Perhaps this has something to do with it:
"When you use a MyISAM table, MySQL uses the product of max_rows *
avg_row_length to decide how big the resulting table will be. If you don't
specify any of the above options, the maximum size for a table will be 4G (or 2G
if your operating systems only
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> I can FTP and telnet in to my site as "admin" or a user, but
> all the files in
> /var are owned by root so cannot be deleted, with the
> exception of several
> mysql files owned by mysql, which I also cannot
I can FTP and telnet in to my site as "admin" or a user, but all the files in
/var are owned by root so cannot be deleted, with the exception of several
mysql files owned by mysql, which I also cannot move or delete :( If I could
extract the info in the database I could delete that remotely, t
on 12/19/2002 5:00 PM, Paul Nolan at [EMAIL PROTECTED] wrote:
> I`ve got myself into a bit of a mess by allowing my raq3's 200mb var partition
> to fill up. This means I can no longer login to my server as root, because a
> log file of my login cannot be created. Naturally only root can delete o
Dear Steve,
> Is it possible to export data from MS Access into MySQL?
If you don't care to export every single table manually, this is what
you do:
1. Install MyODBC 3.51.04
2. Configure a system DSN for your MySQL server.
3. In Access, right-click the table to be exported.
4. Choose Export...
r 26, 2002 12:50 PM
To: MySQL General Mailing list; [EMAIL PROTECTED]
Subject: Re: Is it possible to export data from access to MySQL?
you're gonna get lots of neat high tech answers
to your problem, so here's a low tech answer just
because it's fun.
construct the database i
you're gonna get lots of neat high tech answers
to your problem, so here's a low tech answer just
because it's fun.
construct the database in mysql.
copy the access database to a working copy to be
safe.
in the working copy, link to the mysql tables.
open the access table a and copy the dat
I used MyAccess to convert my 40mb .mdb file into MySQL and it works
great. You can find it and a whole bunch of other conversion tools on
the MySQL site in Downloads/Other. Here's the link,
http://www.mysql.com/downloads/os-win32.html
Good Luck
>>> "Steve Jackson" <[EMAIL PROTECTED]> 11/26/02 6
Hi!
Yes, it's possible. Export your Access data to standard csv files, and then
use mysqlimport with appropriate parameters to import the csvs into MySQL.
The MySQL manual has excellent guidance on using mysqlimport or LOAD DATA
INFILE statements (which can do the same as mysqlimport).
Iikka
On
A quick way. If you don't have phpMyAdmin running set it up. It has a great
import feature. Just dump the access table to a delimited text file. Then go
to phpMyAdmin, from the main page - create a new database, or select an
existing one. from there scroll down to create a table, enter the table na
MySQL-Front is quite good for this...
- Original Message -
From: "Steve Jackson" <[EMAIL PROTECTED]>
To: "MySQL General Mailing list" <[EMAIL PROTECTED]>
Sent: Tuesday, November 26, 2002 4:37 PM
Subject: Is it possible to export data from access to MySQL?
> Is it possible to export data
age-
> From: FlashGuy [mailto:[EMAIL PROTECTED]]
> Sent: 26. marraskuuta 2002 16:42
> To: MySQL General Mailing list; [EMAIL PROTECTED]
> Subject: Re: Is it possible to export data from access to MySQL?
>
>
>
> Download MySQL-Font v2.5
>
> This is what I used whe
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Steve,
It is quite possible. You can use MyODBC to connect your current
Access database(s) into your MySQL server directly, the major
drawback is that you'd have to create the overall table structure in
MySQL first and then link the table from MySQL
I ran across several quick and dirty, but very effective little
converters at this site:
http://www.intranet2internet.com
Regards,
Jim
Jim Esten
Chief Techbot
WebDynamic http://www.wdynamic.com
-Original Message-
From: Steve Jackson [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November
Download MySQL-Font v2.5
This is what I used when I switched from Access to MySQL.
Once installed just load MySQL-Front and click on "Im-/Export" on the toolbar. Select
ODBC Import.
Viola!
On Tue, 26 Nov 2002 16:37:45 +0200, Steve Jackson wrote:
> Is it possible to export data from MS Acce
Ralf Koellner wrote:
> Hi,
>
> Is it possible to replicate just some tables instead of a whole mysql
> database? A replication of the whole database would be not necessary in
> my case. It would be a one-way replication (means slave won't update
> master).
You can use 'replicate-do-table' on sla
Ralf,
Monday, October 28, 2002, 11:48:22 PM, you wrote:
RK> Is it possible to replicate just some tables instead of a whole mysql
RK> database? A replication of the whole database would be not necessary in
RK> my case. It would be a one-way replication (means slave won't update
RK> master).
R
Hi,
Is it possible to replicate just some tables instead of a whole mysql
database? A replication of the whole database would be not necessary in
my case. It would be a one-way replication (means slave won't update
master).
Furthermore:
Is there a cheep tool taking care of that (without chang
- Original Message -
From: "Jay Blanchard" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, June 04, 2002 8:48 PM
Subject: RE: Is it possible to have MySQL perform an action at a
specific time?
> Sounds like you need to run a CRON job (you will have t
Hummm..one solution is just to exploit the 'at' program of unix/linux
systems...
I use that for backups, table dumps etc. combined with perl or php
scripts...
$0.02;
Eivind
-
Before posting, please check:
http:/
Have you looked at cron on LINUX?
- Original Message -
From: "Jamie Buck" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, June 04, 2002 11:37 AM
Subject: Is it possible to have MySQL perform an action at a specifictime?
> I have a file containing commands to add and drop tab
[snip]
I have a file containing commands to add and drop tables as a means of
synchronizing two databases. What i want to happen is for MySQL to open
this file and read it at a specific time without the user having to
explicitly connect to MySQL and type in the commands in order to get it
to read
en; Brandon Lewis; [EMAIL PROTECTED]
> Subject: RE: Is it possible to Rename Database
>
>
> Or, use mysqldump to dump the entire database, edit the CREATE
> DATABASE line
> at the top to the new name and pipe it all back into mysql, then drop the
> old one?
>
>
It's the only way with InnoDB short of renaming each table in the
format:
RENAME TABLE olddb.table1 TO newdb.table1
Ken
>
> That's sort of taking the long way around the barn, isn't it?
>
> Will
>
-
Before posting, please check
ginal Message-
> From: Ravi Raman [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, October 03, 2001 6:04 PM
> To: Carsten H. Pedersen; Brandon Lewis; [EMAIL PROTECTED]
> Subject: RE: Is it possible to Rename Database
>
>
> Or, use mysqldump to dump the entire database, edit the
; [EMAIL PROTECTED]
Subject: RE: Is it possible to Rename Database
> Is it possible to rename a database?
I would assume that the only way to do is is to
shut down the server, then rename the directory
of the database.
/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit
> Is it possible to rename a database?
I would assume that the only way to do is is to
shut down the server, then rename the directory
of the database.
/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq
-
Hi Brandon,
It is possible if you are you are using myisam or DBD table types,
but you have to rename the directory from the Unix shell prompt.
There is not yet a RENAME DATABASE command (althought it is on the
todo list) and no way that I know of (short of renaming each table if
you only have
On 22-Aug-2001 Johan Nilsson wrote:
> Hi,
>
> Is it possible for me to do a SELECT COUNT(*) and GROUP BY the answers based
> on a INTERVAL e.g. HOUR?
>
> the e.g. data:
> ++
>| id | time |
> ++
>| 1 | 08:30 |
>| 2 | 09:30 |
>| 3 | 09:31 |
>| 4 | 09:32 |
> +-
In message <001301c0ddf3$49e1cc60$12ffa8c0@notodo>, Martin Cabrera
Diaubalick <[EMAIL PROTECTED]> writes
>Hi there!
>
>I installed MyODBC and tried to import a Database from my Web Hosting
>account but didn't let me. Was it me that didn't know how to do it or is it
>possible that access is only a
do & publish any improvements you suggest :)
On Tue, 1 May 2001 10:26:05 -0700 (PDT)
sagar tamhane <[EMAIL PROTECTED]> wrote:
> hi,
>
> I was reading the manual for the full-text search. It
> is really interesting to have a search engine embedded
> into the database itself!!!.
>
> Mysql uses t
sser; 'nigel wood'; [EMAIL PROTECTED]
> Subject: Re: Is it possible to use an "optional field"?
>
>
> Your query converted to using left joins:
> SELECT DISTINCT Questions.QuestionID, Questions.Question,
> Experts.ExpertFullName, Category.CategoryName, Q
>
To: "'nigel wood'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, March 28, 2001 3:18 PM
Subject: RE: Is it possible to use an "optional field"?
> I took a look at the manual, but I am a bit unsure of how this would be
done
> in
Assuming that there is a one-to-one relationship between the tables on the
FunctionID (meaning there is only one entry in Functions for each
FunctionID), then...
SELECT Names.NameID, Names.Name, Names.FunctionID, Functions.FunctionName
FROM Names LEFT JOIN Functions ON (Names.FunctionID=Function
-Original Message-
> From: nigel wood [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, March 28, 2001 8:16 PM
> To: Roy Nasser
> Subject: Re: Is it possible to use an "optional field"?
>
>
> On Wed, 28 Mar 2001, you wrote:
> > Hi,
> >
> > I ha
On 2001-02-18, Jon Roig did say,
> It's actually pretty simple.
>
> Here's an excellent tutorial on how to do it with PHP.
>
> http://www.oreillynet.com/pub/a/php/2000/09/15/php_mysql.html
>
> > From: Nikhilesh Haval <[EMAIL PROTECTED]>
> >
> > I want to store different file formats in a data
It's actually pretty simple.
Here's an excellent tutorial on how to do it with PHP.
http://www.oreillynet.com/pub/a/php/2000/09/15/php_mysql.html
Enjoy -- it's pretty cool what you can do with it.
-- jon
> From: Nikhilesh Haval <[EMAIL PROTECTED]>
> Organization: University of Sheffield
Cc: [EMAIL PROTECTED]
Subject: Re: is it possible to store images in mysql db?
Actually, blobs are stored in files in data directory. You can store your
binary files in data directory, if you wish.
- Original Message -
From: Gerald R. Jensen <[EMAIL PROTECTED]>
To: clay bon
Sent: Saturday, February 17, 2001 5:52 PM
Subject: Re: is it possible to store images in mysql db?
> Actually ... there are often some good reasons one might want to store
> pictures in BLOBs.
>
> For example, our integrated application gives the administrators at our
> various cu
files. If we store them as BLOBs in
the database, we know exactly where they are.
G. Jensen
- Original Message -
From: "clay bond" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, February 17, 2001 8:16 AM
Subject: Re: is it possible to store images in
On Sat, 17 Feb 2001, Nikhilesh Haval wrote:
> I want to store different file formats in a database like images (*.jpg)
> or audio files (*.mp3). Is it possible to do so in mysql?
>
Yeah, that's what BLOB is for--but why would you want
to do that? Why not just store the path in the table,
and
damn it, DOES ANYBODY READ MANUALS these days?
in short: yes
for details: RTFM
it might not be good. you probabluy want to keep filenames in
the db, but files itself in the filesystems. Your choice.
Artem
- Original Message -
From: "Nikhilesh Haval" <[EMAIL PROTECTED]>
To: "mysql list"
72 matches
Mail list logo