Commercial Licence

2004-03-10 Thread Pierre Luguern
I want to run a commercial product based on  MySQL. I have one centralized
server running MySQL in replication mode (master server). I have five
clients running MySQL (each slave is running one MySQL daemon).
Do I have to acquire only one commercial licence for my master server or do
I have do get commercail licence for master and slave.
Thanks in advance.





mailto:[EMAIL PROTECTED]








-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Update statement with LIKE

2004-03-10 Thread Egor Egorov
Ligaya Turmelle [EMAIL PROTECTED] wrote:
 Can I use  LIKE in an UPDATE statement when it is not in the WHERE clause?
 I only know what the attribute name will end with (may be prefixed).
 
 Example:
 UPDATE table SET LIKE '%donut' = valueColumn1 WHERE condition1 = value1;
 

Find column names ending with 'donut' with:
SHOW COLUMNS FROM table LIKE '%donut';

Then put column names to UPDATE statement.



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: JDBC timeout after 4.0.8 - 4.0.18 upgrade?

2004-03-10 Thread Eric B.
Indeed, I am running the server in Windows.  I'll take a look at
Troubleshooting 4.4 in depth.

Thanks,

Eric


Mark Matthews [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Eric B. wrote:

  Hi,
 
  I've recently upgraded from 4.0.8a to 4.0.18, and am running into a
 strange
  error in the JDBC connector.  If the DB connection is unused for a
 period of
  time (don't konw the minimum amount of time, but 8-12 hours defintiely
  triggers the problem), I get the following error msg in my stack:
 
  ** BEGIN NESTED EXCEPTION **
 
  java.net.SocketException
  MESSAGE: Software caused connection abort: recv failed
 
  STACKTRACE:
 
  java.net.SocketException: Software caused connection abort: recv failed
   at java.net.SocketInputStream.socketRead0(Native Method)
   at java.net.SocketInputStream.read(SocketInputStream.java:147)
   at java.io.BufferedInputStream.fill(BufferedInputStream.java:183)
   at java.io.BufferedInputStream.read(BufferedInputStream.java:201)
   at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:1399)
   at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:1775)
   at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1020)
   at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1109)
   at com.mysql.jdbc.Connection.execSQL(Connection.java:2030)
   at
 
com.mysql.jdbc.PreparedStatement.executeQuery(PreparedStatement.java:1563)
 
 
 
 From this point on, all connections to the DB fail.  I don't have the
  autoreconnect parameter in the JConnector enabled, but I didn't have it
  enabled in 4.0.8 either.  I haven't changed anything in my code
 either.  It
  uses the java.sql.DriverManager class to do my connection pooling.
 
  Has something changed between 4.0.8 and 4.0.18 that would cause this
  problem?


 Eric,

 Are you running the server on Windows? If so, then yes, something has
 changed. Starting in 4.0.15, network timeouts (including wait_timeout)
 were implemented in the Windows binaries.

 See Connector/J's 'troubleshooting' section in the docs at
 http://www.mysql.com/documentation/connector-j/index.html#id2803835 for
 ways of dealing with this _correctly_ (hint, 'autoReconnect' isn't one
 of them).

 Regards,

 -Mark


 - --
 Mr. Mark Matthews
 MySQL AB, Software Development Manager, J2EE and Windows Platforms
 Office: +1 708 332 0507
 www.mysql.com

 Meet the MySQL Team! April 14-16, 2004 http://www.mysql.com/uc2004/
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.2.3 (MingW32)
 Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

 iD8DBQFATghqtvXNTca6JD8RAs9GAJ4j9P7o2zTUKxqCU2XIuS33vxgfKwCgkuc+
 LyGiyDFR0BthlJXcBv7aRGo=
 =QKF3
 -END PGP SIGNATURE-

 -- 
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]






-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: MySql

2004-03-10 Thread Victoria Reznichenko
kavitha  kutty [EMAIL PROTECTED] wrote:
 I am a student currently doing my final year MCA project.My project is in JSP and
 MySql.I have not studied MySql before.But I got more information about this database 
 from
 MySql.com.But I have a doubt

How many number of tables are possible in one MySql database?

Maximum number of tables depends on your filesystem. But you should not put too many 
tables in a database, as opening tables will slow down.


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Query INTO OUTFILE Problem

2004-03-10 Thread Egor Egorov
Bessares, Bob [EMAIL PROTECTED] wrote:
 Hello MYSQL Genii,
 I am trying to run a query that returns results to a .csv file using mysql's 'INTO 
 OUTFILE'.
 The problem is whenever I write the file I lose my the field names for each 
 column. For example, when I run the query at command line mysql:
 mysql SELECT distinct count(*), Product FROM LIVE WHERE dbStatus =  'Live' and 
 vertical = 'Cars' GROUP BY Product;^MI get this:
 +--+-+^M| count(*) | Product |^M+--+-+^M|4 | 
 BANN|^M|   10 | CRBN|^M|  256 | LEAD|^M|   36 | SALE|^M| 
   26 | TRBN|^M+--+-+^M5 rows in set (0.20 sec)
 
 I want to have the titles of my columns (like above) in my .csv file...
 When I use the 'INTO OUTFILE' syntax I lose all of the titles and just get the data 
 returned like this:
 
 4,BANN^M10,CRBN^M256,LEAD^M36,SALE^M26,TRBN
 Is it possible to use INTO OUTFILE and still get my field names outputted?

No, SELECT INTO OUTFILE doesn't include column names to the file. You should do it by 
yourself.

 Here is the query $var I am using for perl or php.
 $query = SELECT distinct count(*), Product FROM LIVE WHERE dbStatus =  'Live' and 
 vertical = 'Cars' GROUP BY Product INTO OUTFILE 
 '/www/vhosts/someurl.org/htdocs/report_files/apts_mnth_unit.csv' FIELDS TERMINATED 
 BY '\,' OPTIONALLY ENCLOSED BY '\' LINES TERMINATED BY '\n';
 



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: problem with mysqldump, ustf8 with mysql 4.1

2004-03-10 Thread Victoria Reznichenko
neal [EMAIL PROTECTED] wrote:
 I need to backup a mysql 4.1 database with UTF8 characters using InnoDB
 and then restore the backup on another machine

 I tried the following (same machine - Windows XP)
 mysqldump.exe -u root stp2 city  d1.sql# backup
 stp2.city
 mysql.exe -u root t1  d1.sql  #
 restore to t1.city

 The UTF8 data in city.City is garbage after the transfer , it is valid
 Thai language characters in the original.

 CREATE TABLE `city` (
 `city_id` int(11) NOT NULL default '0',
 `City` varchar(25) NOT NULL default '',
 `EngCity` varchar(25) NOT NULL default '',
 PRIMARY KEY  (`city_id`)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;

Use --default-character-set option of mysqldump:
http://www.mysql.com/doc/en/mysqldump.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: mysqldump JOIN?

2004-03-10 Thread Egor Egorov
[EMAIL PROTECTED] wrote:
 I would like to do the following:
 
 mysqldump -w users.user_id=enews.user_id sotx users
 c:/enews_users.sql
 
 Ideally this would dump all records in table users
 where the user_id field value is also present in the
 enews table. Is this possible?

You can't do it only with mysqldump.
If you want dump only data from the users table, what about using SELECT .. INTO 
OUTFILE command?



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Commercial Licence

2004-03-10 Thread Bernard Clement
Dear Pierre,

I would suggest you to contact directly MySQL AB for such a question at 
[EMAIL PROTECTED]

My guess is that you will need to buy a license for the master and the slaves.

Regards,

Bernard

On Wednesday 10 March 2004 03:19, Pierre Luguern wrote:
 I want to run a commercial product based on  MySQL. I have one centralized
 server running MySQL in replication mode (master server). I have five
 clients running MySQL (each slave is running one MySQL daemon).
 Do I have to acquire only one commercial licence for my master server or do
 I have do get commercail licence for master and slave.
 Thanks in advance.





 mailto:[EMAIL PROTECTED]


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



checksum error in innodb - what can do to find the reason ?

2004-03-10 Thread Christian Rabe
Hello together,

I'm getting the following error every few hours. I can force it by 
trying to dump the db.
Even if I drop the named table and create an empty one the error still 
occurs after some time.

I tried both, raw-device and normal. But nothing solves this problem.
The data is stored on a raid and the discs should be faultless.
Running debian sarge with kernel 2.4.25
2x2.4 GHz Xeon
2GB RAM
RAID bus controller: 3ware Inc 3ware 7000-series ATA-RAID (rev 01)

InnoDB: Database page corruption on disk or a failed
InnoDB: file read of page 105283.
InnoDB: You may have to recover from a backup.
040310  1:01:09  InnoDB: Page dump in ascii and hex (16384 bytes):
len 16384; hex 
9f84195800019b4300019a319b550001c8b03f3545bf001a3f5a00d324091f950002000200680
040310  1:01:09  InnoDB: Page checksum 3314471633, prior-to-4.0.14-form 
checksum 2546962952
InnoDB: stored checksum 2676234584, prior-to-4.0.14-form stored checksum 
2546962952
InnoDB: Page lsn 1 3366993717, low 4 bytes of lsn at page end 3366993717
InnoDB: Page may be an index page where index id is 0 22
InnoDB: and table adserver/banner_stats_running index PRIMARY
InnoDB: Database page corruption on disk or a failed
InnoDB: file read of page 105283.
InnoDB: You may have to recover from a backup.
InnoDB: It is also possible that your operating
InnoDB: system has corrupted its own file cache
InnoDB: and rebooting your computer removes the
InnoDB: error.
InnoDB: If the corrupt page is an index page
InnoDB: you can also try to fix the corruption
InnoDB: by dumping, dropping, and reimporting
InnoDB: the corrupt table. You can use CHECK
InnoDB: TABLE to scan your table for corruption.
InnoDB: Look also at section 6.1 of
InnoDB: http://www.innodb.com/ibman.html about
InnoDB: forcing recovery.
InnoDB: Ending processing because of a corrupt database page.
--

mysql show table status like 'banner_stats_running';
+--+++--++-+-+--+---++-+-++++
| Name | Type   | Row_format | Rows | Avg_row_length 
| Data_length | Max_data_length | Index_length | Data_free | 
Auto_increment | Create_time | Update_time | Check_time | Create_options 
| Comment|
+--+++--++-+-+--+---++-+-++++
| banner_stats_running | InnoDB | Fixed  | 11750021 |154 
|  1812987904 |NULL |   3481616384 | 0 |   
NULL | NULL| NULL| NULL   || InnoDB 
free: 43975680 kB; InnoDB free: 15213568 kB |
+--+++--++-+-+--+---++-+-++++
1 row in set (0.52 sec)
Note: the first Innodb-free is from a dump

mysql \s
--
mysql  Ver 12.22 Distrib 4.0.18, for pc-linux (i686)
Connection id:  173011
Current database:
Current user:   [EMAIL PROTECTED]
SSL:Not in use
Current pager:  stdout
Using outfile:  ''
Server version: 4.0.18
Protocol version:   10
Connection: Localhost via UNIX socket
Client characterset:latin1
Server characterset:latin1
UNIX socket:/tmp/mysql.sock
Uptime: 42 min 18 sec
Threads: 23  Questions: 10700857  Slow queries: 0  Opens: 244  Flush 
tables: 1  Open tables: 238  Queries per second avg: 4216.256
--

Any help appreciated :)

Regards,
 Christian Rabe
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Saving file into database

2004-03-10 Thread Paul Rigor
Are you running a web server (or ftp server) as well?  Because if you are, 
then you can upload the files to a separate directory using perl and just 
store the links to that file into a table in your database...

If you're not running a webserver (or ftp)... then lemme konw if you get a 
viable suggestion.

