Re: Restoring a binary log ( mysqlbinlog )

2006-04-05 Thread Mauricio Pellegrini
gt; use intra ; CREATE TABLE table1 AS SELECT * FROM hrdb.table2 > Would this prevent this kind of querys from appearing in the source ? > > --Praj > > > On Wed, 05 Apr 2006 08:44:52 -0300 > Mauricio Pellegrini <[EMAIL PROTECTED]> wrote: > > > Hi ,

Restoring a binary log ( mysqlbinlog )

2006-04-05 Thread Mauricio Pellegrini
Hi , Yesterday our main database was dropped by mystake. This has never happened before. Furtunately we had a daily backup performed with mysqldump at about 06:00 am that day. As the problem ocurred at about 12:00am we had to restore the transactions from the binary log ( we have several bina

Re: Numbering rows

2005-05-13 Thread Mauricio Pellegrini
re could be less. That's it. Thank you very much for your valuable help Mauricio On Fri, 2005-05-13 at 06:22, Harald Fuchs wrote: > In article <[EMAIL PROTECTED]>, > Mauricio Pellegrini <[EMAIL PROTECTED]> writes: > &

Numbering rows

2005-05-12 Thread Mauricio Pellegrini
Hi , I don't know if this is possible with Sql but I'm trying to set the row number into a field for each row. The complexity comes when I try to do that according to some grouping rules. I think I'll made myself more clear with a simple example: This is the table I have Column Id is primary ke

Re: How to select the max value

2005-04-13 Thread Mauricio Pellegrini
several rows with the > same max date, the outer query will return all of them. > > Please note that I am running MySQL 4.0.x so I can't test this in MySQL but > it would work in DB2; DB2 and MySQL are very close in most respects. > > Rhino > > - Original Mess

How to select the max value

2005-04-12 Thread Mauricio Pellegrini
Hi, I need to select the max value from a set of records but I also need the primary key for that record. The problem is that the record id may not be the same as the record max value for the column as in the following example: Table_x Id x_col date_col 1 1 2005-04-11 2

Re: How to import data from Dbase3?

2005-03-24 Thread Mauricio Pellegrini
Hi there's a free utility name dbf2mysql I assume you are running dbase3 plus under windows/dos Look for it in google or ask me and I would send it to you. I´ve used it under windows with dbf tables from Clipper, dBase and Fox It doesn't require ODBC drivers at all. greetings Mauricio On Wed,

Upgrading from 4.1.4 gamma to 4.1.10a

2005-03-14 Thread Mauricio Pellegrini
Hi, I'm intending to upgrade from mysql 4.1.4 gamma with InnnoDB to production release 4.1.10a with InnoDB on a suse Linux machine. I've read the documentation inside the binary distribution and found the steps to install this release from scratch. my question is : Is it recomendable to leave in

Re: Lock timeout problem

2005-03-14 Thread Mauricio Pellegrini
se Locked table (pr_prestaciones) was not updated by the query in *** (2) thanks Mauricio On Fri, 2005-03-11 at 18:42, Heikki Tuuri wrote: > Mauricio, > > - Original Message - > From: "Mauricio Pellegrini" <[EMAIL PROTECTED]> > Newsgroups: mailing.datab

Limit of a sql script

2005-03-12 Thread Mauricio Pellegrini
Hi , I'm using mysql 4.1.4 gamma with InnoDB suse 8.2 reiser fs. I'am doing backups using mysqldump which creates a sql script with the structure for all tables plus the correspondig commands to create them and also the data to be inserted in each one of them. Latter when I have to restore one o

Lock timeout problem

2005-03-11 Thread Mauricio Pellegrini
Hi, we are using mysql 4.1.4-gamma and a few days ago we started to receive lock wait timeout messages from within our application also on other connections via tcp/ip ( from mysql clients ) the same thing happens While we are trying to discover what is causing these errors I've noted this in the

Re: Query_cache_size Question

2005-03-09 Thread Mauricio Pellegrini
questions for thoses results ? > There's a lot of lowmem_prunes, so I would indeed increase the memory > size to reduce the risk of lowmem_prunes. > What is your query_cache_limit ? > >Jocelyn > > Mauricio Pellegrini a écrit : &

Re: Query_cache_size Question

2005-03-09 Thread Mauricio Pellegrini
not_cached means the number of query results that didn't get into the cache because of a space limitation ? If so, perhaps adding few more Mb would improve that number , isn't it? On Wed, 2005-03-09 at 19:30, Dan Nelson wrote: > In the last episode (Mar 09), Mauricio Pellegrini said

Query_cache_size Question

2005-03-09 Thread Mauricio Pellegrini
Hi, I'm trying to tweak the execution time for querys on my mysql server which is using InnoDB. I know that there are a lot of things to check but one of them, perhaps not the most important, is the query_cache_size. I have a dual Xeon cpu with 4gb of ram and this is a Linux dedicated server whic

Re: skip-name-resolve

2005-03-09 Thread Mauricio Pellegrini
accepted by mysqld So I repost my question Is there a sure way to check if skip-name-resolve is in efect ? Thanks Mauricio On Wed, 2005-03-09 at 14:20, Keith Ivey wrote: > Mauricio Pellegrini wrote: > > > Is there a way to check whether this option is active or not, while the > >

Re: skip-name-resolve

2005-03-09 Thread Mauricio Pellegrini
aults-file command line > option to be sure). > > > No.2 > > This slowness problem could occur also on a server running SuSe Linux > > 8.2 ? > > Usually using MySQL server on Unix gives better results than on Windows. See: > http://dev.mysql.com/doc/mysql/en/

