Arun Kumar PG wrote:
Guys,
I know this is a stupid thing but I wanted to know if we have an index
on a
column X and if i have a query having 1 OR conditions on the
field e.g.
where X=10 OR x=12 OR x=13 OR x=15.. so on then will it give any
benefits in terms of speed?
Yes the index
Hi,
Might be column indexing have restriction over number of columns to be
indexed, but for number of columns, hope you can overrider with the
variables
avg_row_length and max_rows during create/alter table.
The length/size of the table depends on the file system(maximum file size
defined
Fabian Köhler wrote:
Hello,
i have table with answers to questions. Every answer is a column in the table.
i.e.
id|q1|q2|q3
1|answer1|answer2|answer5
2|answer3|answer4|asnwer6
another option to save it would be sth like this:
id|field|value
1|q1|answer1
1|q2|answer2
1|q3|answer5
Fabian Köhler wrote:
Hello,
i have table with answers to questions. Every answer is a column in the table.
i.e.
id|q1|q2|q3
1|answer1|answer2|answer5
2|answer3|answer4|asnwer6
another option to save it would be sth like this:
id|field|value
1|q1|answer1
1|q2|answer2
1|q3|answer5
Arg, come on, really.
where t.created = date(now()));
--
Later
Mogens Melander
+45 40 85 71 38
+66 870 133 224
On Mon, April 16, 2007 15:18, Jay Blanchard wrote:
[snip]
select s.* from store s
where s.id not in
(select t.storeid from trans t where t.created=date(now()));
[/snip]
Argh, that was not the one i wanted to send :)
This is the one:
select s.* from store s
where s.id not in
(select t.storeid from trans t
where t.created date(now()) - interval 1 day);
--
Later
Mogens Melander
+45 40 85 71 38
+66 870 133 224
On Tue, April 17, 2007 09:20,
I had a trial version of Navicat 7.2 in my system. Now I installed the full
version 7.0.9 enterprise Navicat. After that when I run the existing
query,,I get a n error message -Got error 1 from storage engine..Could you
guys pls help me
I noticed that when I run a small query it works..Is it
Hi Renish,
What is the query that you ran, please let us know.
regards
anandkl
On 4/17/07, Renish koshy [EMAIL PROTECTED] wrote:
I had a trial version of Navicat 7.2 in my system. Now I installed the
full
version 7.0.9 enterprise Navicat. After that when I run the existing
query,,I get a n
I guess it is nothing to do with the query as it was working perfectly
fine be4 installing the Navicat enterprise version 7.0.9 .thanks a lot
On 4/17/07, Ananda Kumar [EMAIL PROTECTED] wrote:
Hi Renish,
What is the query that you ran, please let us know.
regards
anandkl
I guess it is nothing to do with the query as it was working perfectly
fine be4 installing the Navicat enterprise version 7.0.9 .thanks a lot
Why don't you install 7.2 full version? Why did you go back a few versions?
Martijn Tonies
Database Workbench - development tool for MySQL, and
great. thx!
On 4/17/07, Daniel Kasak [EMAIL PROTECTED] wrote:
Arun Kumar PG wrote:
Guys,
I know this is a stupid thing but I wanted to know if we have an index
on a
column X and if i have a query having 1 OR conditions on the
field e.g.
where X=10 OR x=12 OR x=13 OR x=15.. so
Thanks for all the input. The problem i have with this idea:
Really? Wow, my opinion is that you're trying to do in one table what
you should do in two. Have a questions table, and an answers table. The
answers table would have a column specifying which question they belong
to. i.e.
I also thought about creating a materialized view with mysql by doing:
create table vanswers (select ... query to get the table in the
format..)
or a stored procedure which generates a table like the one below, but
all solutions seem to be slow like hell due to the high large joins
which are
There is another question coming to my mind: is it possible to define a
view which has more columns then put nof cols limit for storage engine
here or does the same limits for a normal table apply to a view?
regards,
Fabian
On Mon, 16 Apr 2007 23:39:40 -0700, Micah Stevens
[EMAIL PROTECTED]
Hi,
Really? Wow, my opinion is that you're trying to do in one table what
you should do in two. Have a questions table, and an answers table. The
answers table would have a column specifying which question they belong
to. i.e.
QUESTIONS
int autoincrement questionID
question
ANSWERS
int
If the possible answers are not predetermined, you have a real problem. I
don't know how you can optimize that. A full-text index might help, but I
don't have a good understanding of the type of queries you're going to need.
I am not a good person to ask about performance, nor am I familiar with
I agree it is poor design, but other than putting a full text index on the
answers I'm not sure what can be done.
Of course, that might well be faster for retrievals; but it would be slower
on insertion. I don't know which would predominate in this case.
Regards,
Jerry Schwartz
Global
The right way to do this would be your second way, where there would be
one row per answer. I can't really grasp how the questions and answers
relate to anything else, so I'm making a lot of assumptions.
If you are concerned that this technique is too slow, because it involves
linking
The right way to do this would be your second way, where there would be
one row per answer. I can't really grasp how the questions and answers
relate to anything else, so I'm making a lot of assumptions.
If you are concerned that this technique is too slow, because it involves
linking two tables,
Not necessarily. I do precisely this for a data base whose structure I do
not control. I stuff
|code1|code2|code3| ...
Into an unused text field. The users can query on LIKE %|code2|%. The key
is to have a delimiter at the start and end of the entire list, so that
the
string match
Not necessarily. I do precisely this for a data base whose structure I do
not control. I stuff
|code1|code2|code3| ...
Into an unused text field. The users can query on LIKE %|code2|%. The key
is to have a delimiter at the start and end of the entire list, so that the
string match doesn't get
The right way to do this would be your second way, where there would be
one row per answer. I can't really grasp how the questions and answers
relate to anything else, so I'm making a lot of assumptions.
If you are concerned that this technique is too slow, because it involves
linking two
i'm using the following query:
REPLACE INTO vviews_total(
SELECT uuser_id, sum( vviews.views ) AS views, sum( vviews.embeds ) AS
embeds, sum( vviews.plinks ) AS plinks, sum( vviews.`30d` ) AS 30d, sum(
vviews.`7d` ) AS 7d, sum( vviews.`24h` ) AS 24h, sum( vviews.site30d ) AS
site30d, sum( site7d
On 04/17/2007 04:18 AM, Fabian Köhler wrote:
Thanks for all the input. The problem i have with this idea:
Really? Wow, my opinion is that you're trying to do in one table what
you should do in two. Have a questions table, and an answers table. The
answers table would have a column
mos [EMAIL PROTECTED] wrote: At 06:23 PM 4/15/2007, you wrote:
Hi,
I have a table with 2 million records but without an index or a primary
key. The column upon which I want to create an index is a varchar. Will
it give me any advantage when I have to do a select on the column?
BTW, here
Baron Schwartz [EMAIL PROTECTED] wrote: murthy gandikota wrote:
Hi,
I have a table with 2 million records but without an index or a primary key.
The column upon which I want to create an index is a varchar. Will it give me
any advantage when I have to do a select on the column?
BTW,
There is no option to do this to my knowledge. However, this would be a
quick workaround:
- TRUNCATE TABLE table; # clears table completely, akin to doing
DROP/CREATE TABLE
- INSERT INTO table SELECT .. FROM ..;
On Mon, 16 Apr 2007, Amer Neely wrote:
At 08:14 AM 4/13/2007, Amer Neely wrote:
Atle Veka wrote:
There is no option to do this to my knowledge. However, this would be a
quick workaround:
- TRUNCATE TABLE table; # clears table completely, akin to doing
DROP/CREATE TABLE
- INSERT INTO table SELECT .. FROM ..;
Again, you missed the critical part. I'm trying to replace a
At 10:14 AM -0400 4/13/07, Amer Neely wrote:
I'm using MySQL 5.0.21 and am trying to find out if it is possible
to overwrite an existing file when using a 'SELECT ... INTO' command
from the command line. Is there another parameter that can do this?
I've looked through the online reference
Paul DuBois wrote:
At 10:14 AM -0400 4/13/07, Amer Neely wrote:
I'm using MySQL 5.0.21 and am trying to find out if it is possible to
overwrite an existing file when using a 'SELECT ... INTO' command from
the command line. Is there another parameter that can do this? I've
looked through the
Hi Tanner,
Tanner Postert wrote:
i'm using the following query:
REPLACE INTO vviews_total(
SELECT uuser_id, sum( vviews.views ) AS views, sum( vviews.embeds ) AS
embeds, sum( vviews.plinks ) AS plinks, sum( vviews.`30d` ) AS 30d, sum(
vviews.`7d` ) AS 7d, sum( vviews.`24h` ) AS 24h, sum(
In most common places where a VALUES list is specified you can
substitute a select statement which produces such a list. SQL is an
algebra after all. The only thing wrong with the syntax of the
original poster was the braces around the select statement itself.
Drop them and it should work fine.
Hi Folks,
I am putting together a table to hold log entries. I was going to index
it on a field with a type of TimeStamp. Unfortunately this will not
suit my needs because I could have more than one log entry per second.
As far as my (limited) knowledge goes I have two options to get
Hi,all
The number of the records in one table increase constantly. As
evaluated, the amount would increase to at least 30 millions within one
year. So we worry about whether mysql could handle such a big amount of
records with good performance. Or need we some other solutions to avoid
this
In the last episode (Apr 18), He, Ming Xin PSE NKG said:
The number of the records in one table increase constantly. As
evaluated, the amount would increase to at least 30 millions within
one year. So we worry about whether mysql could handle such a big
amount of records with good
35 matches
Mail list logo