HEre's my 2cents. Since mysql is a relational database, it would be 
difficult to display that particular column/row containing the file (esp, 
binary).  You can use perl (or another converter) to convert the binary 
file into uue (or other text format)... and then import that... make sure 
you remove the linefeeds and store information about the column widths of 
the uue (or other text format) into a table in your database.  but geez, if 
the file is considerably large... like i said, it would put a strain on 
your server. (unless you have GIGS of ram and extra processing spd).

good luck,
paul
At 01:49 AM 3/9/2004, Isa Wolt wrote:
Hi,

I would like to save a binary file into a mysql database, for later being 
able to use the file. I am using a perl interafce. Is this at all possible???

And would it be possible to then read that file from a c++ interface?

would be greatful for any help/advices!

Isa

_
Hitta rätt på nätet med MSN Sök http://search.msn.se/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
_
Paul Rigor
[EMAIL PROTECTED]
Go Bruins! 

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Security

2004-03-10 Thread Ed Curtis

 I guess the easiest way to do this would be to index all transactions
with a user id number or something identifying the user. When they log in
to the site have the scripts only access the records for that person using
a WHERE clause in the queries. You would have to be able to keep track of
their user id for them via cookies or sessions or something though.

Ed Curtis


On Tue, 9 Mar 2004, Mulugeta Maru wrote:

 Thank you for the kind response. May be I did not clearly ask the question.
 The user table in mysql database is used to set-up a user and password. Once
 I set-up my tables (customer, customer orders, customer order details, etc)
 in say abc database what will I have to do to make sure when customer A logs
 in to the database can only see his/her account, orders, order details
 without getting access to other customer accounts.

 I hope my question is clear.

 Maru
 - Original Message -
 From: Paul Rigor [EMAIL PROTECTED]
 To: Mulugeta Maru [EMAIL PROTECTED]; MySQL [EMAIL PROTECTED]
 Sent: Tuesday, March 09, 2004 7:46 PM
 Subject: Re: Security


  Heya,
 
  Those are the default databases that comes with the setup.  the mysql
  database holds info on mysql accounts.  the test is an empty
  database.  You should create a new database CREATE DATABASE customers
  then use customers... after that... you can setup the tables you
 mentioned.
 
  Goodluck!
  Paul
 
  At 06:34 PM 3/9/2004, Mulugeta Maru wrote:
  I have used access in the past and now I have started using MySQL. I have
  customer table, customer order table, customer order detail table. How
  would I make sure that when a particular customer log-in he/she sees only
  the account that is set-up for them. What confused me is that MySQL has a
  database called mysql and a table in this database called users that is
  used to set a user name and password for each user. I could not figure
 out
  how a user in my case a customer that has access to a customer table
 could
  be restricted to see his/her transaction only.
  
  Any insight is very much appreciated.
 
  _
  Paul Rigor
  [EMAIL PROTECTED]
  Go Bruins!
 
 
  --
  MySQL General Mailing List
  For list archives: http://lists.mysql.com/mysql
  To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
 
 


 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



questions mean what?

2004-03-10 Thread Rochester, Dean
does the questions counter equate to the number of queries ran against the
database?  or then number of questions a query may have to ask the database
for one query?

if I do a 
select * from table1;

and table one has 100 records does that equate to 100 questions or one
question?

Dean-O



EMAIL CONFIDENTIALITY NOTICE 
This Email message, and any attachments, may contain confidential 
patient health information that is legally protected.  This information 
is intended only for the use of the individual or entity named above.  
The authorized recipient of this information is prohibited from disclosing 
this information to any other party unless required to do so by law 
or regulation and is required to destroy the information after its stated 
need has been fulfilled.  If you are not the intended recipient, you are 
hereby notified that any disclosure, copying, distribution, or action 
taken in reliance on the contents of this message is strictly prohibited. 
If you have received this information in error, please notify 
the sender immediately by replying to this message and delete the 
message from your system.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Saving file into database

2004-03-10 Thread Kurt Haegeman
Use the BLOB, Luke!

See your local MySQL manual for details.

We're using BLOBs to store PDF in our database, and through the use of 
HTTP headers, we're able to let user download the PDFs without having to 
store a local copy on disk, directly from the database 
(content-disposition header).

Hope this helps.
Kurt Haegeman
Mediargus.com
Paul Rigor wrote:

Are you running a web server (or ftp server) as well?  Because if you 
are, then you can upload the files to a separate directory using perl 
and just store the links to that file into a table in your database...

If you're not running a webserver (or ftp)... then lemme konw if you 
get a viable suggestion.

HEre's my 2cents. Since mysql is a relational database, it would be 
difficult to display that particular column/row containing the file 
(esp, binary).  You can use perl (or another converter) to convert the 
binary file into uue (or other text format)... and then import that... 
make sure you remove the linefeeds and store information about the 
column widths of the uue (or other text format) into a table in your 
database.  but geez, if the file is considerably large... like i said, 
it would put a strain on your server. (unless you have GIGS of ram and 
extra processing spd).

good luck,
paul
At 01:49 AM 3/9/2004, Isa Wolt wrote:

Hi,

I would like to save a binary file into a mysql database, for later 
being able to use the file. I am using a perl interafce. Is this at 
all possible???

And would it be possible to then read that file from a c++ interface?

would be greatful for any help/advices!

Isa

_
Hitta rätt på nätet med MSN Sök http://search.msn.se/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


_
Paul Rigor
[EMAIL PROTECTED]
Go Bruins!


Re: Webobjects and mySQL

2004-03-10 Thread Mark Matthews
James Tichenor said:

 Hello --

 New to mysql and the cocoa development environment. I wonder if anyone
 can point me in the direction of documentation for mysql support for
 webobjects. The webobjects page says that it will support JDBC 2 and 4,
 whereas mysql says it supports JDBC 3? Not sure if I'm reading this
 right and what it means.


I think there's an error in the WebObjects documentation, because there is
no 'JDBC 4' (yet, it's being created as we speak).

In any case, JDBC versions are supposed to be backwards-compatible (i.e.
JDBC 3 drivers will work with applications that only know about JDBC 2).

Regards,

  -Mark


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



ANN: VBMySQLDirect API

2004-03-10 Thread Mike Hillyer
Hi All;

Sorry to repost, but it appears this announcement was dated 2001 and
probably fell through some email systems:



VBMySQL.com is pleased to announce the launch of a new projects page at
http://projects.vbmysql.com.

The first (and flagship) project is VBMySQLDirect. VBMySQLDirect is a
new MySQL C API wrapper written by longtime site contributor Robert Rowe.

VBMySQLDirect is a fork of the MyVbQl API and is available for Visual
Basic developers and all Windows developers who have access to COM objects.

VBMySQLDirect offers improved performance over ODBC, and also offers
improvements over the previous MyVbQl API in terms of better memory
management, BLOB support, and better ADO compatibility. VBMySQLDirect
uses a more recent MySQL API as it's basis as well and therefore
supports more recent functionality than MyVbQl.

VBMySQLDirect is available at http://projects.vbmysql.com/vbmysqldirect

Regards,
Mike Hillyer
www.vbmysql.com



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Load data + odbc

2004-03-10 Thread Stan Sebastian
Please help! :)

I've got 2 workstations and a server on which i have Mysql 3.23.52 - nt.

The clients are build in Visual FoxPro and use MyODBC for connecting to
server.

From both WKS statements like select, insert, update, delete work just fine,
but when i want to 'LOAD DATA local INFILE' it works OK only from one WKS.

I've used also the 'root'  for this and is the same problem.


Thank you!

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Load data + odbc

2004-03-10 Thread Victoria Reznichenko
Stan Sebastian [EMAIL PROTECTED] wrote:
 Please help! :)
 
 I've got 2 workstations and a server on which i have Mysql 3.23.52 - nt.
 
 The clients are build in Visual FoxPro and use MyODBC for connecting to
 server.
 
 From both WKS statements like select, insert, update, delete work just fine,
 but when i want to 'LOAD DATA local INFILE' it works OK only from one WKS.
 
 I've used also the 'root'  for this and is the same problem.
 

What exactly wrong with 'LOAD DATA LOCAL'?
Did you get 'The used command is not allowed with this MySQL version' error? If so, 
you should enable LOAD DATA LOCAL command:
http://www.mysql.com/doc/en/LOAD_DATA_LOCAL.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: InnoDB tables using 90% cpu

2004-03-10 Thread Ken Menzel
Hi Cliff,
   Either way for a production system I recommend using Linuxthreads
with FreeBSD4 (also works on 5 but threads are much improved on 5).
Please use the ports and make WITH_LINUXTHREADS=yes and others that
use (see make pre-fetch in
/usr/ports/databases/mysql-favorite-version)
or
http://jeremy.zawodny.com/blog/archives/000458.html  for Jeremey's
building hints.  I would also examine your innodb configuration and
buffer sizes and isolation level.  These are separate from myisam.

Best of luck,
Ken