skip-name-resolve

2005-03-07 Thread Mauricio Pellegrini
Hi, Sometimes our Internet conection goes down and then all conections via tcp/ip to our the mysql server (v.4.1.5) are slow. I've read in the manual that one could use --skip-name-resolve as a possible solution to this problem under windows. The thing is that I've set this option int /etc/my.cnf

Re: Which file to backup

2005-03-05 Thread Mauricio Pellegrini
Yes , I'm using innodb. Is it necesary to do a mysqladmin flush-logs before making a copy of ib_logfile* or must the server go down to do a safe copy of the ib_logfiles ? thanks Mauricio On Fri, 2004-09-17 at 09:08, Egor Egorov wrote: > Mauricio Pellegrini <[EMAIL PROTEC

How to create random table names on the fly

2004-12-18 Thread Mauricio Pellegrini
Hi, I'm using MySql 4.1.4 gamma and there are certain circumstances in wich I need to create tables with random names from within querys. And after using them I need to drop them; so I need a way to *remember* these table names so I can dispose them later. Is that possible with MySql? Thank

Re: Naming columns dynamically

2004-11-16 Thread Mauricio Pellegrini
icio. > > > > I've found something in comments at: > > > > http://dev.mysql.com/doc/mysql/en/Problems_with_alias.html > > > > But I don't know if that will help you. Here it is: > > > > > > > > "Posted by Ravi Kumar on November 10 2004 9:21a

Re: Naming columns dynamically

2004-11-16 Thread Mauricio Pellegrini
> > Execute the following command: > mysql.exe -BN -u %uname% -p"%pwd%" -h %host% -P%port% dbname < t.sql > t1.sql > > In t1.sql, we'll have the required command and this can be wrapped inside > a shell script." > > > > Mauricio Pellegr

Naming columns dynamically

2004-11-15 Thread Mauricio Pellegrini
Hi , I need to do the following: Given a certain variable for example @var I want to include the contents of that variable as part of the name of a result column. I'll try to explain myself a bit more with this example Set @var = 'October_' ; Select Tot as 'Total

Complex update query

2004-10-18 Thread Mauricio Pellegrini
Hi, I don't know if this is possible ( my experience with SQL is very short) but I need to update table A from table B but saving the "Old values" from certain columns into table C. In other words I have 3 tables A,B,C. Table A is going to be updated with values from table B, but I have to kee

Re: How to pick the oldest row

2004-09-28 Thread Mauricio Pellegrini
Thanks Jim,but that doesn't work for me because the order by performs after the records have been selected. At that time I already have the unwanted row. I will try to explain a little bit further SELECT * FROM `mj_tmp`This select is suposed to return all rows WHERE idk NOT IN but

Re: Conexiones no autorizadas

2004-09-27 Thread Mauricio Pellegrini
Very sorry!!! I've just mistaken the email address.. This message was intended to be sent to a Spanish SuSE List. I Apologize. Mauricio On Mon, 2004-09-27 at 15:55, Mauricio Pellegrini wrote: > Hola , > > Estoy empezando a notar intentos de ingreso con usuarios ilegales >

Conexiones no autorizadas

2004-09-27 Thread Mauricio Pellegrini
Hola , Estoy empezando a notar intentos de ingreso con usuarios ilegales no existentes) a mi server. Mi pregunta es : Como lo rastreo teniendo como unico dato el numero de ip desde el cual se esta conectando? O si alguien tiene una mejor idea o ha pasado por lo mismo, le agradecere me comente s

Re: SV: Mysql goes down when executing query

2004-09-24 Thread Mauricio Pellegrini
gt; > ----- Alkuperäinen viesti - > Lähettäjä: "Mauricio Pellegrini" <[EMAIL PROTECTED]> > Vastaanottaja: "Heikki Tuuri" <[EMAIL PROTECTED]> > Kopio: "MySql List" <[EMAIL PROTECTED]> > Lähetetty: Thursday, September 16, 2004 7:25 PM

Re: What's wrong with the use of Between and datetime columns ?

2004-09-23 Thread Mauricio Pellegrini
Sorry , You were right. I was mistaken the results Between works just fine. It was me. I'm Very sorry Thank you all On Thu, 2004-09-23 at 15:45, Mauricio Pellegrini wrote: > Thanks,but I've also tried the date() function > to compare only the date part of the colum

Re: What's wrong with the use of Between and datetime columns ?

2004-09-23 Thread Mauricio Pellegrini
Thanks,but I've also tried the date() function to compare only the date part of the column like this select * where date(date_col) between date(startdate) and date(enddate) and the result is the same. On Thu, 2004-09-23 at 11:04, gerald_clark wrote: > Mauricio Pellegrini wrote:

What's wrong with the use of Between and datetime columns ?

2004-09-23 Thread Mauricio Pellegrini
Hi, I'm using Between to fetch rows whose date column is between two dates. The thing is, sometimes it brings all the rows including those with a date similar to the upper limit ( which is the correct behaviour, according to the manual) and in other cases it brings al the rows excluding those e

Which file to backup

2004-09-16 Thread Mauricio Pellegrini
Sorry for my bad English!! From: Mauricio Pellegrini <[EMAIL PROTECTED]> To: MySql List <[EMAIL PROTECTED]> Subject: Wich file to backup Date: 16 Sep 2004 11:28:56 -0700 Hi , I'm trying to backup the 'binary log' and don't know which file is it. these are the f

Re: SV: Mysql goes down when executing query

2004-09-16 Thread Mauricio Pellegrini
www.innodb.com/order.php > > Order MySQL technical support from https://order.mysql.com/ > > > > - Original Message - > From: "Mauricio Pellegrini" <[EMAIL PROTECTED]> > Newsgroups: mailing.database.myodbc > Sent: Wednesday, September 15, 2004 3:46

Wich file to backup

2004-09-16 Thread Mauricio Pellegrini
Hi , I'm trying to backup the 'binary log' and don't know wich file is it. these are the files I see in my datadir -rw-rw 1 mysql users175K Sep 14 14:21 hrrgp01-bin.07 -rw-rw 1 mysql users345K Sep 14 15:03 hrrgp01-bin.08 -rw-rw 1 mysql users1.6

Re: SV: Mysql goes down when executing query

2004-09-15 Thread Mauricio Pellegrini
Thanks, but already have innodb_buffer_pool_size=160M and I've raised innodb_additional_mem_pool_size from 2M to 10M And the problem remains the same. Any sugestions? Thanks Mauricio On Tue, 2004-09-14 at 18:05, Nickolai Nielsen wrote: > Hi > > Try setting these variables in you conf: > s