- Original Message - 
From: Cliff [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, March 09, 2004 4:56 PM
Subject: Re: InnoDB tables using 90% cpu


 The query is running dramatically slower than the MyISAM query,
sometimes
 even causing mysql to freeze for a while. I searched this list and
found a
 few people saying that on FreeBSD mysql should be compiled using
linux
 pthreads if you are using InnoDB or else I would get this exact
problem. Has
 this been resolved or is should I recompile? I am using native
freebsd
 threads.


 - Original Message - 
 From: Sasha Pachev [EMAIL PROTECTED]
 To: Cliff [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Monday, March 08, 2004 9:18 AM
 Subject: Re: InnoDB tables using 90% cpu


  Cliff wrote:
   Hi, I have a whole database I wanted to convert to InnoDB from
MyISAM,
 but
   do not want to use alter table because of the problems I had
last time.
 I
   made a whole dump of the table using mysqldump and changed all
of the
 table
   create definitions from MyISAM to InnoDB. Theoretically this
should be
 just
   like creating a new innodb table from scratch and inserting new
records.
   However, while the MyISAM tables used ~30% of the cpu usage on a
query,
   InnoDB runs anywhere from 50-90% depending on the query. The
databases
   combined are approximately 200MB. Here is my cnf file:
  
   [mysqld]
   basedir=/mysql
   long_query_time=3
   log-slow-queries=/tmp/slowmysql.log
   innodb_data_home_dir =
   innodb_data_file_path = /mysql/data/innodb_data:300M:autoextend
   set-variable = innodb_buffer_pool_size=300M
   set-variable = innodb_additional_mem_pool_size=20M
   set-variable = innodb_log_file_size=150M
   set-variable = innodb_log_buffer_size=8M
   innodb_flush_log_at_trx_commit=0
  
   This is mysql 4.0.18 on freebsd 4.8-STABLE. We have 1GB of ram
which
 should
   be plenty to run the large queries that we are doing. Thanks in
advance.
 
  50-90% CPU vs only 30% could be actually an improvement ( less
disk I/O,
 and
  relatively more time to get the data). The question is - does the
query
 actually
  take less time? If not, it could be because a certain optimization
 available
  with MyISAM is not available with InnoDB. Isolate the trouble
query, and
 do an
  EXPLAIN.
 
  -- 
  Sasha Pachev
  Create online surveys at http://www.surveyz.com/
 


 -- 
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Webobjects and mySQL

2004-03-10 Thread J Tichenor
Ok, that's what I thought. Standard backwards compatibility - figured 
it had to be that way, since 99.9% of everything else works that way.

Any documentation I might get into describing issues/concerns with 
WebObjects and mySQL?

James

On 10-Mar-04, at 5:29 AM, Mark Matthews wrote:

James Tichenor said:

Hello --

New to mysql and the cocoa development environment. I wonder if anyone
can point me in the direction of documentation for mysql support for
webobjects. The webobjects page says that it will support JDBC 2 and 
4,
whereas mysql says it supports JDBC 3? Not sure if I'm reading this
right and what it means.

I think there's an error in the WebObjects documentation, because 
there is
no 'JDBC 4' (yet, it's being created as we speak).

In any case, JDBC versions are supposed to be backwards-compatible 
(i.e.
JDBC 3 drivers will work with applications that only know about JDBC 
2).

Regards,

  -Mark




--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


mysql_query memory

2004-03-10 Thread Melanie Ware
I am using mysql 4.0.17 on Red Hat Linux.

I am using the C API to access mysql

The application I am writing should parse a xml file and write details to 
the mysql database.

The xml elements as they are read are fed into a simple data structure.  On 
the completion of the structure details the datbase should be checked for a 
prior entry.

This works successfully for the first 3 entries.  The 4th. entry executes 
the SELECT statement but appears to wipe the structure contents

The code is as follows.

select_query = SELECT file_id FROM File WHERE file_name = 'RPCMap.h';

mysql_query (conn, select_query);

I know that the line containing the mysql_query statement destroys the 
struture data content because I have used gdb to print the structure values 
as I step through the code.

Thanks

Melly

_
Use MSN Messenger to send music and pics to your friends 
http://www.msn.co.uk/messenger

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Stored procedure strange behavior?

2004-03-10 Thread Victoria Reznichenko
Philip Markwalder [EMAIL PROTECTED] wrote:
 
 I have a few questions concerning stored procedures:
 
 1. If I create a stored procedure (like the one below), why does the 
 returned values not change, though in the stored prcoedure the id has 
 been generated?
 2. Is there any better way to hand over multiple values and how can I 
 unset global varaibles?
 
 thx
 
 Philip
 
 
 
 delimiter |
 drop procedure if exists create_obj |
 
 CREATE PROCEDURE `create_obj` (
   out success int(2),
   out success_msg varchar(255),
   out obj_id int(10),
   inout obj_hostname varchar(255),
   inout obj_type varchar(25)
   ) LANGUAGE SQL not deterministic
 begin
   declare done int default 0;
   DECLARE CONTINUE HANDLER FOR SQLSTATE '02000' SET done = 1;
   insert into  idsdb.obj values (NULL,obj_hostname,obj_type);
   if ! done then
   select LAST_INSERT_ID() into obj_id;
   set success = 1;
   set success_msg = concat(added host with object id: , obj_id);
   else
   set success = -1;
   set success_msg=Could not insert new object;
   end if;
 end |
 
 call create_obj(@a,@b,@id,'test1','ddd')|
 select @a,@b,@id |
 

LAST_INSERT_ID() returns wrong result inside stored procedure. I entered simple test 
case to the bug database:
http://bugs.mysql.com/bug.php?id=3117

Thanks!


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.com





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Newbie question on Comparing fields in 2 tables?

2004-03-10 Thread Ian Izzard
Hi,
 
I am new to using MySQL and SQL queries.  I have in the past only carried out simple 
queries.  I am trying to write a query for use in our Helpdesk/Audit software.
 
I want to compare the values in one table (Keywords) to the values found in another 
table (Software) so that I can get records of games that are installed on PCs.  The 
Software table is created from an audit run on each PC.  The keywords table is created 
by myself.
 
The keywords table contains 2 fields, ID and Searchname.  A sample of the data in this 
table would be:
 
ID   Searchname
1worm
2kazaa
3delta
4game
 
The software table has 2 fields, pcname and product.  A sample of the data in this 
table would be:
 
pcname product
SW0638CADS Support
SW0638Citrix ICA Client
SW0638Winzip
SW0653Winzip
SW0653Delta Force 2
SW0462Winzip
SW0462Delta Force
SW0462Worms 2000
SW0785Winzip
SW0785Worms2
 
The software table has some 50,000 records in it.  What I am looking to do is to pick 
out the pcname from the software table, where the product field contains the 
searchname from the keywords table.  Something like:
 
select pcname, product from software, keywords where product like searchname
 
I would then expect the results to come out as:
 
pcname product
SW0653Delta Force 2
SW0462Delta Force
SW0462Worms 2000
SW0785Worm2
 
 
I have tried using the LIKE command, but the manuals only show examples when comparing 
a field to a string, ie product LIKE 'worm%'
 
As the keyword table is likely to get quite long (currently 163 records) I don't want 
to do a query using the LIKE command immediately above (, as the query will get very 
long and unmanageable.
 
Can someone help with a solution to this?  Can it be done in a single query?  Is there 
a command that I just haven't yet found?
 
If it is of any help, the version of MySQL being used 4.0.16.  This version is 
installed by the Helpdesk/Audit software, and so cannot be upgraded.
 
Your help is greatly appreciated.
 
Ian Izzard

Visit our web site at www.scottwilson.com

Privilege and Confidentiality Notice.
This e-mail and any attachments to it are intended only for the party
to whom they are addressed.  They may contain privileged and/or
confidential information.  If you have received this transmission in 
error, please notify the sender immediately and delete any digital
copies and destroy any paper copies.
Thank you.


Scott Wilson Kirkpatrick  Co Ltd
Registered in London: No. 880328
Registered office: Scott House, Basing View,
Basingstoke, Hampshire, RG21 4JG. UK.

This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk


what does show status 'questions' refer to?

2004-03-10 Thread Rochester, Dean
in the show status there is a line that says
 Questions  and it shows a number

 The manual says this is the number of questions asked the mysql database.

 what I want to know does one query equal one question or if I did the
select * and it brought back 100 rows... does that equate to 100 questions?

 Trying to get number of hits to the database.

 Maybe there is a better way to get that.

 Dean-O


EMAIL CONFIDENTIALITY NOTICE 
This Email message, and any attachments, may contain confidential 
patient health information that is legally protected.  This information 
is intended only for the use of the individual or entity named above.  
The authorized recipient of this information is prohibited from disclosing 
this information to any other party unless required to do so by law 
or regulation and is required to destroy the information after its stated 
need has been fulfilled.  If you are not the intended recipient, you are 
hereby notified that any disclosure, copying, distribution, or action 
taken in reliance on the contents of this message is strictly prohibited. 
If you have received this information in error, please notify 
the sender immediately by replying to this message and delete the 
message from your system.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: what does show status 'questions' refer to?

2004-03-10 Thread Paul DuBois
At 12:35 -0500 3/10/04, Rochester, Dean wrote:
in the show status there is a line that says
 Questions  and it shows a number
 The manual says this is the number of questions asked the mysql database.

 what I want to know does one query equal one question or if I did the
select * and it brought back 100 rows... does that equate to 100 questions?
It's the number of queries sent to the server, not the number of rows
returned from the server. (That might be better termed answers :-))
 Trying to get number of hits to the database.

 Maybe there is a better way to get that.

 Dean-O


--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: what does show status 'questions' refer to?

2004-03-10 Thread Rhino

- Original Message - 
From: Rochester, Dean [EMAIL PROTECTED]
To: MySQL (E-mail) (E-mail) [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 12:35 PM
Subject: what does show status 'questions' refer to?


 in the show status there is a line that says
  Questions  and it shows a number

  The manual says this is the number of questions asked the mysql database.

  what I want to know does one query equal one question or if I did the
 select * and it brought back 100 rows... does that equate to 100
questions?

I see Paul DuBois has already answered that; he's on the Documentation Team
at MySQL so he's a pretty authoritative source.

  Trying to get number of hits to the database.

  Maybe there is a better way to get that.

I've never seen a database that automatically tracks the number of hits to
the database. That doesn't mean that MySQL doesn't do it - maybe someone
here can answer that with 100% certainty - but I'd be a little surprised if
it did.

You could create your own table of counters but I don't see how you could
reasonably keep it accurate. You could certainly count *application*
accesses by incrementing those counters every time your program hit a given
table but I don't see how you could keep track of command line accesses.
After all, every time someone executes select * from my_table from the
command line, that is a database hit but I don't know of any simple way to
keep track of those hits. Once triggers are added to MySQL you could create
triggers to do this for you automatically with very little effort but that's
probably at least several months away.

Rhino


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Stringing in a table...

2004-03-10 Thread Torrance Hill
I am fairly new to MySQL and I need a little assistance.  In our diff scripts, I need 
the output to string all the mods for a given table together in a single query, which 
will reduce the number of times the larger tables are copied.

So what modifications would I need to make to my diff script to reflect this.  

Any help will do...

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: what does show status 'questions' refer to?

2004-03-10 Thread Paul DuBois
At 13:15 -0500 3/10/04, Rhino wrote:
- Original Message -
From: Rochester, Dean [EMAIL PROTECTED]
To: MySQL (E-mail) (E-mail) [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 12:35 PM
Subject: what does show status 'questions' refer to?

 in the show status there is a line that says
  Questions  and it shows a number
  The manual says this is the number of questions asked the mysql database.

  what I want to know does one query equal one question or if I did the
 select * and it brought back 100 rows... does that equate to 100
questions?

I see Paul DuBois has already answered that; he's on the Documentation Team
at MySQL so he's a pretty authoritative source.
  Trying to get number of hits to the database.

  Maybe there is a better way to get that.

I've never seen a database that automatically tracks the number of hits to
the database. That doesn't mean that MySQL doesn't do it - maybe someone
here can answer that with 100% certainty - but I'd be a little surprised if
it did.
I'm wondering what hits means in the original question.  If it refers
to statements executed, the Questions value may be sufficient.  If it refers
to rows returned by statements, I don't believe there is a way to get that
value.  You can count the results from your own statements, of course, but
if you connect a bunch of times all at once, each connection can count
only its own statement results.  And you cannot count the results from queries
issued by clients that connect using other accounts.
If you're interested in statements executed, broken down by statement type,
try this:
SHOW STATUS LIKE 'Com%';

However, the Com_select value reflects only SELECT statements actually executed
by the server. If the query cache is on, some SELECT statements may be served
directly out of the query cache without the server having to execute them.
You can get the number of such queries like this:
SHOW STATUS LIKE 'Qcache_hits';

--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


RE: what does show status 'questions' refer to?

2004-03-10 Thread Rochester, Dean
Thanks guys... I think questions does it.  I just want to know how many
queries hit the database.  I am getting ready to unleash our company
phonebook, with 10,000 plus listings and just want to make sure that it can
handle it.  I have a jndi connection pool established and have the max used
connections set to 200.  We are in testing mode and we set around 24 max
used connections all the time.  Is the the current number of users on the
database when I did a show status or is that the top number of users on the
database at any given time?  Like  a max indicator since the database was
up.  

What value should I change the default 28800 wait timeout to for
connections?

Do these two values relate?  Max Used Connections and Wait Timeout?

Dean-O


-Original Message-
From: Paul DuBois [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 1:27 PM
To: Rhino; Rochester, Dean; MySQL (E-mail) (E-mail)
Subject: Re: what does show status 'questions' refer to?


At 13:15 -0500 3/10/04, Rhino wrote:
- Original Message -
From: Rochester, Dean [EMAIL PROTECTED]
To: MySQL (E-mail) (E-mail) [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 12:35 PM
Subject: what does show status 'questions' refer to?


  in the show status there is a line that says
   Questions  and it shows a number

   The manual says this is the number of questions asked the mysql
database.

   what I want to know does one query equal one question or if I did the
  select * and it brought back 100 rows... does that equate to 100
questions?

I see Paul DuBois has already answered that; he's on the Documentation Team
at MySQL so he's a pretty authoritative source.

   Trying to get number of hits to the database.

   Maybe there is a better way to get that.

I've never seen a database that automatically tracks the number of hits to
the database. That doesn't mean that MySQL doesn't do it - maybe someone
here can answer that with 100% certainty - but I'd be a little surprised if
it did.

I'm wondering what hits means in the original question.  If it refers
to statements executed, the Questions value may be sufficient.  If it
refers
to rows returned by statements, I don't believe there is a way to get that
value.  You can count the results from your own statements, of course, but
if you connect a bunch of times all at once, each connection can count
only its own statement results.  And you cannot count the results from
queries
issued by clients that connect using other accounts.

If you're interested in statements executed, broken down by statement type,
try this:

SHOW STATUS LIKE 'Com%';

However, the Com_select value reflects only SELECT statements actually
executed
by the server. If the query cache is on, some SELECT statements may be
served
directly out of the query cache without the server having to execute them.
You can get the number of such queries like this:

SHOW STATUS LIKE 'Qcache_hits';

-- 
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com

MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/


EMAIL CONFIDENTIALITY NOTICE 
This Email message, and any attachments, may contain confidential 
patient health information that is legally protected.  This information 
is intended only for the use of the individual or entity named above.  
The authorized recipient of this information is prohibited from disclosing 
this information to any other party unless required to do so by law 
or regulation and is required to destroy the information after its stated 
need has been fulfilled.  If you are not the intended recipient, you are 
hereby notified that any disclosure, copying, distribution, or action 
taken in reliance on the contents of this message is strictly prohibited. 
If you have received this information in error, please notify 
the sender immediately by replying to this message and delete the 
message from your system.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: what does show status 'questions' refer to?

2004-03-10 Thread Paul DuBois
At 13:35 -0500 3/10/04, Rochester, Dean wrote:
Thanks guys... I think questions does it.  I just want to know how many
queries hit the database.  I am getting ready to unleash our company
phonebook, with 10,000 plus listings and just want to make sure that it can
handle it.  I have a jndi connection pool established and have the max used
connections set to 200.  We are in testing mode and we set around 24 max
used connections all the time.  Is the the current number of users on the
database when I did a show status or is that the top number of users on the
database at any given time?  Like  a max indicator since the database was
up.
I admit that I don't actually understand what you're asking here, because
you're referring to the SHOW STATUS statement, but referring to variables
with descriptive terms rather than the actual variable names.  I will
guess that you mean Max_used_connections, which is the maximum number
of clients that have been simultaneously connected since the server started.
If you want the number that are connected *now*, then you want to look
at Threads_connected.
http://www.mysql.com/doc/en/SHOW_STATUS.html

What value should I change the default 28800 wait timeout to for
connections?
Why do you think you should change it?

Do these two values relate?  Max Used Connections and Wait Timeout?
If I understand you correctly, no.

Dean-O


--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


RE: what does show status 'questions' refer to?

2004-03-10 Thread Paul DuBois
At 13:50 -0500 3/10/04, Rochester, Dean wrote:
Does max used connections value ever go down?  Or is this a high water mark
on the server... stating that since the server has been up, at one time you
had this many users connected at a given time.
It's a high water mark.  It'll be reset to zero when you restart the
server, or when you issue a FLUSH STATUS statement or execute
mysqladmin flush-status.


-Original Message-
From: Paul DuBois [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 1:45 PM
To: Rochester, Dean; Rhino; MySQL (E-mail) (E-mail)
Subject: RE: what does show status 'questions' refer to?
At 13:35 -0500 3/10/04, Rochester, Dean wrote:
Thanks guys... I think questions does it.  I just want to know how many
queries hit the database.  I am getting ready to unleash our company
phonebook, with 10,000 plus listings and just want to make sure that it can
handle it.  I have a jndi connection pool established and have the max used
connections set to 200.  We are in testing mode and we set around 24 max
used connections all the time.  Is the the current number of users on the
database when I did a show status or is that the top number of users on the
database at any given time?  Like  a max indicator since the database was
up.
I admit that I don't actually understand what you're asking here, because
you're referring to the SHOW STATUS statement, but referring to variables
with descriptive terms rather than the actual variable names.  I will
guess that you mean Max_used_connections, which is the maximum number
of clients that have been simultaneously connected since the server started.
If you want the number that are connected *now*, then you want to look
at Threads_connected.
http://www.mysql.com/doc/en/SHOW_STATUS.html

What value should I change the default 28800 wait timeout to for
connections?
Why do you think you should change it?

Do these two values relate?  Max Used Connections and Wait Timeout?
If I understand you correctly, no.


 Dean-O


--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


MySQL and NFS

2004-03-10 Thread Tucker, Gabriel
Hi All

I have read through some previous threads on this topic and I was unable to find any 
to answer my question...

Can I install MySQL on a NFS mount and use its executables on multiple machines 
simultaneously?  The data will be NOT be on a NFS mount, just the install.

Thanks
Gabe

*

The jokes on him, I'll be dead by then - HJS

Gabe Tucker
Bloomberg LP
P 609 750 6668
F 646 268 5681

*


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: MySQL and NFS

2004-03-10 Thread Victor Medina
HI!

yes you can! as long as the data is no on a nfs volume go ahead! =)

Best Regards!
On Wed, 2004-03-10 at 15:16, Tucker, Gabriel wrote:

 Hi All
 
 I have read through some previous threads on this topic and I was unable to find any 
 to answer my question...
 
 Can I install MySQL on a NFS mount and use its executables on multiple machines 
 simultaneously?  The data will be NOT be on a NFS mount, just the install.
 
 Thanks
 Gabe
 
 *
 
 The jokes on him, I'll be dead by then - HJS
 
 Gabe Tucker
 Bloomberg LP
 P 609 750 6668
 F 646 268 5681
 
 *

-- 

 |...|
 |  _    _|Victor Medina M   |
 |\ \ \| |  _ \ / \   |Linux - Java - MySQL  |
 | \ \ \  _| | |_) / _ \  |Dpto. Sistemas - Ferreteria EPA   |
 | / / / |___|  __/ ___ \ |[EMAIL PROTECTED]  |
 |/_/_/|_|_| /_/   \_\|ext. 325 - Tél: +58-241-8507325   |
 ||geek by nature - linux by choice  |
 |...|






















Re: Pricelist

2004-03-10 Thread Sturgeon, Jon
Sasha Pachev wrote:

 This so-called moron is Miguel Soloranzo - the guy in charge of
 MySQL Wind ows
 builds. So blocking his posts to the list would be a bad idea.

 The problem is that somebody got infected with a virus that picked up
 his address, as well as the address of the list, and keeps posting
 viruses in hi s name.

Yes I know.  I was referring to the moron that is infected.  As we all know,
these viruses fake the from addresses, I didn't think that needed pointing
out.  But the list administrator can figure out who the real subscriber is
by looking at the headers.  Or at least configure the list so that it
doesn't permit attachments...a mailing list that allows attachments these
days is bordering on recklessness, IMHO.

Jon


-- 
--
FutureSoft, Inc.
12012 Wickchester Lane, Suite 600
Houston, TX 77079
If you no longer want to receive commercial e-mail correspondence
from FutureSoft, you may remove your address from our records 
by visiting www.futuresoft.com/emailremoval.asp
--

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Newbie question on Comparing fields in 2 tables?

2004-03-10 Thread Rocar Peças
Mr. Izzard,

We have these tables:

Table software
- pcname char(..)
- product char(..)

Table keywords
- id int(..)
- seachname char(...)

and you want to pick out the pcname from the software table, where the
product field contains the searchname from the keywords table

Try this and you´ll succeed:
==
SELECT
software.pcname,
software.product

FROM
software, keywords

WHERE
software.product LIKE CONCAT(%, keywords.searchname, %)
==

Best wishes,

Leandro M Neves,
ROCAR PEÇAS LTD.
Sete Lagoas/MG - Brazil

- Original Message - 
From: Ian Izzard [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 2:05 PM
Subject: Newbie question on Comparing fields in 2 tables?


Hi,

I am new to using MySQL and SQL queries.  I have in the past only carried
out simple queries.  I am trying to write a query for use in our
Helpdesk/Audit software.

I want to compare the values in one table (Keywords) to the values found in
another table (Software) so that I can get records of games that are
installed on PCs.  The Software table is created from an audit run on each
PC.  The keywords table is created by myself.

The keywords table contains 2 fields, ID and Searchname.  A sample of the
data in this table would be:

ID   Searchname
1worm
2kazaa
3delta
4game

The software table has 2 fields, pcname and product.  A sample of the data
in this table would be:

pcname product
SW0638CADS Support
SW0638Citrix ICA Client
SW0638Winzip
SW0653Winzip
SW0653Delta Force 2
SW0462Winzip
SW0462Delta Force
SW0462Worms 2000
SW0785Winzip
SW0785Worms2

The software table has some 50,000 records in it.  What I am looking to do
is to pick out the pcname from the software table, where the product field
contains the searchname from the keywords table.  Something like:

select pcname, product from software, keywords where product like searchname

I would then expect the results to come out as:

pcname product
SW0653Delta Force 2
SW0462Delta Force
SW0462Worms 2000
SW0785Worm2


I have tried using the LIKE command, but the manuals only show examples when
comparing a field to a string, ie product LIKE 'worm%'

As the keyword table is likely to get quite long (currently 163 records) I
don't want to do a query using the LIKE command immediately above (, as the
query will get very long and unmanageable.

Can someone help with a solution to this?  Can it be done in a single query?
Is there a command that I just haven't yet found?

If it is of any help, the version of MySQL being used 4.0.16.  This version
is installed by the Helpdesk/Audit software, and so cannot be upgraded.

Your help is greatly appreciated.

Ian Izzard

Visit our web site at www.scottwilson.com

Privilege and Confidentiality Notice.
This e-mail and any attachments to it are intended only for the party
to whom they are addressed.  They may contain privileged and/or
confidential information.  If you have received this transmission in
error, please notify the sender immediately and delete any digital
copies and destroy any paper copies.
Thank you.


Scott Wilson Kirkpatrick  Co Ltd
Registered in London: No. 880328
Registered office: Scott House, Basing View,
Basingstoke, Hampshire, RG21 4JG. UK.

This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Commercial Licence

2004-03-10 Thread Stephen Brownlow
If those servers are yours, it sounds to me that you can run it GPL.

Read this:
http://www.mysql.com/doc/en/Using_the_MySQL_software_for_free_under_GPL.html

Stephen

- Original Message - 
From: Pierre Luguern [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 7:19 PM
Subject: Commercial Licence


 I want to run a commercial product based on  MySQL. I have one centralized
 server running MySQL in replication mode (master server). I have five
 clients running MySQL (each slave is running one MySQL daemon).
 Do I have to acquire only one commercial licence for my master server or
do
 I have do get commercail licence for master and slave.
 Thanks in advance.





 mailto:[EMAIL PROTECTED]








 -- 
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Span a database transaction across multiple CGI scripts

2004-03-10 Thread Joshua J. Kugler
The short answer is no, not using MySQL built in transaction system.  What I 
do for things like this is add a field to the table that indicates whether or 
not the record is locked.  It is usually a  Tiny Int that I just set to 1 or 
0.

Hope that helps.

j- k-

On Tuesday 09 March 2004 06:24 am, Sagara Wijetunga wrote:
 Hi all

 Is it possible to span a database transaction across
 multiple CGI scripts? That is, start transaction and
 lock some records in one CGI script and update and
 commit in another CGI script.

 Here is an example: I have a accounts database. Only
 one user should edit a given account at any given
 time. Once an account is open for editing, it should
 be locked so that other users cannot open in edit
 mode. Multiple users should be able to edit different
 accounts.

 The list.cgi lists accounts. Once click on an account,
 the edit.cgi reads account info and display in an
 editable form. This is where I need to lock the
 account. After editing is completed, user clicks on
 the Update button and data transfer to process.cgi.
 After the account is updated, I issue commit and
 release record locks.

 I use MySQL 4.x and Perl. Could my requirement be
 implemented in MySQL? Could somebody please at least
 give me a hint how to implement this?

 Many thanks in advance.

 Regards
 Sagara


 __
 Do you Yahoo!?
 Yahoo! Search - Find what you’re looking for faster
 http://search.yahoo.com

-- 
Joshua J. Kugler
Fairbanks, Alaska
Computer Consultant--Systems Designer
.--- --- ...  ..- .--.- ..- --. .-.. . .-.
[EMAIL PROTECTED]
ICQ#:13706295
Every knee shall bow, and every tongue confess, in heaven, on earth, and under 
the earth, that Jesus Christ is LORD -- Count on it!


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



@@identity

2004-03-10 Thread Aaron
How can I select the last record that was inserted? An ASP/VB example would
be great too!


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Serveral mysqld instances

2004-03-10 Thread Rocar Peças
Hi, Folks!

I get a MySQL 4.0.18 server running on a Conectiva Linux Kernel 2.4.5.

The MySQL server supports datum for a C apliccation which everybody in the company 
uses.

The problem is that huge mysqld processes come up as people loads their programs, 
which connect to the mysql server.

Each mysqld quickly gets 80MB large in RAM, and the number of mysqld usually reaches 
80, so my 1GB RAM server gets out of memory early in the morning.

What is happening? Isn´t mysqld supposed to have only one instance running on kernel?

Thanks.

Leandro M Neves,
ROCAR PEÇAS LTD
Sete Lagoas/MG - Brazil


Rocar Peças Ltda.

Re: @@identity

2004-03-10 Thread Daniel Kasak




Aaron wrote:

  How can I select the last record that was inserted? An ASP/VB example would
be great too!
  

I believe you have it already.
I use:

select last_insert_id() as MyID

but from memory @@identity is a synonym of last_insert_id()

Dan

-- 

sig
Daniel Kasak

IT Developer

NUS Consulting Group
Level 5, 77 Pacific Highway
North Sydney, NSW, Australia 2060

T: (+61) 2 9922-7676 / F: (+61) 2 9922 7989

email: [EMAIL PROTECTED]

website: http://www.nusconsulting.com.au



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: @@identity

2004-03-10 Thread Rocar Peças
My Aaron,

I don´t  know any means to get the last inserted record into a MySQL table,
as built-in command.

What I would do to get this record is  to have a timestamp field in the
record (mmddmilisecsinday) to solve the problem.

That´s it.

Leandro Neves.
- Original Message - 
From: Aaron [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 7:04 PM
Subject: @@identity


 How can I select the last record that was inserted? An ASP/VB example
would
 be great too!


 -- 
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Mysql timed actions... Confused

2004-03-10 Thread Joshua J. Kugler
Judging from the times on the clock (03:00 to 07:00) I would guess that the 
server on which MySQL is running is doing some scheduled activity.  Cron jobs 
for backup, slocate updates, security checks, etc.  MySQL doesn't do 
scheduled maintenance, especially not for four hours.

j- k-

On Tuesday 09 March 2004 01:49 pm, Scott Haneda wrote:
 Here is a log of query times I made when a certain page is loaded that uses
 php and mysql, does mysql 4 do some sort of scheduled maintenance I am not
 aware of?

SNIP
 2004/03/09 02:00:00OK, 77585 bytes1 seconds
 2004/03/09 02:05:01OK, 77591 bytes24 seconds
 2004/03/09 02:10:00OK, 77591 bytes23 seconds
 2004/03/09 02:15:00OK, 77585 bytes32 seconds
 2004/03/09 02:20:00OK, 77591 bytes26 seconds
 2004/03/09 02:25:00OK, 77591 bytes25 seconds
 2004/03/09 02:30:00OK, 77579 bytes27 seconds
 2004/03/09 02:35:00OK, 77585 bytes26 seconds
 2004/03/09 02:40:00OK, 77585 bytes27 seconds
 2004/03/09 02:45:00OK, 77572 bytes28 seconds
 2004/03/09 02:50:00OK, 77578 bytes26 seconds
 2004/03/09 02:55:00OK, 77578 bytes26 seconds
 2004/03/09 03:00:00OK, 77572 bytes26 seconds
 2004/03/09 03:05:00OK, 77578 bytes26 seconds
 2004/03/09 03:10:00OK, 77572 bytes28 seconds
 2004/03/09 03:15:00OK, 77572 bytes29 seconds
 2004/03/09 03:20:00OK, 77572 bytes33 seconds
 2004/03/09 03:25:00OK, 77572 bytes64 seconds
 2004/03/09 03:30:01OK, 77532 bytes27 seconds
 2004/03/09 03:35:01OK, 77526 bytes25 seconds
 2004/03/09 03:40:01OK, 77532 bytes114 seconds
 2004/03/09 03:45:01OK, 77532 bytes27 seconds
 2004/03/09 03:50:00OK, 77526 bytes79 seconds
 2004/03/09 03:55:00OK, 77532 bytes26 seconds
 2004/03/09 04:00:01OK, 77532 bytes27 seconds
 2004/03/09 04:05:00OK, 77526 bytes26 seconds
 2004/03/09 04:10:00OK, 77526 bytes26 seconds
 2004/03/09 04:15:00OK, 77526 bytes26 seconds
 2004/03/09 04:20:00OK, 77532 bytes33 seconds
 2004/03/09 04:25:00OK, 77532 bytes26 seconds
 2004/03/09 04:30:01OK, 77526 bytes167 seconds
 2004/03/09 04:35:01OK, 77532 bytes26 seconds
 2004/03/09 04:40:00OK, 77526 bytes29 seconds
 2004/03/09 04:45:00OK, 77532 bytes28 seconds
 2004/03/09 04:50:00OK, 77526 bytes26 seconds
 2004/03/09 04:55:01OK, 77526 bytes25 seconds
 2004/03/09 05:00:00OK, 77532 bytes28 seconds
 2004/03/09 05:05:00OK, 77526 bytes28 seconds
 2004/03/09 05:10:00OK, 77526 bytes27 seconds
 2004/03/09 05:15:00OK, 77526 bytes28 seconds
 2004/03/09 05:20:00OK, 77532 bytes26 seconds
 2004/03/09 05:25:01OK, 77526 bytes27 seconds
 2004/03/09 05:30:00OK, 77532 bytes27 seconds
 2004/03/09 05:35:01OK, 77526 bytes25 seconds
 2004/03/09 05:40:00OK, 77526 bytes26 seconds
 2004/03/09 05:45:01OK, 77526 bytes26 seconds
 2004/03/09 05:50:01OK, 77526 bytes26 seconds
 2004/03/09 05:55:00OK, 77526 bytes28 seconds
 2004/03/09 06:00:01OK, 77532 bytes27 seconds
 2004/03/09 06:05:01OK, 77526 bytes28 seconds
 2004/03/09 06:10:00OK, 77532 bytes30 seconds
 2004/03/09 06:15:00OK, 77532 bytes30 seconds
 2004/03/09 06:20:01OK, 77532 bytes27 seconds
 2004/03/09 06:25:00OK, 77526 bytes27 seconds
 2004/03/09 06:30:00OK, 77526 bytes27 seconds
 2004/03/09 06:35:00OK, 77526 bytes31 seconds
 2004/03/09 06:40:00OK, 77532 bytes27 seconds
 2004/03/09 06:45:00OK, 77526 bytes26 seconds
 2004/03/09 06:50:01OK, 77526 bytes29 seconds
 2004/03/09 06:55:00OK, 77526 bytes28 seconds
 2004/03/09 07:00:00OK, 77532 bytes28 seconds
 2004/03/09 07:05:00OK, 77526 bytes1 seconds

-- 
Joshua J. Kugler
Fairbanks, Alaska
Computer Consultant--Systems Designer
.--- --- ...  ..- .--.- ..- --. .-.. . .-.
[EMAIL PROTECTED]
ICQ#:13706295
Every knee shall bow, and every tongue confess, in heaven, on earth, and under 
the earth, that Jesus Christ is LORD -- Count on it!


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Security

2004-03-10 Thread Joshua J. Kugler
Only being able to see certain rows is not a function of MySQL, it is a 
function of the application you write for the user to access the database.  
If a user has permission to read a table, they can read all rows.  It is up 
to your application to make sure they are only seeing rows that apply to 
them.

j- k-

On Tuesday 09 March 2004 05:57 pm, Mulugeta Maru wrote:
 Thank you for the kind response. May be I did not clearly ask the question.
 The user table in mysql database is used to set-up a user and password.
 Once I set-up my tables (customer, customer orders, customer order details,
 etc) in say abc database what will I have to do to make sure when customer
 A logs in to the database can only see his/her account, orders, order
 details without getting access to other customer accounts.

-- 
Joshua J. Kugler
Fairbanks, Alaska
Computer Consultant--Systems Designer
.--- --- ...  ..- .--.- ..- --. .-.. . .-.
[EMAIL PROTECTED]
ICQ#:13706295
Every knee shall bow, and every tongue confess, in heaven, on earth, and under 
the earth, that Jesus Christ is LORD -- Count on it!


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: @@identity

2004-03-10 Thread Victor Pendleton
Rough example. Assuming that you are using the same connection since
last_insert_id() is connection specific.

rset.open INSERT INTO table1 values(someValue) 
rset.open SELECT last_insert_id() as identity
identity = rset.fields(identity)


-Original Message-
From: Aaron
To: [EMAIL PROTECTED]
Sent: 3/10/04 4:04 PM
Subject: @@identity

How can I select the last record that was inserted? An ASP/VB example
would
be great too!


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: 3 000 000 requests for last 14 days...

2004-03-10 Thread Matt W
Hi Patrick,

No, you can't get per database statistics in MySQL. :-(


Matt


- Original Message -
From: Patrick Gelin
Sent: Wednesday, March 10, 2004 1:45 AM
Subject: 3 000 000 requests for last 14 days...


 Hi,

 I've got very astonished to see with phpMyAdmin my MySQL database has
 received more than 3 Millions conexions for this last 14 days. But I
don't
 knowwhich database is reponsable for this. Is there a mean to know
 connexion rate per database ?

 Thanks.


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Serveral mysqld instances

2004-03-10 Thread Victor Pendleton
Are you looking at ps -aux | grep mysql (or some variant) to determine this?


-Original Message-
From: Rocar Peças
To: [EMAIL PROTECTED]
Sent: 3/10/04 4:19 PM
Subject: Serveral mysqld instances

Hi, Folks!

I get a MySQL 4.0.18 server running on a Conectiva Linux Kernel 2.4.5.

The MySQL server supports datum for a C apliccation which everybody in
the company uses.

The problem is that huge mysqld processes come up as people loads their
programs, which connect to the mysql server.

Each mysqld quickly gets 80MB large in RAM, and the number of mysqld
usually reaches 80, so my 1GB RAM server gets out of memory early in the
morning.

What is happening? Isn´t mysqld supposed to have only one instance
running on kernel?

Thanks.

Leandro M Neves,
ROCAR PEÇAS LTD
Sete Lagoas/MG - Brazil


Rocar Peças Ltda.

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: @@identity

2004-03-10 Thread Aaron
Great - thanks! 

-Original Message-
From: Victor Pendleton [mailto:[EMAIL PROTECTED] 
Sent: March 10, 2004 5:36 PM
To: 'Aaron '; '[EMAIL PROTECTED] '
Subject: RE: @@identity

Rough example. Assuming that you are using the same connection since
last_insert_id() is connection specific.

rset.open INSERT INTO table1 values(someValue) 
rset.open SELECT last_insert_id() as identity
identity = rset.fields(identity)


-Original Message-
From: Aaron
To: [EMAIL PROTECTED]
Sent: 3/10/04 4:04 PM
Subject: @@identity

How can I select the last record that was inserted? An ASP/VB example would
be great too!


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Security

2004-03-10 Thread Maru, Mulugeta
When I go online to access my bank account I only see transactions pertain to my 
account only. I think when ever I make a transaction the database records my account 
number in the transaction table. When I log-in using my account number and password 
the system checks whether it is correct or not and run another query to get all 
transaction that match my account number. 

Do I make sense?

-Original Message-
From: Joshua J. Kugler [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 5:34 PM
To: Mulugeta Maru; MySQL
Subject: Re: Security


Only being able to see certain rows is not a function of MySQL, it is a 
function of the application you write for the user to access the database.  
If a user has permission to read a table, they can read all rows.  It is up 
to your application to make sure they are only seeing rows that apply to 
them.

j- k-

On Tuesday 09 March 2004 05:57 pm, Mulugeta Maru wrote:
 Thank you for the kind response. May be I did not clearly ask the question.
 The user table in mysql database is used to set-up a user and password.
 Once I set-up my tables (customer, customer orders, customer order details,
 etc) in say abc database what will I have to do to make sure when customer
 A logs in to the database can only see his/her account, orders, order
 details without getting access to other customer accounts.

-- 
Joshua J. Kugler
Fairbanks, Alaska
Computer Consultant--Systems Designer
.--- --- ...  ..- .--.- ..- --. .-.. . .-.
[EMAIL PROTECTED]
ICQ#:13706295
Every knee shall bow, and every tongue confess, in heaven, on earth, and under 
the earth, that Jesus Christ is LORD -- Count on it!


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

VisionTV proudly celebrates 15 years as Canada's multi-faith television network.

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Security

2004-03-10 Thread Mike Johnson
From: Maru, Mulugeta [mailto:[EMAIL PROTECTED]

 When I go online to access my bank account I only see 
 transactions pertain to my account only. I think when ever I 
 make a transaction the database records my account number in 
 the transaction table. When I log-in using my account number 
 and password the system checks whether it is correct or not 
 and run another query to get all transaction that match my 
 account number. 
 
 Do I make sense?


(sent offlist by mistake, please excuse the dupe)

The point being made is that you're looking at your bank account information in a 
client that is set to read records only pertaining to your account.

The native mysql client is not such a program and was never intended to be. While you 
can customize access for users to certain databases or certain tables within those 
databases, it's simply not built as a multi-user transactional client for limiting 
access to data in commonly-used tables.

It begs the question why you're giving your clients access to the native mysql client 
itself rather than developing an application to do this, in which you could quite 
easily limit such access.


-- 
Mike Johnson
Web Developer
Smarter Living, Inc.
phone (617) 886-5539

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Database crash, lock held too long

2004-03-10 Thread ZenShadow
Folks,

We've been running a fairly  high-traffic mysql server for some time,
and we've been occasionally seeing messages like this in the logs:

InnoDB: Error: semaphore wait has lasted  600 seconds
InnoDB: We intentionally crash the server, because it appears to be
hung.
040309 18:20:36  InnoDB: Assertion failure in thread 2623773248 in file
sync0arr.c line 934
InnoDB: Failing assertion: 0
InnoDB: We intentionally generate a memory trap.
InnoDB: Send a detailed bug report to [EMAIL PROTECTED]

This is a fairly critical issue for us (the latest crash borked
replication, which is never fun), so if anyone has an answer it would be
most appreciated.  I've attached the full relevant log snippet and the
my.cnf for anyone who's willing to take a look.

I'd provide more information, but it has so far been impossible to tell
what's causing it.  This server averages 2000 queries per second (25%
of which is inserts and updates, I'd guess), and is also the replication
master for another database.  It seems to be random so far.

This system is running on a dual Xeon (2.4GHz + hyperthread) with 4GB of
memory, Two U160 SCSI arrays (configured for 1TB @ RAID1+0), and the
stock RedHat 2.4.20-8smp kernel (the box is pretty much a stock RedHat 9
install).

Again, any insight would be most appreciated.

--ZS

%---[ Cut Here for my.cnf ]%-

[client]
port= 3306
socket  = /tmp/mysql.sock


[mysqld]
port= 3306
socket  = /tmp/mysql.sock
skip-locking
key_buffer = 1024M
max_allowed_packet = 16M
table_cache = 512
sort_buffer_size = 256M
read_buffer_size = 256M
myisam_sort_buffer_size = 64M
thread_cache = 8
query_cache_size = 128M
thread_concurrency = 8
max_connections = 1000
interactive_timeout = 1800
wait_timeout = 1800
server-id   = 1
log-bin
tmpdir  = /tmp/ 
innodb_data_home_dir = /usr/local/mysql/var/

# 1560GB of DB tablespace
innodb_data_file_path =
aa:1G;i2/ab:1G;ac:1G;i2/ad:1G;ae:1G;i2/af:1G;ag:1G;i2/ah:1G;ai:1G;i2/aj:1G;ak:1G;i2/al:1G;am:1G;i2/an:1G;ao:1G;i2/ap:1G;aq:1G;i2/ar:1G;as:1G;i2/at:1G;au:1G;i2/av:1G;aw:1G;i2/ax:1G;ay:1G;i2/az:1G;aA:1G;i2/aB:1G;aC:1G;i2/aD:1G;aE:1G;i2/aF:1G;aG:1G;i2/aH:1G;aI:1G;i2/aJ:1G;aK:1G;i2/aL:1G;aM:1G;i2/aN:1G;aO:1G;i2/aP:1G;aQ:1G;i2/aR:1G;aS:1G;i2/aT:1G;aU:1G;i2/aV:1G;aW:1G;i2/aX:1G;aY:1G;i2/aZ:1G;a0:1G;i2/a1:1G;a2:1G;i2/a3:1G;a4:1G;i2/a5:1G;a6:1G;i2/a7:1G;a8:1G;i2/a9:1G;ba:1G;i2/bb:1G;bc:1G;i2/bd:1G;be:1G;i2/bf:1G;bg:1G;i2/bh:1G;bi:1G;i2/bj:1G;bk:1G;i2/bl:1G;bm:1G;i2/bn:1G;bo:1G;i2/bp:1G;bq:1G;i2/br:1G;bs:1G;i2/bt:1G;bu:1G;i2/bv:1G;bw:1G;i2/bx:1G;by:1G;i2/bz:1G;bA:1G;i2/bB:1G;bC:1G;i2/bD:1G;bE:1G;i2/bF:1G;bG:1G;i2/bH:1G;bI:1G;i2/bJ:1G;bK:1G;i2/bL:1G;bM:1G;i2/bN:1G;bO:1G;i2/bP:1G;bQ:1G;i2/bR:1G;bS:1G;i2/bT:1G;bU:1G;i2/bV:1G;bW:1G;i2/bX:1G;bY:1G;i2/bZ:1G;b0:1G;i2/b1:1G;b2:1G;i2/b3:1G;b4:1G;i2/b5:1G;b6:1G;i2/b7:1G;b8:1G;i2/b9:1G;ca:1G;i2/cb:1G;cc:1G;i2/cd:1G;ce:1G;i2/cf:1G;cg:1G;i2/ch:1G;ci:1G;i2/cj:1G;ck:1G;i2/cl:1G;cm:1G;i2/cn:1G;co:1G;i2/cp:1G;cq:1G;i2/cr:1G;cs:1G;i2/ct:1G;cu:1G;i2/cv:1G;cw:1G;i2/cx:1G;cy:1G;i2/cz:1G;cA:1G;i2/cB:1G;cC:1G;i2/cD:1G;cE:1G;i2/cF:1G;cG:1G;i2/cH:1G;cI:1G;i2/cJ:1G;cK:1G;i2/cL:1G;cM:1G;i2/cN:1G;cO:1G;i2/cP:1G;cQ:1G;i2/cR:1G;cS:1G;i2/cT:1G;cU:1G;i2/cV:1G;cW:1G;i2/cX:1G;cY:1G;i2/cZ:1G;c0:1G;i2/c1:1G;c2:1G;i2/c3:1G;c4:1G;i2/c5:1G;c6:1G;i2/c7:1G;c8:1G;i2/c9:1G;da:1G;i2/db:1G;dc:1G;i2/dd:1G;de:1G;i2/df:1G;dg:1G;i2/dh:1G;di:1G;i2/dj:1G;dk:1G;i2/dl:1G;dm:1G;i2/dn:1G;do:1G;i2/dp:1G;dq:1G;i2/dr:1G;ds:1G;i2/dt:1G;du:1G;i2/dv:1G;dw:1G;i2/dx:1G;dy:1G;i2/dz:1G;dA:1G;i2/dB:1G;dC:1G;i2/dD:1G;dE:1G;i2/dF:1G;dG:1G;i2/dH:1G;dI:1G;i2/dJ:1G;dK:1G;i2/dL:1G;dM:1G;i2/dN:1G;dO:1G;i2/dP:1G;dQ:1G;i2/dR:1G;dS:1G;i2/dT:1G;dU:1G;i2/dV:1G;dW:1G;i2/dX:1G;dY:1G;i2/dZ:1G;d0:1G;i2/d1:1G;d2:1G;i2/d3:1G;d4:1G;i2/d5:1G;d6:1G;i2/d7:1G;d8:1G;i2/d9:1G;ea:1G;i2/eb:1G;ec:1G;i2/ed:1G;ee:1G;i2/ef:1G;eg:1G;i2/eh:1G;ei:1G;i2/ej:1G;ek:1G;i2/el:1G;em:1G;i2/en:1G;eo:1G;i2/ep:1G;eq:1G;i2/er:1G;es:1G;i2/et:1G;eu:1G;i2/ev:1G;ew:1G;i2/ex:1G;ey:1G;i2/ez:1G;eA:1G;i2/eB:1G;eC:1G;i2/eD:1G;eE:1G;i2/eF:1G;eG:1G;i2/eH:1G;eI:1G;i2/eJ:1G;eK:1G;i2/eL:1G;eM:1G;i2/eN:1G;eO:1G;i2/eP:1G;eQ:1G;i2/eR:1G;eS:1G;i2/eT:1G;eU:1G;i2/eV:1G;eW:1G;i2/eX:1G;eY:1G;i2/eZ:1G;e0:1G;i2/e1:1G;e2:1G;i2/e3:1G;e4:1G;i2/e5:1G;e6:1G;i2/e7:1G;e8:1G;i2/e9:1G;fa:1G;i2/fb:1G;fc:1G;i2/fd:1G;fe:1G;i2/ff:1G;fg:1G;i2/fh:1G;fi:1G;i2/fj:1G;fk:1G;i2/fl:1G;fm:1G;i2/fn:1G;fo:1G;i2/fp:1G;fq:1G;i2/fr:1G;fs:1G;i2/ft:1G;fu:1G;i2/fv:1G;fw:1G;i2/fx:1G;fy:1G;i2/fz:1G;fA:1G;i2/fB:1G;fC:1G;i2/fD:1G;fE:1G;i2/fF:1G;fG:1G;i2/fH:1G;fI:1G;i2/fJ:1G;fK:1G;i2/fL:1G;fM:1G;i2/fN:1G;fO:1G;i2/fP:1G;fQ:1G;i2/fR:1G;fS:1G;i2/fT:1G;fU:1G;i2/fV:1G;fW:1G;i2/fX:1G;fY:1G;i2/fZ:1G;f0:1G;i2/f1:1G;f2:1G;i2/f3:1G;f4:1G;i2/f5:1G;f6:1G;i2/f7:1G;f8:1G;i2/f9:1G;ga:1G;i2/gb:1G;gc:1G;i2/gd:1G;ge:1G;i2/gf:1G;gg:1G;i2/gh:1G;gi:1G;i2/gj:1G;gk:1G;i2/gl:1G;gm:1G;i2/gn:1G;go:1G;i2/gp:1G;gq:1G;i2/gr:1G;gs:1G;i2/gt:1G;gu:1G;i2/gv:1G;gw:1G;i2/gx:1G;gy:1G;i2/gz:1G;gA:1G;i2/gB:1G

innodb_log_group_home_dir = 

Re: 3 000 000 requests for last 14 days...

2004-03-10 Thread Patrick GELIN
Matt W wrote:

 Hi Patrick,
 
 No, you can't get per database statistics in MySQL. :-(
 
May be there is a tool to get this information examining log file, or
hooking requests send by clients??? By the way, it is possible to rotate
log files?
 
 Matt
 
 
 - Original Message -
 From: Patrick Gelin
 Sent: Wednesday, March 10, 2004 1:45 AM
 Subject: 3 000 000 requests for last 14 days...
 
 
 Hi,

 I've got very astonished to see with phpMyAdmin my MySQL database has
 received more than 3 Millions conexions for this last 14 days. But I
 don't
 knowwhich database is reponsable for this. Is there a mean to know
 connexion rate per database ?

 Thanks.
 
 



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Security

2004-03-10 Thread Joshua J. Kugler
Yes, you make sense.  But when you go in to access your bank account, you are 
not directly accessing the database.  The web application is opening the 
database and only returning rows in the table that pertain to you.  The web 
application can read all the rows; your user name has *no* read or write 
permissions to the database: the web application connects via its own 
username, and selects your account information from the database.

So, in other words, you need to keep a list of users separate from the list of 
MySQL users.  The mysql database controls which username/passwords can 
connect to the database.  Your user list would contain users which can log in 
to your system.

j- k-

On Wednesday 10 March 2004 01:47 pm, Maru, Mulugeta wrote:
 When I go online to access my bank account I only see transactions pertain
 to my account only. I think when ever I make a transaction the database
 records my account number in the transaction table. When I log-in using my
 account number and password the system checks whether it is correct or not
 and run another query to get all transaction that match my account number.

 Do I make sense?

 -Original Message-
 From: Joshua J. Kugler [mailto:[EMAIL PROTECTED]
 Sent: Wednesday, March 10, 2004 5:34 PM
 To: Mulugeta Maru; MySQL
 Subject: Re: Security


 Only being able to see certain rows is not a function of MySQL, it is a
 function of the application you write for the user to access the database.
 If a user has permission to read a table, they can read all rows.  It is up
 to your application to make sure they are only seeing rows that apply to
 them.

 j- k-

 On Tuesday 09 March 2004 05:57 pm, Mulugeta Maru wrote:
  Thank you for the kind response. May be I did not clearly ask the
  question. The user table in mysql database is used to set-up a user and
  password. Once I set-up my tables (customer, customer orders, customer
  order details, etc) in say abc database what will I have to do to make
  sure when customer A logs in to the database can only see his/her
  account, orders, order details without getting access to other customer
  accounts.

 --
 Joshua J. Kugler
 Fairbanks, Alaska
 Computer Consultant--Systems Designer
 .--- --- ...  ..- .--.- ..- --. .-.. . .-.
 [EMAIL PROTECTED]
 ICQ#:13706295
 Every knee shall bow, and every tongue confess, in heaven, on earth, and
 under the earth, that Jesus Christ is LORD -- Count on it!


 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

 VisionTV proudly celebrates 15 years as Canada's multi-faith television
 network.

-- 
Joshua J. Kugler
Fairbanks, Alaska
Computer Consultant--Systems Designer
.--- --- ...  ..- .--.- ..- --. .-.. . .-.
[EMAIL PROTECTED]
ICQ#:13706295
Every knee shall bow, and every tongue confess, in heaven, on earth, and under 
the earth, that Jesus Christ is LORD -- Count on it!


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



JOB: MySQL Operations Engineer for Yahoo! Mail in Sunnyvale, CA

2004-03-10 Thread Jeremy Zawodny
[I checked with the a list admin before posting a job here, so ping me
off-list if this bugs you...]

Do you have a working knowledge of MySQL in a production environment?
Can you configure and debug replication in your sleep? Do you know the
differences between MyISAM and InnoDB tables? Do you want to work a
thriving, stable Internet company?

If you're answered yes to those questions, check out this job
description and send me your resume if you're interested.

Think of the job as an operations job specializing in MySQL support.

job_listing
  
  Yahoo! Mail Operations Engineer

  The Yahoo Mail Operations team is looking for a highly dedicated,
  motivated, and experienced software operations and tools development
  engineer. The Mail operations team is responsible for overall
  performance, availability, reliability and scalability of several
  large-scale systems involving thousands of servers and hundred of
  terabytes of data.

  To be successful, you must have at least 4 to 5 years of experience
  with the following skills: UNIX (shell scripting, gmake, awk, sed
  and/or other unix system administration tools), perl, site
  monitoring such as NetSaint/Nagios, site operations/networking
  (VIPs, ssh, cron), c++ (some exposure), production database
  installation and/or configuration (MySQL or Oracle). Prior
  experiences with operations in 24x7 production environment are
  highly desired. You also need to have good communication skills,
  schedule flexibility in working with offshore engineers. BSCS or
  equivalent is required.

/job_listing

This job is on-site in Sunnyvale, California.

And, in for the sake of full disclosure, if you get hired, I do get a
reward.  But more importantly, you get a good job! :-)

Thanks,

Jeremy
-- 
Jeremy D. Zawodny |  Perl, Web, MySQL, Linux Magazine, Yahoo!
[EMAIL PROTECTED]  |  http://jeremy.zawodny.com/

MySQL 4.0.15-Yahoo-SMP: up 178 days, processed 2,619,184,901 queries (169/sec. avg)

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Newbie question on Comparing fields in 2 tables?

2004-03-10 Thread Michael Stassen
An equivalent, but slightly simpler, query would be

  SELECT sw.pcname, sw.product
  FROM software sw, keywords kw
  WHERE sw.product RLIKE kw.Searchname
RLIKE is for regular expression pattern matching.  Regular expressions, 
unlike LIKE patterns, don't have to match the whole string, so there is 
no need to paste '%' onto each end.

For more, see

  http://www.mysql.com/doc/en/String_comparison_functions.html
  http://www.mysql.com/doc/en/Pattern_matching.html
Michael

Rocar Peças wrote:

Mr. Izzard,

We have these tables:

Table software
- pcname char(..)
- product char(..)
Table keywords
- id int(..)
- searchname char(...)
and you want to pick out the pcname from the software table, where the
product field contains the searchname from the keywords table
Try this and you´ll succeed:
==
SELECT
software.pcname,
software.product
FROM
software, keywords
WHERE
software.product LIKE CONCAT(%, keywords.searchname, %)
==
Best wishes,

Leandro M Neves,
ROCAR PEÇAS LTD.
Sete Lagoas/MG - Brazil
- Original Message - 
From: Ian Izzard [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 2:05 PM
Subject: Newbie question on Comparing fields in 2 tables?

Hi,

I am new to using MySQL and SQL queries.  I have in the past only carried
out simple queries.  I am trying to write a query for use in our
Helpdesk/Audit software.
I want to compare the values in one table (Keywords) to the values found in
another table (Software) so that I can get records of games that are
installed on PCs.  The Software table is created from an audit run on each
PC.  The keywords table is created by myself.
The keywords table contains 2 fields, ID and Searchname.  A sample of the
data in this table would be:
ID   Searchname
1worm
2kazaa
3delta
4game
The software table has 2 fields, pcname and product.  A sample of the data
in this table would be:
pcname product
SW0638CADS Support
SW0638Citrix ICA Client
SW0638Winzip
SW0653Winzip
SW0653Delta Force 2
SW0462Winzip
SW0462Delta Force
SW0462Worms 2000
SW0785Winzip
SW0785Worms2
The software table has some 50,000 records in it.  What I am looking to do
is to pick out the pcname from the software table, where the product field
contains the searchname from the keywords table.  Something like:
select pcname, product from software, keywords where product like searchname

I would then expect the results to come out as:

pcname product
SW0653Delta Force 2
SW0462Delta Force
SW0462Worms 2000
SW0785Worm2
I have tried using the LIKE command, but the manuals only show examples when
comparing a field to a string, ie product LIKE 'worm%'
As the keyword table is likely to get quite long (currently 163 records) I
don't want to do a query using the LIKE command immediately above (, as the
query will get very long and unmanageable.
Can someone help with a solution to this?  Can it be done in a single query?
Is there a command that I just haven't yet found?
If it is of any help, the version of MySQL being used 4.0.16.  This version
is installed by the Helpdesk/Audit software, and so cannot be upgraded.
Your help is greatly appreciated.

Ian Izzard

Visit our web site at www.scottwilson.com

Privilege and Confidentiality Notice.
This e-mail and any attachments to it are intended only for the party
to whom they are addressed.  They may contain privileged and/or
confidential information.  If you have received this transmission in
error, please notify the sender immediately and delete any digital
copies and destroy any paper copies.
Thank you.
Scott Wilson Kirkpatrick  Co Ltd
Registered in London: No. 880328
Registered office: Scott House, Basing View,
Basingstoke, Hampshire, RG21 4JG. UK.

This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk




--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: questions mean what?

2004-03-10 Thread Sasha Pachev
Rochester, Dean wrote:
does the questions counter equate to the number of queries ran against the
database?  or then number of questions a query may have to ask the database
for one query?
if I do a 
select * from table1;

and table one has 100 records does that equate to 100 questions or one
question?
Dean-O
questions = queries

--
Sasha Pachev
Create online surveys at http://www.surveyz.com/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: mysql_query memory

2004-03-10 Thread Sasha Pachev
Melanie Ware wrote:
I am using mysql 4.0.17 on Red Hat Linux.

I am using the C API to access mysql

The application I am writing should parse a xml file and write details 
to the mysql database.

The xml elements as they are read are fed into a simple data structure.  
On the completion of the structure details the datbase should be checked 
for a prior entry.

This works successfully for the first 3 entries.  The 4th. entry 
executes the SELECT statement but appears to wipe the structure contents

The code is as follows.

select_query = SELECT file_id FROM File WHERE file_name = 'RPCMap.h';

mysql_query (conn, select_query);

I know that the line containing the mysql_query statement destroys the 
struture data content because I have used gdb to print the structure 
values as I step through the code.
The results you are seeing are more likely a gdb peculiarity. To verify, try 
printing out select_query before and after the call to mysql_query() without the 
use of gdb.

If you discover that select_query is indeed modified through a call to 
mysql_query(), I would run your program through valgrind to see if it happens to 
smash the stack earlier on. In 5 years of extensive work with the C API, I have 
never seen mysql_query() corrupt the caller's buffer.



--
Sasha Pachev
Create online surveys at http://www.surveyz.com/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Stringing in a table...

2004-03-10 Thread Sasha Pachev
Torrance Hill wrote:
I am fairly new to MySQL and I need a little assistance.  In our diff scripts, I need the output to string all the mods for a given table together in a single query, which will reduce the number of times the larger tables are copied.

So what modifications would I need to make to my diff script to reflect this.  

Any help will do...

Probably something like this:

delete from t1 where prim_key in (1,4,10,..);
insert into t1 values (...),(...),(...);
Basically, in the first query, delete all the records that have been removed or 
modified, and in the second insert those that have been inserted or modified.

Another solution you may want to consider is replication.

--
Sasha Pachev
Create online surveys at http://www.surveyz.com/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: 3 000 000 requests for last 14 days...

2004-03-10 Thread Sasha Pachev
Patrick GELIN wrote:
Matt W wrote:


Hi Patrick,

No, you can't get per database statistics in MySQL. :-(

May be there is a tool to get this information examining log file, or
hooking requests send by clients??? By the way, it is possible to rotate
log files?
Turn on full logging (log option), then write a few lines of Perl to parse it 
and collect the stats. Note that you could have cross-database queries.

To rotate, move the log into a different location, then do FLUSH LOGS

--
Sasha Pachev
Create online surveys at http://www.surveyz.com/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Database crash, lock held too long

2004-03-10 Thread Sasha Pachev
ZenShadow wrote:
Folks,

We've been running a fairly  high-traffic mysql server for some time,
and we've been occasionally seeing messages like this in the logs:
InnoDB: Error: semaphore wait has lasted  600 seconds
InnoDB: We intentionally crash the server, because it appears to be
hung.
040309 18:20:36  InnoDB: Assertion failure in thread 2623773248 in file
sync0arr.c line 934
InnoDB: Failing assertion: 0
InnoDB: We intentionally generate a memory trap.
InnoDB: Send a detailed bug report to [EMAIL PROTECTED]
Try replacing the RedHat kernel with the one from kernel.org. MyISAM tables do 
get periodically corrupted on RedHat kernels, and all the corruptions I've 
investigated went away when the kernel was replaced.

Otherwise, it could be a rare InnoDB bug - Heikki would be interested in 
investigating it if that is the case. But first, try a different kernel.

--
Sasha Pachev
Create online surveys at http://www.surveyz.com/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Security

2004-03-10 Thread Mulugeta Maru
Hi Mike,

I am sorry for the confusion I might have caused. May be it would help to
give a clear example.

Table - Customers (CustomerID, CustomerName, Address, etc)

Table - Transaction(TransactionID,CustomerID,Date,Amount)

Note: CustomerID in Customer Table is a Primary Key. TransactionID is a
Primary Key and CustomerID is a Foreign Key in Transaction Table).

Question: How would I be able to give my customers access to the database so
that they can update the customer table (for example address change) and add
transactions to the transaction table. What I do not want to happen is that
customer A is able to modify customer B's record.
In short how would you restrict customer a to see transactions that pertain
to him/her.

Many thanks.
- Original Message - 
From: Mike Johnson [EMAIL PROTECTED]
To: MySQL [EMAIL PROTECTED]
Sent: Wednesday, March 10, 2004 4:55 PM
Subject: RE: Security


 From: Maru, Mulugeta [mailto:[EMAIL PROTECTED]

  When I go online to access my bank account I only see
  transactions pertain to my account only. I think when ever I
  make a transaction the database records my account number in
  the transaction table. When I log-in using my account number
  and password the system checks whether it is correct or not
  and run another query to get all transaction that match my
  account number.
 
  Do I make sense?


 (sent offlist by mistake, please excuse the dupe)

 The point being made is that you're looking at your bank account
information in a client that is set to read records only pertaining to your
account.

 The native mysql client is not such a program and was never intended to
be. While you can customize access for users to certain databases or certain
tables within those databases, it's simply not built as a multi-user
transactional client for limiting access to data in commonly-used tables.

 It begs the question why you're giving your clients access to the native
mysql client itself rather than developing an application to do this, in
which you could quite easily limit such access.


 -- 
 Mike Johnson
 Web Developer
 Smarter Living, Inc.
 phone (617) 886-5539

 -- 
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Security

2004-03-10 Thread Paul DuBois
At 20:39 -0600 3/10/04, Mulugeta Maru wrote:
Hi Mike,

I am sorry for the confusion I might have caused. May be it would help to
give a clear example.
Table - Customers (CustomerID, CustomerName, Address, etc)

Table - Transaction(TransactionID,CustomerID,Date,Amount)

Note: CustomerID in Customer Table is a Primary Key. TransactionID is a
Primary Key and CustomerID is a Foreign Key in Transaction Table).
Question: How would I be able to give my customers access to the database so
that they can update the customer table (for example address change) and add
transactions to the transaction table. What I do not want to happen is that
customer A is able to modify customer B's record.
In short how would you restrict customer a to see transactions that pertain
to him/her.
MySQL does not support row-level privileges, which is what you're asking
for.  You must enforce this kind of access policy by implementing it
in your application.
--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


host names

2004-03-10 Thread CJNoyesSW
I have a question about connecting to MySQL. I have MySQL both on my box for 
development and on my Web host's machine. Can I use my domain name of my web 
host as a host so I can write a program to load data into MySQL.

Christopher J. Noyes


Re: host names

2004-03-10 Thread Paul DuBois
At 23:03 -0500 3/10/04, [EMAIL PROTECTED] wrote:
I have a question about connecting to MySQL. I have MySQL both on my box for
development and on my Web host's machine. Can I use my domain name of my web
host as a host so I can write a program to load data into MySQL.
What does that mean?

--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


RE: host names

2004-03-10 Thread Jonathan Villa
I wonder if he means that he wants to pull data from one db into another
using a script of some kind.

If that is what you mean, why not give phpMyAdmin a try, unless your hosting
company already has it.  Many do now a days...

Please clarify.



-Original Message-
From: Paul DuBois [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, March 10, 2004 10:18 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: host names

At 23:03 -0500 3/10/04, [EMAIL PROTECTED] wrote:
I have a question about connecting to MySQL. I have MySQL both on my box
for
development and on my Web host's machine. Can I use my domain name of my
web
host as a host so I can write a program to load data into MySQL.

What does that mean?

-- 
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com

MySQL Users Conference: April 14-16, 2004
http://www.mysql.com/uc2004/

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: host names

2004-03-10 Thread Jonathan Villa
How exactly are you doing it with phpMyAdmin?  Not sure if it would be save
to a temp dir,  I usually get a save as option.

 

Sorry I can't see your batch file because Outlook blocked it, since it was a
batch file.  I'll be checking my email from my Linux machine later, I'll
take a look at it then if I can.

 

  _  

From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, March 10, 2004 10:41 PM
To: [EMAIL PROTECTED]
Subject: Re: host names

 

In a message dated 3/10/04 11:23:42 PM Eastern Standard Time,
[EMAIL PROTECTED] writes:




I wonder if he means that he wants to pull data from one db into another
using a script of some kind.

If that is what you mean, why not give phpMyAdmin a try, unless your hosting
company already has it.  Many do now a days...



I've been trying to load data into my local copy of MySQL with both
phpMyAdmin and MySQLImport and both are failing. MyPHPAdmin is losing the \
in the file name of the text file which I gather it copied to my temp
directory. MySqlImport, just displays the help even though I am using the
commands as documented. The batch file attached are the commands that I used
to run MySQLImport. Part of what I am going to wind up doing is populating
long text fields in the future. I have a program to process the text already
written and it would be easy to modify it with the C++ lib to stuff the text
into the database.

Christopher J. Noyes



Privilege to single database being revoked occasionally

2004-03-10 Thread Terence
Dear Lists,

We moved to 4.1.0 when it was first launched, and twice a month or so, we
get access denied commands to one particular database for one particular
user. The privileges are correctly set, and the only way to restore access
for the user, is to revoke and re-apply the privileges and all works fine
again. I am the only user with permission to change privileges.

I am just wondering if anyone else has stumbled across this problem in
4.1.0? It doesnt seem to have been fixed in version 4.1.1 according to:
http://www.mysql.com/doc/en/News-4.1.1.html

If there's any data I can provide for debugging purposes, please let me
know.

Thanks
Terence


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Saving file into database

2004-03-10 Thread Isa Wolt
Thanks for all the answers!!!

I have been trying the longblob's and it seems to work!
Now all I have to is to figure out how to read it out.. but how hard can it 
be ;)

thanks again for all good suggestions!

/isa


From: Kurt Haegeman [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: Saving file into database
Date: Wed, 10 Mar 2004 14:25:33 +0100
Use the BLOB, Luke!

See your local MySQL manual for details.

We're using BLOBs to store PDF in our database, and through the use of HTTP 
headers, we're able to let user download the PDFs without having to store a 
local copy on disk, directly from the database (content-disposition 
header).

Hope this helps.
Kurt Haegeman
Mediargus.com
Paul Rigor wrote:

Are you running a web server (or ftp server) as well?  Because if you are, 
then you can upload the files to a separate directory using perl and just 
store the links to that file into a table in your database...

If you're not running a webserver (or ftp)... then lemme konw if you get a 
viable suggestion.

HEre's my 2cents. Since mysql is a relational database, it would be 
difficult to display that particular column/row containing the file (esp, 
binary).  You can use perl (or another converter) to convert the binary 
file into uue (or other text format)... and then import that... make sure 
you remove the linefeeds and store information about the column widths of 
the uue (or other text format) into a table in your database.  but geez, 
if the file is considerably large... like i said, it would put a strain on 
your server. (unless you have GIGS of ram and extra processing spd).

good luck,
paul
At 01:49 AM 3/9/2004, Isa Wolt wrote:

Hi,

I would like to save a binary file into a mysql database, for later being 
able to use the file. I am using a perl interafce. Is this at all 
possible???

And would it be possible to then read that file from a c++ interface?

would be greatful for any help/advices!

Isa

_
Hitta rätt på nätet med MSN Sök http://search.msn.se/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


_
Paul Rigor
[EMAIL PROTECTED]
Go Bruins!
_
Chatt: Träffa nya nätkompisar på Habbo Hotel 
http://habbohotel.msn.se/habbo/sv/channelizer

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


MySQL 5 C API prepared Statments errors

2004-03-10 Thread Arunachalam
Hi,

As I declared that COBOL can able to communicate with MySQL via it's C API routines.

Currently i have used MySQL 5.0.0-alpha and involved in the usage of prepared 
statement C API.
When I implement this calling from COBOL shows this error and reset the MySQL server. 
(reset --
stop).

Finally I obtaines the error message from the mysql_error() API as
*'Can't open shared memeory; Request event don't create * in COBOL.

and stores error message in mysql.err log file as;

Error: Freeing unallocated data at line 181,
'C:\build500\build\mysql-5.0.0-alpha\mysys\my_alloc.c'

Is anybody met these error already reply me what it means...
What cause this error?
How could we resolve this?

please...

Arun.


Yahoo! India Insurance Special: Be informed on the best policies, services, tools and 
more. 
Go to: http://in.insurance.yahoo.com/licspecial/index.html

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



RE: Load data + odbc

2004-03-10 Thread Stan Sebastian

 Stan Sebastian [EMAIL PROTECTED] wrote:
  Please help! :)
 
  I've got 2 workstations and a server on which i have Mysql 3.23.52 - nt.
 
  The clients are build in Visual FoxPro and use MyODBC for connecting to
  server.
 
  From both WKS statements like select, insert, update, delete work just
fine,
  but when i want to 'LOAD DATA local INFILE' it works OK only from one
WKS.
 
  I've used also the 'root'  for this and is the same problem.
 

 What exactly wrong with 'LOAD DATA LOCAL'?
 Did you get 'The used command is not allowed with this MySQL version'
error? If so, you should enable LOAD DATA LOCAL command:
 http://www.mysql.com/doc/en/LOAD_DATA_LOCAL.html


I dont know what's wrong with 'LOAD DATA LOCAL'. In Visual FoxPro, from the
command line i get the -1 error , that means that  'a connection level error
occurs' (this, of course, from the client that doesnt works, because, like i
said, i have a client that can load the file).

In the tutorial i've read about
If LOAD DATA LOCAL INFILE is disabled, either in the server or the client,
a client that attempts to issue such a statement receives the following
error message:
ERROR 1148: The used command is not allowed with this MySQL version

How can i enable this on a client that works with MyODBC?


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]