Mysql goes down when executing query

2004-09-14 Thread Mauricio Pellegrini
Hi, Sorry to disturb but Mysql 4.1.4 gamma goes down when executing this query. I've tryed the same query without the coalesce function and the problem persists. select coalesce(viehc,0), coalesce(vieapellido,0), coalesce(vienombres,0), coalesce(viedoc,0), coalesce(numero,0),

Wrong query result

2004-09-11 Thread Mauricio Pellegrini
Sorry to insist with this, but still can't find the reason. Any ideas? -Forwarded Message- Hi, I'm using MySql 4.1.4 Gamma and the following query returns values containing N and Ñ instead of only those containing Ñ. The query is as follows Select Lastname from table1 where loc

License question

2004-09-09 Thread Mauricio Pellegrini
Hi, Sorry to ask this in here. If it's not the right place please ignore the post. I want to know if someone could claim a license upon an application wich was developed using Php and a non-commercially-licensed copy of MySql. I mean, the application is designed to work only with MySql as databa

Wrong query result

2004-09-08 Thread Mauricio Pellegrini
Hi, I'm using MySql 4.1.4 Gamma and the following query returns values containing N and Ñ instead of only those containing Ñ. The query is as follows Select Lastname from table1 where locate("Ñ",Lastname)>0 The result set includes values like this HERNANDEZ NUÑES

Mysql 4.1.4 gamma - Install error

2004-09-06 Thread Mauricio Pellegrini
Hi, I'm trying to upgrade my mysql 4.1.0 to 4.1.4 For this purpose I've uninstalled the server and client and after installing the new version I've had this error on the log 040902 21:47:53 mysqld started 040902 21:47:53 [ERROR] Warning: Asked for 196608 thread stack, but got 126976 Despite tha

Re: Query hangs mysql 4.1

2004-09-03 Thread Mauricio Pellegrini
Hi, I don't mean to abuse, but could someone give me some help on how to upgrade from 4.1.1 Alpha to 4.1.4 gamma Any help gratly appreciated Mauricio On Thu, 2004-09-02 at 10:34, Heikki Tuuri wrote: > Mauricio, > > please send the FULL .err log to me. Do not cut anything off. > > [EMAIL PRO

Query hangs mysql 4.1

2004-09-02 Thread Mauricio Pellegrini
Hi, I've experienced a hang after running a query wich is run usually 2 to 3 times a day without a problem till now. This is what the error log reports nnoDB: Thread 4784139 stopped in file btr0pcur.c line 205 Attempting backtrace. You can use the following information to find out where mysqld

how to hide certain columns

2004-08-25 Thread Mauricio Pellegrini
Hi, I'm using a few variables to do some calculations in the select list of a query but I don't like those columns ( the ones performing the calc's ) to be shown in the result. for example: Set @var1=0; Set @var2=1; Select Col1, as 'C1' Col2as

Re: Using SUM in a special way

2004-08-13 Thread Mauricio Pellegrini
l the rest of the people who answered my question Gratefully Mauricio On Fri, 2004-08-13 at 11:55, Keith Ivey wrote: > Mauricio Pellegrini wrote: > > >and would like to obtain this result from a query > > > > Col1Col2Col3 > > 1 20 20 &

Using SUM in a special way

2004-08-13 Thread Mauricio Pellegrini
Hi, I would like to use SUM or any other function to sum a series of records as in the following example. I have this table T1 Col1Col2 1 20 2 10 1 10 25 1 20 3 10 and would like to obtain this r

ERROR 1137: Can't reopen table: 'mj_tmp_diag'

2004-07-05 Thread Mauricio Pellegrini
Hi, I have this pretty complex query which uses two temporary tables. The first temporary table ( T1 ) is created as a result from query 'A' The second temporary table is created as result from a query based upon temporary table one ( T1 ). At this point I get the message ERROR 1

How to turn rows into columns

2004-06-29 Thread Mauricio Pellegrini
Hi , Sorry to ask this question, but I'm in desperate need to acomplish this report, and don't even know it is possible to be done. The thing is I have to turn rows from one table into columns in other table. The first table looks like this T1 --- id cod --- 1 bb

MySqldump not giving the right output

2004-06-10 Thread Mauricio Pellegrini
Hi, I'm dumping my database with Mysqldump using this command mysqldump --extended-insert --add-drop-table -K --user=root xdatab xtable > xtable.sql For a certain number of tables, the command seems to work perfectly.. But some of the tables are missing records at the begining. Could it be th

Re: Slow querys When ADSL is down on W2K

2004-06-08 Thread Mauricio Pellegrini
> > > > The only thing strange about this is that in your previous > post you mentioned that the wk2 machine had an ip of > 192.168.10.5. Yes, that example was from another machine on the same net > > The above route print output seems to be for a machine > with an ip of 192.168.10.2. Yes.

Re: Slow querys When ADSL is down on W2K

2004-06-08 Thread Mauricio Pellegrini
On Tue, 2004-06-08 at 12:57, John Fawcett wrote: > From: "Mauricio Pellegrini" > > Hi, > > > > I've tryed that after reading this message, > > But couldn't get the route correctly established. > > > > I'm giving some more details

Re2: Slow querys When ADSL is down on W2K

2004-06-08 Thread Mauricio Pellegrini
ute happens to be) > g = gateway (I guess this would be the switch, not quite sure, > suggestions anyone???) > > If this solves the problem, you should make the route persistent by > adding '-p' to the above command. > > Hope this helps. > > > Mauricio Pel

RE: Slow querys When ADSL is down on W2K

2004-06-08 Thread Mauricio Pellegrini
hen the adsl goes down? > > Not a network expert, so just a guess 8-) > > Peter > > > > -Original Message- > > From: Mauricio Pellegrini [mailto:[EMAIL PROTECTED] > > Sent: 04 June 2004 00:44 > > To: MySql List > > Subject: Slow querys When

Slow querys When ADSL is down on W2K

2004-06-03 Thread Mauricio Pellegrini
Hi, This seems to be a strange situation. I have a server ( Sun fire v65x ) running SuSE 8.2 and My-Sql 4.1.1alpha-max. I've detected that when our adsl internet connection is down the querys on our local network turns to be unusually slow. But this situation occurs only when querys are execu

Re: MySQL Warning Messages - Continued..

2004-06-03 Thread Mauricio Pellegrini
assen wrote: > I believe this means mysql found fewer columns in each row of your infile > than are defined in your table. > > Michael > > Mauricio Pellegrini wrote: > > > Hi again, > > Thanks to all your kind answers, I've > > found the Warn

MySQL Warning Messages - Continued..

2004-06-03 Thread Mauricio Pellegrini
Hi again, Thanks to all your kind answers, I've found the Warning Text is as Follows Warning|1260|Record count is fewer than the column count at row 1 Warning|1260|Record count is fewer than the column count at row 2 Warning|1260|Record count is fewer than the column coun

How to retrieve MySQL Warning Messages

2004-06-03 Thread Mauricio Pellegrini
Hi, Mysql 4.018 , SuSE 8.2. I'm using LOAD DATA LOCAL INFILE "//.txt" INTO TABLE zz_zzz ; and I get the following message Query OK, 158063 rows affected (1 min 36.49 sec) Records: 158063 Deleted: 0 Skipped: 0 Warnings: 158115 Nothing seems to be wrong with the

ERROR 2013

2004-05-26 Thread Mauricio Pellegrini
Hi, I'm using MySql 4.0.18 on Linux (SuSE 8.2) and I'm getting this error ERROR 2013: Lost connection to MySQL server during query a few seconds after launching the following command LOAD DATA LOCAL INFILE '/root/hc.txt' into table af_afiliados ; soon after that I repeat t

Backups with version 4.1

2004-05-17 Thread Mauricio Pellegrini
Hi I'm using, Mysql version 4.1.1 with InnoDB under SuSE linux 8.2 I don't know if this is the right place to ask. If not please point me in the right direction. I'm performing nightly backups of the datadir. So my backups include a database and the Mysql databases themselves ( also I think there