re: Using Indian languages and working with them using C API()
Thanks for your help. I am no seasoned C programmer so looking into the source code is out of question. I am having RichControl in my application that returs text in Unicode data. So if a user has entered Hindi text in the text control i have to add them in a table. For that I will be using C API mysql_real_query(). Should I send them after converting to utf-8 or it depends upon how the server was configured. I mean the server was configured to use ucs-2 then probably I can send the data as it is in Unicode and setting the correct length in mysql_real_query() API. WIndows has inbuilt functions that can convert from Unicode to utf-8 and vice versa. Since my application is a general purpose so I dont know how the server is configured...whether it is configured for ucs-2 or for utf-8. There how to figure out so that I can correctly convert the data returned from mysql_store_result() to Unicode value and display the result in my app. I am confused on how the data is returned back and forth between my client and the server? Regards Karam --- Jeremy March [EMAIL PROTECTED] wrote: Can somebody give me pointers how to store and retrieve data in Hindi using MySQL C API and MySQL in general. Since alll the hindi text will be in unicode format and C API uses char* parameter how do I interface between my Hindi text data and C API. DO I convert them to some other format like utf-8 etc. I don't have very much experience writing clients in C, but I have been following the MySQL unicode development. If you haven't already it might help to look at the MySQL source that deals with unicode. In the strings directory there are two files ctype-utf8.c and ctype-ucs2.c. All the sorting and string comparisons for unicode are defined there. I think the conversion from char* to unicode is done there. I suggest you look at the latest source for 4.1.2 in the bitkeeper tree because changes are still being made to this code. I expect there will be more significant changes in the next couple of weeks. It might also help to read the SET CHARACTER SET and SET NAMES commands here: http://www.mysql.com/doc/en/Charset.html Good luck, Jeremy -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] __ Do you Yahoo!? Yahoo! Mail - More reliable, more storage, less spam http://mail.yahoo.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Jumping to prev and next records
Scott Haneda wrote: [...] Is perhaps there some way to get the next id and prev id in a mysql query based on id being sorted? You could do this using LIMIT. For example: SELECT id FROM foo WHERE id $current_id ORDER BY id ASC LIMIT 1; SELECT id FROM foo WHERE id $current_id ORDER BY id DESC LIMIT 1; If the result is empty, you'll know you have to wrap to the first/last entry. Hans-Peter -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: How could I do this insert/select?
stephen [EMAIL PROTECTED] wrote: mysql use zzz Database changed mysql create table category - ( - id tinyint(4) NOT NULL auto_increment, - name varchar(20) NOT NULL, - parent tinyint(4) NULL, - primary key(id) - ); Query OK, 0 rows affected (0.00 sec) mysql insert into category (name, parent) values('cc_1',null); insert into category (name, parent) select 'cc_2a', id from category where name = 'cc_1'; Query OK, 1 row affected (0.01 sec) mysql insert into category (name, parent) select 'cc_2a', id from category where name = 'cc_1'; ERROR 1066: Not unique table/alias: 'category' You can add data into the same table tnat you use in the SELECT part only from version 4.0.14. http://www.mysql.com/doc/en/INSERT_SELECT.html If you use older version, retrieve data into the temporary table and then insert them into 'category' table. mysql show tables; +---+ | Tables_in_zzz | +---+ | category | +---+ 1 row in set (0.00 sec) mysql status -- /usr/local/mysql/bin/mysql Ver 11.17 Distrib 3.23.49a, for pc-linux-gnu (i686) Connection id: 25 Current database: zzz Current user: [EMAIL PROTECTED] Current pager: stdout Using outfile: '' Server version: 3.23.49a Protocol version: 10 Connection: Localhost via UNIX socket Client characterset:latin1 Server characterset:latin1 UNIX socket:/tmp/mysql.sock Uptime: 2 days 14 hours 36 min 36 sec Threads: 1 Questions: 313 Slow queries: 0 Opens: 70 Flush tables: 1 Open tables: 15 Queries per second avg: 0.001 -- I don't have version 4 at my ISP either. -- 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: restoring a database from tape
If the directory structure is the same and the snapshot is consistent then the answer is yes. If you do not want to purchase a commercial utility, one method is to schedule mysqldump, compress the file and then backup that file up. -Original Message- From: Ansari, Raza (GEI, GEFA) To: [EMAIL PROTECTED] Cc: Cc: Sent: 3/15/04 4:52 PM Subject: RE: restoring a database from tape Victor, Will this not work for Innodb tables? If my backup also includes system tablespaces and .ibd files ( we using multiple tablepsace), will that be a problem? Thanks Raza -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, March 15, 2004 9:03 AM To: mt m Cc: [EMAIL PROTECTED] Subject: Re: restoring a database from tape If the table types are all MyISAM and you took a consistent backup the answer is most likely yes. Original Message On 3/15/04, 7:50:39 AM, mt m [EMAIL PROTECTED] wrote regarding restoring a database from tape: Hi, Recently we EOLed a machine that had a mysql instance. The /usr/local/mysql dir was backed up to tape before EOLing. Having now installed a new machine, we need to copy the old database from tape to the new machine. Mysql has been successfully installed on the new machine. To install the database, can I just copy the ../mysql/data directory from the tape to the corresponding dir on the new machine? thanks for your time. -M _ MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus -- 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]
Re: composite Keys
joe collins [EMAIL PROTECTED] wrote: does MySQL support composite keys? Yes, MySQL supports composite keys: http://www.mysql.com/doc/en/Multiple-column_indexes.html I have a table 'Group_Map' This has 3 fields contact_id (primary key in another table) group_id (candidate key in another table) user_id (primary key in another table) is it possible / advisable to create and maintain a composite key for this table? Sorry, I don't understand what exactly you want to get. It depends on your queries on which columns it will be efficient to create an index. -- 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: restoring a database from tape
On 16 Mar 2004, at 09:06, Victor Pendleton wrote: If the directory structure is the same and the snapshot is consistent then the answer is yes. If you do not want to purchase a commercial utility, one method is to schedule mysqldump, compress the file and then backup that file up. What commercial utilities exist for backups of MySQL instances? For complicated reasons I don't want to go into, most of the standard methods for backing up MySQL instances don't work well for us, or at least have significant drawbacks. Tim -- Dr Tim Cutts Informatics Systems Group Wellcome Trust Sanger Institute Hinxton, Cambridge, CB10 1SA, UK -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
3 node master - master - master replication?
hi, we have 3 inet servers running mysql: mysql1.mydom.tld mysql2.mydom.tld mysql3.mydom.tld and we also got an dynamicdns entry mysql.mydom.tld. normaly mysql.mydom.tld directs to mysql1.mydom.tld - but if mysql2 detects mysql1 is down it will use a dyndns script to become mysql.mydom.tld. what we now need is the exact same data content on all 3 servers! and what we also need is any methode to queue tabel updates if one of the servers is down. if mysql1 is down mysql2 will become mysql.mydom.tld for all clients - but if an table is updated and mysql1 is down the data will get lost on mysql1 if it comes up again... is there any tool to queue mysql requests and update the failed master later on its comeback? and how to configure the 3 mysql servers to have an master(mysql1) - master(mysql2) - master(mysql3) - master(mysql1) replication? thx4any help Florian Engelmann -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Great QUERY question
JR Bullington [EMAIL PROTECTED] wrote: This is for those who love a challenge. I am trying to come up with a query that would calculate the Standard Deviation and Variance for 15 fields. Although in theory this is easily done in Access, MySQL does not have the same mathematical calculations that Access/SQL does. Here is the query as it stands in Access: Select avg(Item01) as Item01a, stdev(Item01) as Item01d, avg(Item02) as Item02a, stdev(Item02) as Item02d, avg(Item03) as Item03a, stdev(Item03) as Item03d, avg(Item04) as Item04a, stdev(Item04) as Item04d, avg(Item05) as Item05a, stdev(Item05) as Item05d, avg(Item06) as Item06a, stdev(Item06) as Item06d, avg(Item07) as Item07a, stdev(Item07) as Item07d, avg(Item08) as Item08a, stdev(Item08) as Item08d, avg(Item09) as Item09a, stdev(Item09) as Item09d, avg(Item10) as Item10a, stdev(Item10) as Item10d, avg(Item11) as Item11a, stdev(Item11) as Item11d, avg(Item12) as Item12a, stdev(Item12) as Item12d, avg(Item13) as Item13a, stdev(Item13) as Item13d, avg(Item14) as Item14a, stdev(Item14) as Item14d, avg(Item15) as Item15a, stdev(Item15) as Item15d, avg(overallscore) as overa, stdev(overallscore) as overd from tblFacultyEvalSurgery This is for an online grading system that, except for 5 pages, has been converted over to MySQL and Linux / Apache. 2 of which have this problem. Avg() is easy, but it's the StDev that I can't get. St Dev is made from Variance (or the mean), which again is not a function of MySQL. To view the Variance and StDev formulae, http://davidmlane.com/hyperstat/A16252.html. If you have any ideas, I will be working on this for the next few days. There are STD()/STDDEV() functions in the MySQL: http://www.mysql.com/doc/en/GROUP-BY-Functions.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]
can I get MySQL Source code under Windows OS?
Hi, I have downloaded *bk-3.0.4-x86-win32.EXE* from URL: http://www.bitmover.com/download, for windows When I try to install it ask for; *** This release of BitKeeper requires the Cygwin version 1.5.5 . If you have already installed a older cygwin release, you should upgrade to cygwin 1.5.5 *WARNING*: This install script will force all cygwin mount table entries to binary mode. You should skip this if you have customized mount setting. Do you want to install cygwin 1.5.5 now? (Cygwin is comes under unix!!) If I press Yes -- it further say error An I/O error occured while installing a file.This is normally cauesd by bad installation media or a corrupt istallation file. and shows ABORT and RETRY button, if I press RETRY it never improve in installation just stay idle... and If I press ABORT it get aborted. Also when I visit the URL http://www.mysql.com/doc/en/Installing_source_tree.html and it seems that instructions given for working under Unix platform - right? Could I get the Source code of MySQL for testing with Windows?... Thanks, 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: finding max values
Keith [EMAIL PROTECTED] wrote: had to upgrade mySQL but I got the subquery working for individual entries. Trouble now is that I can't figure out how to get it to work for more than one entry. The query currently stands at: SELECT SQL_CALC_FOUND_ROWS sys.sectorID, sys.name AS sysName, sys.sysID, sys.galX, sys.galY, SUBSTRING_INDEX(sys.description,' ',50) AS description, sec.name AS secName, pla.government FROM planets AS pla, systems AS sys, sectors AS sec WHERE sys.sectorID IN ('1','2','3','4','11','14','18','25','28','29') AND sys.visible='Y' AND sys.sectorID=sec.sectorID AND population=(SELECT MAX(population) FROM planets AS pla, systems AS sys, sectors AS sec WHERE sys.sectorID IN ('1','2','3','4','11','14','18','25','28','29') AND pla.sysID=sys.sysID AND sys.visible='Y' AND sys.sectorID=sec.sectorID) ORDER BY sys.name, sec.name LIMIT 0,10 with that it will only display a single government. Where I want it to, for each system, look through that systems planets and find the highest population then return that. Any ideas? You can rewrite your query like: SELECT SQL_CALC_FOUND_ROWS sys.sectorID, sys.name AS sysName, sys.sysID, sys.galX, sys.galY, SUBSTRING_INDEX(sys.description,' ',50) AS description, ec.name AS secName, pla.government FROM planets AS pla, systems AS sys, sectors AS sec WHERE sys.sectorID IN ('1','2','3','4','11','14','18','25','28','29') AND sys.visible='Y' AND sys.sectorID=sec.sectorID AND (pla.population, pla.sysID) IN (SELECT MAX(population), pla.sysID FROM planets AS pla, systems AS sys, sectors AS sec WHERE sys.sectorID IN ('1','2','3','4','11','14','18','25','28','29') AND pla.sysID=sys.sysID AND sys.visible='Y' AND sys.sectorID=sec.sectorID GROUP BY pla.sysID) ORDER BY sys.name, sec.name LIMIT 0,10 -- 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: restoring a database from tape
Tim Cutts [EMAIL PROTECTED] wrote: On 16 Mar 2004, at 09:06, Victor Pendleton wrote: If the directory structure is the same and the snapshot is consistent then the answer is yes. If you do not want to purchase a commercial utility, one method is to schedule mysqldump, compress the file and then backup that file up. What commercial utilities exist for backups of MySQL instances? For complicated reasons I don't want to go into, most of the standard methods for backing up MySQL instances don't work well for us, or at least have significant drawbacks. For InnoDB and MyISAM tables there is InnoDB Hot Backup tool: http://innodb.com/order.php -- 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]
Administrator
After install the MySQL Administrator version 1.0.2b alpha there is an error about a msvcr70.dll not found. This problem was found in Windows 98SE and Windows 2000 server systems. Thanks for your attention Reinaldo Melo Filho from Brazil
Re: mysqlgui problem - can't connect via tmp/mysql.sock
Dmitry Rusak writes: Hi! I have a problem using musqlgui-1.7.2 under FreeBSD 4.9 STABLE. It Can't connect to mysql server via tmp/mysql.sock My setup: 1) mysql is installed in /usr/local/mysql data base directory - /usr/local/mysql/data socket directory - /usr/local/mysql/tmp/mysql.sock 2) currenlty i am using FreeBSD 4.2 static binary of MySQLGUI 1.7.2 3) I have created: /etc/my.cnf /etc/.my.cnf ~/my.cnf ~/.my.cnf /usr/local/etc/my.cnf /usr/local/etc/.my.cnf with the same content: --- [client] port = 3306 host = localhost user = root [client_fltk] client_file=~/.mysql.options queries_file=~/.mysql_history history_length=100 database=my_db - (this db exists!) - The problem: When executing mysqlgui it first asks me for a password. I assume it should be the root password (or not? actually in my case mysql is configured to work under mysql user, but i tryed password for this user also). I am entering the password and then it says in Info line at the bottom of window that Can't connect to mysql server via tmp/mysql.sock. When i am pressing on + to see full message log it shows the lines that options are successifully read from options file and so on - so, no problem here. In options of mysqlgui i have localhost, port 3306. There is no problem with running ordinary mysql client. I think probably because mysql server has been installed not in standard directory, it can not find it. So, maybe there is a chance to configure the path to mysql? Or something other? Best regards, Dmitry First of all, please use version 1.7.5. 1.7.2 has too many bugs. You should add socket option under [client] and you should put /usr/local/mysql/tmp/mysql.sock there as well as under [mysqld] options header. You should also make /usr/local/mysql/tmp/ directory scannable etc .. by all, plus with temporary attribute. -- Sincerely, -- For technical support contracts, go to https://order.mysql.com/?ref=msmi __ ___ ___ __ / |/ /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED] / /|_/ / // /\ \/ /_/ / /__ MySQL AB /_/ /_/\_, /___/\___\_\___/ Full time Developer and Support Coordinator ___/ www.mysql.com Larnaca, Cyprus Meet the MySQL at User 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]
Hierarchical data design
Hi all, I've been playing around with the concepts mentioned in this article: http://www.sitepoint.com/article/hierarchical-data-database/ (Short summary: Using Modified Preorder Tree Traversal, resulting in left and right values for each tree node to describe the tree structure) With all this in mind, I'm hoping to emulate a folders and pages hierarchical structure for a CMS, without relying on the file system at all. Here's where I get stuck: In a simple tree, one can easily see that using the title of a node as it's primary key is not smart... names can easily collide: Root Products ProductOne About FAQ Support ProductTwo About FAQ Support Services About As the writer of the article suggests, numeric IDs are the way to go. However, I want to call the tree via the URL with name-based ID's (eg /products/product-one/about/) rather than numeric IDs (eg /2/17/44/). A further complication is that this data design would allow two nodes in the same parent node to have the same title, since the numeric key is the ID, rather than the title. When we look at a traditional file system, it's based on unique keys AT EACH TREE LEVEL, not unique keys for the entire tree. As such, I don't think the above data model is right for this application. The only catch is I have no idea where to look next. Hours of Googling has returned very little. Any hints on where to look next would be great. --- Justin French http://indent.com.au -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
[ot] connection process is very slow under WIN NT 4.0
Hi I realize that this is may be off topic, but the remote connection times to MySQL under Windows NT 4.0 is really slow, while under Unix is quite responsible. Does anyone faced this problem and found a proper solution? because the project needs to reside on Windows and otherwise management will switch to ORACLE. Thanks in advance, Leonardo J. Belén. mysql query row select mysql query row select - Original Message - From: Newsletter [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 10:04 AM Subject: Administrator After install the MySQL Administrator version 1.0.2b alpha there is an error about a msvcr70.dll not found. This problem was found in Windows 98SE and Windows 2000 server systems. Thanks for your attention Reinaldo Melo Filho from Brazil -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Hierarchical data design
One of the ways around this that I've seen is to maintain an additional field for the 'full path' info. so that you have: table_name --- node_id integer auto_increment node_name varchar(50) not null parent_id integer full_path varchar(255) the obvious downside is that your application needs to maintain this info. the other option is to parse your info from the URL, tokenizing per '/' character, then do look ups recursively for each entry, finding the node you're looking for. -Original Message- From: Justin French [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 8:39 AM To: MySQL Subject: Hierarchical data design Hi all, I've been playing around with the concepts mentioned in this article: http://www.sitepoint.com/article/hierarchical-data-database/ (Short summary: Using Modified Preorder Tree Traversal, resulting in left and right values for each tree node to describe the tree structure) With all this in mind, I'm hoping to emulate a folders and pages hierarchical structure for a CMS, without relying on the file system at all. Here's where I get stuck: In a simple tree, one can easily see that using the title of a node as it's primary key is not smart... names can easily collide: Root Products ProductOne About FAQ Support ProductTwo About FAQ Support Services About As the writer of the article suggests, numeric IDs are the way to go. However, I want to call the tree via the URL with name-based ID's (eg /products/product-one/about/) rather than numeric IDs (eg /2/17/44/). A further complication is that this data design would allow two nodes in the same parent node to have the same title, since the numeric key is the ID, rather than the title. When we look at a traditional file system, it's based on unique keys AT EACH TREE LEVEL, not unique keys for the entire tree. As such, I don't think the above data model is right for this application. The only catch is I have no idea where to look next. Hours of Googling has returned very little. Any hints on where to look next would be great. --- Justin French http://indent.com.au -- 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: Help with a tough query
The DISTINCT key word works on the whole record, not the field that follows it. So the query actually does return multiple records with the same EventID when there are multiple related contacts/regardings. DISTINCT filters out duplicate records created from the joining of the three tables. When you specify a left join, you will always get the same number of records as are in your primary join table (barring other filters). So a left join assures that I get all the events, but leaves out the related contacts and regards if there is more than one. I'm thinking I'm going to have use UNION to merge a few select statements. On Mar 16, 2004, at 5:21 AM, Harald Fuchs wrote: In article [EMAIL PROTECTED], Brent Baisley [EMAIL PROTECTED] writes: You're right, it doesn't fail, it just fails to give me the desired results. Left joining won't work because it will only grab one record from contacts and/or regarding if one exists, when there could be many. But that's not due to the LEFT JOIN, but due to the SELECT DISTINCT EventID. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- Brent Baisley Systems Architect Landover Associates, Inc. Search Advisory Services for Advanced Technology Environments p: 212.759.6400/800.759.0577 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Hierarchical data design
the other option is to parse your info from the URL, tokenizing per '/' character, then do look ups recursively for each entry, finding the node you're looking for. This strikes me as the most logical solution to this particular problem. With regards, Martijn Tonies Database Workbench - developer tool for InterBase, Firebird, MySQL MS SQL Server. Upscene Productions http://www.upscene.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Copying a database
How would you go about copying a database? I need to make a copy with all the tables and names the same. I just need to name the database something different. Thanks, Ed -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
BLOB 1024
Hi All, How can I define a column of BLOB (or TEXT) with exact length of 1024 bytes? Can I index it? I want to run a select query using FIND_IN_SET function on that column.. but I'm afraid it will be slow.. any suggestions? thanks in advance, -Lorderon. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Hierarchical data design
In a simple tree, one can easily see that using the title of a node as it's primary key is not smart... names can easily collide: The names can definitely collide. But under a file system paradigm the combination of name with parentID will be unique and define the tree structure you mention: create table nodes ( nodeID integer NOT NULL PRIMARY KEY, parentIDinteger NOT NULL, namechar(50), INDEX p_id_idx (parentID) ); example to list a directory from this: SELECT names FROM nodes WHERE parentID = 1234; Brad Eacker ([EMAIL PROTECTED]) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Copying a database
Ed Curtis [EMAIL PROTECTED] wrote: How would you go about copying a database? I need to make a copy with all the tables and names the same. I just need to name the database something different. If you use only ISAM/MyISAM table, rename database directory. Otherwise create new database, make a dump of tables, restore them into new database, drop the old one. -- 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]
4.1.2.?
Hi, Is there any info on when 4.1.2 is to be released? Mirza -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
[4.0] latin1 accented characters and fulltext
I've been playing around with fulltext searching in 4.0, and I ran into the following weirdness with accented characters. | version | 4.0.14 | character_set | latin1 in my entire collection, there is just one row with the keyword 'angélica' with the accent, several others without. a fulltext search for 'angélica' returns all of them. it's almost as if mysql knows what the base unaccented character is, and is performing some normalization before searching. but I couldn't find this documented anywhere (tried a search for 'accented character fulltext', nothing looked relevant). I don't think I _mind_ the behavior. In fact it may actually save me jumping through some hoops in order to meet functional requirements, but I just didn't _expect_ it... - mark drop table test_search; create table test_search ( artist_id integer not null, lang_code char(5) not null, name varchar(255) not null, keywords varchar(255) not null, primary key ( artist_id, lang_code ), fulltext ( keywords ) ) type=myisam; insert into test_search values ( 740273, 'en-us', 'Angelica', 'Angelica' ); insert into test_search values ( 783679, 'en-us', 'Angelica Garcia', 'Angelica Garcia' ); insert into test_search values ( 756774, 'en-us', 'Angélica Vale', 'Angelica Angélica Vale' ); insert into test_search values ( 751119, 'en-us', 'Electric Junkyard', 'Electric Junkyard' ); insert into test_search values ( 774590, 'en-us', 'Moncho', 'Moncho' ); select artist_id,lang_code,name,keywords FROM test_search WHERE match(keywords) against ('angélica' in boolean mode) ORDER BY name asc +---+---+-++ | artist_id | lang_code | name| keywords | +---+---+-++ |740273 | en-us | Angelica| Angelica | |783679 | en-us | Angelica Garcia | Angelica Garcia| |756774 | en-us | Angélica Vale | Angelica Angélica Vale | +---+---+-++ 3 rows in set (0.00 sec) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: BETWEEN
Matt W wrote: Hi Michael, SELECT * FROM sys WHERE sectorID BETWEEN 1 AND 20 OR sectorID BETWEEN 30 AND 42; If that's slow (the optimizer doesn't like ORs) and you are using at least mysql 4.0.0, you can change this to SELECT * FROM sys WHERE sectorID BETWEEN 1 AND 20 UNION SELECT * FROM sys WHERE sectorID BETWEEN 30 AND 42; The query using 2 BETWEENs with OR is exactly how it should be. It will be fast even in MySQL 3.23. OR is not a problem when the OR parts involve the same index. :-) Well, that makes sense, and it fits my own experience, but is it documented anywhere? Or is that just supposed to be common sense? So far as I can see, the manual does not mention OR or BETWEEN in the context of using an index, except for the mention of a new feature in 5.0 http://www.mysql.com/doc/en/OR_optimizations.html. There have been so many threads about slowness of OR or BETWEEN, often with UNION as a suggested work-around, that in the absence of a clear description of how this works and when UNION helps, it is easy to get confused. Michael -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
ORACLE to MySQL migration
Hello colleagues, I have to migrate a lot of ORACLE 8.1.7 databases to MySQL 3.23 I'm looking for a tool or for an algorithm which fully supports any ORACLE structures ... If needed I may use a commercial tool, otherwise a free software / shared software should be very appreciated Can anyone give me some suggestions? thanks a lot Enrico -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: BETWEEN
Jochem van Dieten wrote: Michael Stassen wrote: SELECT * FROM sys WHERE sectorID BETWEEN 1 AND 20 OR sectorID BETWEEN 30 AND 42; If that's slow (the optimizer doesn't like ORs) and you are using at least mysql 4.0.0, you can change this to SELECT * FROM sys WHERE sectorID BETWEEN 1 AND 20 UNION SELECT * FROM sys WHERE sectorID BETWEEN 30 AND 42; At the very least use UNION ALL. Right, because UNION DISTINCT is the default. Good point. Matt W has already pointed out, however, that UNION is unnecessary, as the optimizer has no problems with OR when the same index is used. However, I expect that would result in doing 2 rangescans and a merge. It might be even faster to use: SELECT * FROM sys WHERE sectorID BETWEEN 1 AND 42 AND sectorID NOT BETWEEN 21 AND 29; That would result in 1 rangescan and a filter. But a lot depends on the schema and cardinality. I'm curious. Could you explain this further? If this works by grabbing 1 to 42, then dropping 21 to 29, wouldn't this increase the likelihood (without knowing anything about the data) of crossing the 30% threshhold and doing a tablescan instead of using the index, relative to asking for 1 to 20 plus 30 to 42? On the other hand, if you already know that 1 to 20 and/or 30 to 42 exceeds 30%, then one tablescan is better than 2. Is that what you mean? Also, if we ignore the UNION version and look at the two BETWEENs, are you saying that WHERE sectorID BETWEEN 1 AND 20 OR sectorID BETWEEN 30 AND 42; will be treated differently than WHERE sectorID BETWEEN 1 AND 42 AND sectorID NOT BETWEEN 21 AND 29; by the optimizer? Jochem Michael -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Copying a database
Egor Egorov wrote: How would you go about copying a database? I need to make a copy with all the tables and names the same. I just need to name the database something different. If you use only ISAM/MyISAM table, rename database directory. Otherwise create new database, make a dump of tables, restore them into new database, drop the old one. If you use phpmyadmin for administration purposes, you will find very comfortable functions for those tasks there. Greetings Fred -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Help with a tough query
Egads you're right! I've been overthinking this. There must something else wrong in my query. Thanks for the hit over the head. I needed it. On Mar 16, 2004, at 10:37 AM, Harald Fuchs wrote: When you specify a left join, you will always get the same number of records as are in your primary join table (barring other filters). So a left join assures that I get all the events, but leaves out the related contacts and regards if there is more than one. What are you talking about? A left outer join gives you the same records as an inner join, plus one fake record for each row of the left table without a match in the right table. -- Brent Baisley Systems Architect Landover Associates, Inc. Search Advisory Services for Advanced Technology Environments p: 212.759.6400/800.759.0577 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: hard boot killed replication execution
Does anyone know what this replication Slave_SQL error means? Error initializing relay log position: Could not find target log during relay log initialization How do I specify the target log other than what I'm doing? See below for details. Daniel Gibby wrote: The problem isn't that it can't connect to the master. The IO is running fine. It is just the SQL slave thread that won't restart. I have looked in the server log and that just has a duplication of the message I get when I try to CHANGE MASTER TO RELAY_LOG_FILE=... Error initializing relay log position: Could not find target log during relay log initialization My master server was hard booted and now my slave can't execute the replicated binary sql logs. mysql show slave status\G *** 1. row *** Master_Host: post.somehost.com Master_User: replicator Master_Port: 3306 Connect_retry: 60 Master_Log_File: post-bin.118 Read_Master_Log_Pos: 651380657 Relay_Log_File: backups-relay-bin.025 Relay_Log_Pos: 4 Relay_Master_Log_File: post-bin.111 Slave_IO_Running: No Slave_SQL_Running: No Replicate_do_db: Replicate_ignore_db: Last_errno: 0 Last_error: Skip_counter: 1 Exec_master_log_pos: 462778298 Relay_log_space: 5987610630 1 row in set (0.00 sec) I can execute slave start and the IO will keep on running. (I think I had to execute some command to accomplish this, but it was a couple of weeks ago, and I don't remember what the command was.) mysql slave start; Query OK, 0 rows affected (0.00 sec) mysql show slave status\G *** 1. row *** Master_Host: post.somehost Connect_retry: 60 Master_Log_File: post-bin.118 Read_Master_Log_Pos: 651817308 Relay_Log_File: backups-relay-bin.025 Relay_Log_Pos: 4 Relay_Master_Log_File: post-bin.111 Slave_IO_Running: Yes Slave_SQL_Running: No Replicate_do_db: Replicate_ignore_db: Last_errno: 0 Last_error: Skip_counter: 1 Exec_master_log_pos: 462778298 Relay_log_space: 5988047320 1 row in set (0.00 sec) As you can see, my relay logs are starting to take up a _lot_ of space and I really need to start executing them or I'll never catch up. This is the contents of my directory where the logs are: -rw-rw1 mysqld mysqld 79 Oct 7 23:10 backups-bin.001 -rw-rw1 mysqld mysqld 79 Oct 10 08:47 backups-bin.002 etc -rw-rw1 mysqld mysqld 3035 Feb 9 14:18 backups-bin.023 -rw-rw1 mysqld mysqld573 Mar 8 18:41 backups-bin.024 -rw-rw1 mysqld mysqld 79 Mar 9 10:39 backups-bin.025 -rw-rw1 mysqld mysqld450 Mar 9 10:39 backups-bin.index -rw-rw1 mysqld mysqld 611349208 Mar 9 07:42 backups-relay-bin.024 -rw-rw1 mysqld mysqld 1073741983 Mar 10 08:52 backups-relay-bin.025 etc... -rw-rw1 mysqld mysqld 1073742041 Mar 15 11:12 backups-relay-bin.029 -rw-rw1 mysqld mysqld 19673092 Mar 15 11:34 backups-relay-bin.030 -rw-rw1 mysqld mysqld168 Mar 15 11:12 backups-relay-bin.index -rw-rw1 mysqld root 315954 Mar 15 11:31 backups.somehost.com.err -rw-rw1 mysqld mysqld 5 Mar 9 10:39 backups.somehost.com.pid -rw-rw1 mysqld mysqld 10485624 Mar 1 22:32 log.55 etc... -rw-rw1 mysqld mysqld9005000 Mar 15 11:14 log.63 drwx--2 mysqld mysqld 16384 Aug 18 2003 lost+found -rw-rw1 mysqld mysqld 81 Mar 15 11:34 master.info -rw-r--r--1 mysqld mysqld 5023 Mar 9 10:39 my.cnf drwx--2 mysqld mysqld 4096 Nov 18 06:52 mysql -rw-rw1 mysqld mysqld 59 Mar 9 11:13 relay-log.info and the directories for my databases. I used mysqlbinlog to check what the last part of the backups-relay-bin.024 contents were and queried and saw that it really has completed it's statements. Looking at the head of the backups-relay-bin.025 reveals that its queries haven't been executed. So I think I need to somehow change the server to start executing at 025, right? When I execute CHANGE MASTER TO RELAY_LOG_FILE='backups-relay-bin.025' RELAY_LOG_POS=4; I get this: ERROR 1105: Failed initializing relay log position: Could not find target log during relay log initialization What does that mean? I can't find documenation on it anywhere. Am I going about recovering this correctly? HELP! Thanks, Daniel Gibby -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: BETWEEN
Michael Stassen wrote: Jochem van Dieten wrote: However, I expect that would result in doing 2 rangescans and a merge. It might be even faster to use: SELECT * FROM sys WHERE sectorID BETWEEN 1 AND 42 AND sectorID NOT BETWEEN 21 AND 29; That would result in 1 rangescan and a filter. But a lot depends on the schema and cardinality. I'm curious. Could you explain this further? If this works by grabbing 1 to 42, then dropping 21 to 29, wouldn't this increase the likelihood (without knowing anything about the data) of crossing the 30% threshhold and doing a tablescan instead of using the index, relative to asking for 1 to 20 plus 30 to 42? Yes. But how relevant is that if the entire table fits on one page and is a tablescan necessarily slower then an indexscan when returning 29% of the table? On the other hand, if you already know that 1 to 20 and/or 30 to 42 exceeds 30%, then one tablescan is better than 2. Is that what you mean? That was the scenario I had in mind. Also, if we ignore the UNION version and look at the two BETWEENs, are you saying that WHERE sectorID BETWEEN 1 AND 20 OR sectorID BETWEEN 30 AND 42; will be treated differently than WHERE sectorID BETWEEN 1 AND 42 AND sectorID NOT BETWEEN 21 AND 29; by the optimizer? No, I am saying that depending on cardinality and schema it might be treated differently. Jochem -- I don't get it immigrants don't work and steal our jobs - Loesje -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
getting off list
Hello. How do I get removed from the mysql e-mail list? Thanks, toney _ FREE pop-up blocking with the new MSN Toolbar get it now! http://clk.atdmt.com/AVE/go/onm00200415ave/direct/01/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: ORACLE to MySQL migration
Try SQLyog - http://www.webyog.com/sqlyog Karam --- [EMAIL PROTECTED] wrote: Hello colleagues, I have to migrate a lot of ORACLE 8.1.7 databases to MySQL 3.23 I'm looking for a tool or for an algorithm which fully supports any ORACLE structures ... If needed I may use a commercial tool, otherwise a free software / shared software should be very appreciated Can anyone give me some suggestions? thanks a lot Enrico -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] __ Do you Yahoo!? Yahoo! Mail - More reliable, more storage, less spam http://mail.yahoo.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: getting off list
On Tue, 16 Mar 2004 09:45:46 -0800, T Si [EMAIL PROTECTED] wrote: Hello. How do I get removed from the mysql e-mail list? It's at the bottom of each email you receive from the list. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
SELECT/UPDATE and locking issue
Hi, all. I'm doing the following on MySQL 4.0.18: LOCK TABLES b WRITE, a READ LOCAL; SELECT a.id FROM a LEFT JOIN b ON b.id = a.id WHERE a.type = 'foo' AND a.action = 'T' AND b.status IS NULL; UPDATE b SET status = 'Q' WHERE id IN ([list of ids from SELECT]); UNLOCK TABLES; Then I loop through the ids, performing various actions and updating b with the result. There's obviously something wrong here, because now that our volume has ramped up, I'm seeing what looks to be a locking issue. After the UNLOCK, I do a sanity check, comparing the number of ids from the SELECT to the number of rows matched in the UPDATE. The SELECT sometimes returns more rows than the UPDATE, leading me to believe that I need a WRITE lock on a (I thought the WHERE clause view of b.status solved the issue, but obviously not). This is a logging application, and a sees a ton of INSERTs, so I obviously want to avoid WRITE locking it if possible. Is this The Right Way To Do It, or can I somehow combine the SELECT and the update into a single step, returning a list of ids? I can't use subselects, and I can't imagine the table replacement mentioned in the Cookbook (pp.647-648) is a good candidate in this scenario. Eamon Daly NextWave Media Group LLC Tel: 1 773 975-1115 Fax: 1 773 913-0970 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: can I get MySQL Source code under Windows OS?
Arunachalam [EMAIL PROTECTED] wrote: I have downloaded *bk-3.0.4-x86-win32.EXE* from URL: http://www.bitmover.com/download, for windows When I try to install it ask for; *** This release of BitKeeper requires the Cygwin version 1.5.5 . If you have already installed a older cygwin release, you should upgrade to cygwin 1.5.5 *WARNING*: This install script will force all cygwin mount table entries to binary mode. You should skip this if you have customized mount setting. Do you want to install cygwin 1.5.5 now? (Cygwin is comes under unix!!) If I press Yes -- it further say error An I/O error occured while installing a file.This is normally cauesd by bad installation media or a corrupt istallation file. and shows ABORT and RETRY button, if I press RETRY it never improve in installation just stay idle... and If I press ABORT it get aborted. Also when I visit the URL http://www.mysql.com/doc/en/Installing_source_tree.html and it seems that instructions given for working under Unix platform - right? Could I get the Source code of MySQL for testing with Windows?... If you want to install MySQL from the latest development source tree, you should first make Windows source package and then compile it: http://www.mysql.com/doc/en/Windows_BitKeeper_Build.html http://www.mysql.com/doc/en/Windows_VC++_Build.html -- 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]
ROWNUM in mysql
How can I select a mysql version of the Oracle 'rownum' inside a SQL statement? I need to include this for a ranking type functionality - but I don't see this type of analytic functionality. Any help would be appreciated. David
Re: 4.1.2.?
Mirza [EMAIL PROTECTED] wrote: Is there any info on when 4.1.2 is to be released? Soon. It will be released in two or three weeks. -- 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]
Blocking INSERT/UPDATE on SLAVE (replication)
Hi there. How could I deny users or applications issuing INSERT or UPDATEs queries on my SLAVE server? This is intended to ensure that slave will not have data which MASTER don't know. Thanks... []s, Conrado -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: getting off list
We are programmed to receive You can signup anytime you like, but you can never leave. T Si wrote: Hello. How do I get removed from the mysql e-mail list? Thanks, toney _ FREE pop-up blocking with the new MSN Toolbar get it now! http://clk.atdmt.com/AVE/go/onm00200415ave/direct/01/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Administrator
Newsletter wrote: After install the MySQL Administrator version 1.0.2b alpha there is an error about a msvcr70.dll not found. This problem was found in Windows 98SE and Windows 2000 server systems. Thanks for your attention Reinaldo Melo Filho from Brazil I searched for that dll on google and downloaded it from the first link I saw. That probably wasn't a good decision security-wise, but it worked :) Dan -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Wish List of Features
I downloaded MySQL and began playing with it. It is a very impressive program and many awards should go to everyone who has ever worked on this project. :-) Since I'm mainly just playing around with the server right now I could never be considered a real user until I've created a few databases and have gotten into the feel of MySQL. Still, after having played with it (and mysqlcc) for a while - there were a few things I wanted to ask about. Especially since these features might already exist and I just haven't gotten to them in the MySQL book. (I'm using the Paul DuBois book.) I used to use FoxBase+ quite a bit and eventually, where I work, I wrote several database applications using my own code. One of the things I found very useful was: 1. LIST STRUCTURE. Which would dump an exact copy of the commands used to create a table in a database. Thus, in MySQL, this command would display the correctly coded CREATE TABLE command for each table. This command used to be in FoxBase+ and I have found it very useful several times. I know about the SHOW COLUMNS command - it is not the same although I could write some code to extract it and then create the CREATE TABLE command from it. (This is just one of those ease of use/convience things.) The second thing I can not figure out, is how to rearrange my entries in the table. In MySQLCC, I can not find any command which will allow me to move items up and down in the list. Granted that, if there is data in the database, this could cause problems - but if you are just trying to set up a database and you go Oops! I forgot to put in X - you can not put X anywhere except at the very bottom of the list. So my next thing is a question: 2. Is there a way to reorganize your table's layout in MySQLCC? Or do I have to delete the entire table and start over? Again, I am pulling from my FoxBase+ background. In FoxBase+ you can insert new fields into the table and what it would do in the background is to change the name of the table to a temporary name, build the new field list, and then port the old table over to the new one and get rid of the temporary table. This is (again) an ease of use/convience thing. A script could be written to do this I suppose but then I'd still have to create the new table, get out of mysqlcc, run the script, and then get back in again. It would be nicer if mysqlcc had this built in. (I hope! :-) ) TIA! To whomever answers this message. :-) Mark -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Blocking INSERT/UPDATE on SLAVE (replication)
First, do not replicate the MySQL database from the master to the slave(s). Then create users on the slave that only have the desired rights. In your case, SELECT only. Original Message On 3/16/04, 2:02:13 PM, cvarda [EMAIL PROTECTED] wrote regarding Blocking INSERT/UPDATE on SLAVE (replication): Hi there. How could I deny users or applications issuing INSERT or UPDATEs queries on my SLAVE server? This is intended to ensure that slave will not have data which MASTER don't know. Thanks... []s, Conrado -- 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]
Optimise two mysql queries to one query
Hello, $a = mysql_query(Select a,b FROM t WHERE category=1) while($a) { $x = $a[a]; //some echo //another query $b = mysql_query(Select * FROM t WHERE subcategory=$x) while ($b) { //some echo } } Poent is thet I have menus, parents with childes (childes are not parents) and I want to display them using only one query. - Parent 1 -- Child 1 -- Child 2 - Patent 2 -- Child 3 Child have subid that is parent id. TNX -- Please do not CC me. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
revoke question
I was trying to allocate a new user and I typed something like: grant all privileges on pail to [EMAIL PROTECTED] identified by 'hill'; I realized I made a mistake needing to specify (at least) 'pail.*', intending to grant the user access to a database I created. So to clean up I tried: revoke all privileges on mysql.pail from jill; ERROR 1141: There is no such grant defined for user 'jill' on host '%' In the privilege tables there is an entry for the user in 'user' and an entry in 'tables_priv'. Nothing any where else. The entries look reasonable (to me). In user: all privileges='N'; In pail: Table_priv: Select,Insert,Update,Delete,Create,Drop,References,Index,Alter I assume this is my error and I can remove the two entries manually but I would like to know what I am doing wrong. _ Douglas Denault [EMAIL PROTECTED] Voice: 301-469-8766 Fax: 301-469-0601 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Blocking INSERT/UPDATE on SLAVE (replication)
I'm currently replicating all databases, so this would happen. This means that I should change my setup to do not replicate the 'mysql' database. Is there a way to explicity do not replicate only 'mysql' and replicate all others, including new databases? []s, Conrado - Original Message - From: Alan Williamson [EMAIL PROTECTED] To: cvarda [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 5:30 PM Subject: Re: Blocking INSERT/UPDATE on SLAVE (replication) cvarda wrote: But this wouldn't conflict with 'mysql' database replication? Changes on the master users would override my setup on the slave... am I wrong? yes you are wrong :) you only mirror/replicate certain DATABASES, not the whole server. Therefore you wouldn't not mirror the 'mysql' database as this would then cause the problems you describe. Only mirror the database with your real data -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Wish List of Features
1) Try, SHOW CREATE TABLE table_name from the mysql client utility. It will give you a create-table command. In MySQL Control Center, you can do the same thing, but for all tables at once. Select the database with your tables, and open the tree. Right click on the Tables item, and choose, Tools-Show Create and then select one, some, or all of the tables in the dialog that pops up. 2) That would be a useful feature for tables without alot of data, but if you have a few gig in your database, or had limited disk space, or had a busy server, it could be a disaster. Table order is nice, but try not to be too anal about it :) Most databases won't let you do that. David. - Original Message - From: Mark Manning [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 7:38 AM Subject: Wish List of Features I downloaded MySQL and began playing with it. It is a very impressive program and many awards should go to everyone who has ever worked on this project. :-) Since I'm mainly just playing around with the server right now I could never be considered a real user until I've created a few databases and have gotten into the feel of MySQL. Still, after having played with it (and mysqlcc) for a while - there were a few things I wanted to ask about. Especially since these features might already exist and I just haven't gotten to them in the MySQL book. (I'm using the Paul DuBois book.) I used to use FoxBase+ quite a bit and eventually, where I work, I wrote several database applications using my own code. One of the things I found very useful was: 1. LIST STRUCTURE. Which would dump an exact copy of the commands used to create a table in a database. Thus, in MySQL, this command would display the correctly coded CREATE TABLE command for each table. This command used to be in FoxBase+ and I have found it very useful several times. I know about the SHOW COLUMNS command - it is not the same although I could write some code to extract it and then create the CREATE TABLE command from it. (This is just one of those ease of use/convience things.) The second thing I can not figure out, is how to rearrange my entries in the table. In MySQLCC, I can not find any command which will allow me to move items up and down in the list. Granted that, if there is data in the database, this could cause problems - but if you are just trying to set up a database and you go Oops! I forgot to put in X - you can not put X anywhere except at the very bottom of the list. So my next thing is a question: 2. Is there a way to reorganize your table's layout in MySQLCC? Or do I have to delete the entire table and start over? Again, I am pulling from my FoxBase+ background. In FoxBase+ you can insert new fields into the table and what it would do in the background is to change the name of the table to a temporary name, build the new field list, and then port the old table over to the new one and get rid of the temporary table. This is (again) an ease of use/convience thing. A script could be written to do this I suppose but then I'd still have to create the new table, get out of mysqlcc, run the script, and then get back in again. It would be nicer if mysqlcc had this built in. (I hope! :-) ) TIA! To whomever answers this message. :-) Mark -- 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: Wish List of Features
You already can insert a column before or after another column. ALTER TABLE blah_table ADD COLUMN column_new VARCHAR(25) AFTER column_existing; Don't count on my syntax being perfect, but it is pretty easy to do what you are saying using the MySQL client Daniel Gibby David Griffiths wrote: 1) Try, SHOW CREATE TABLE table_name from the mysql client utility. It will give you a create-table command. In MySQL Control Center, you can do the same thing, but for all tables at once. Select the database with your tables, and open the tree. Right click on the Tables item, and choose, Tools-Show Create and then select one, some, or all of the tables in the dialog that pops up. 2) That would be a useful feature for tables without alot of data, but if you have a few gig in your database, or had limited disk space, or had a busy server, it could be a disaster. Table order is nice, but try not to be too anal about it :) Most databases won't let you do that. David. - Original Message - From: Mark Manning [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 7:38 AM Subject: Wish List of Features I downloaded MySQL and began playing with it. It is a very impressive program and many awards should go to everyone who has ever worked on this project. :-) Since I'm mainly just playing around with the server right now I could never be considered a real user until I've created a few databases and have gotten into the feel of MySQL. Still, after having played with it (and mysqlcc) for a while - there were a few things I wanted to ask about. Especially since these features might already exist and I just haven't gotten to them in the MySQL book. (I'm using the Paul DuBois book.) I used to use FoxBase+ quite a bit and eventually, where I work, I wrote several database applications using my own code. One of the things I found very useful was: 1. LIST STRUCTURE. Which would dump an exact copy of the commands used to create a table in a database. Thus, in MySQL, this command would display the correctly coded CREATE TABLE command for each table. This command used to be in FoxBase+ and I have found it very useful several times. I know about the SHOW COLUMNS command - it is not the same although I could write some code to extract it and then create the CREATE TABLE command from it. (This is just one of those ease of use/convience things.) The second thing I can not figure out, is how to rearrange my entries in the table. In MySQLCC, I can not find any command which will allow me to move items up and down in the list. Granted that, if there is data in the database, this could cause problems - but if you are just trying to set up a database and you go Oops! I forgot to put in X - you can not put X anywhere except at the very bottom of the list. So my next thing is a question: 2. Is there a way to reorganize your table's layout in MySQLCC? Or do I have to delete the entire table and start over? Again, I am pulling from my FoxBase+ background. In FoxBase+ you can insert new fields into the table and what it would do in the background is to change the name of the table to a temporary name, build the new field list, and then port the old table over to the new one and get rid of the temporary table. This is (again) an ease of use/convience thing. A script could be written to do this I suppose but then I'd still have to create the new table, get out of mysqlcc, run the script, and then get back in again. It would be nicer if mysqlcc had this built in. (I hope! :-) ) TIA! To whomever answers this message. :-) Mark -- 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: Blocking INSERT/UPDATE on SLAVE (replication)
Add the following line to you slave my.cnf file: replicate-ignore-db=mysql Original Message On 3/16/04, 2:44:53 PM, cvarda [EMAIL PROTECTED] wrote regarding Re: Blocking INSERT/UPDATE on SLAVE (replication): I'm currently replicating all databases, so this would happen. This means that I should change my setup to do not replicate the 'mysql' database. Is there a way to explicity do not replicate only 'mysql' and replicate all others, including new databases? []s, Conrado - Original Message - From: Alan Williamson [EMAIL PROTECTED] To: cvarda [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 5:30 PM Subject: Re: Blocking INSERT/UPDATE on SLAVE (replication) cvarda wrote: But this wouldn't conflict with 'mysql' database replication? Changes on the master users would override my setup on the slave... am I wrong? yes you are wrong :) you only mirror/replicate certain DATABASES, not the whole server. Therefore you wouldn't not mirror the 'mysql' database as this would then cause the problems you describe. Only mirror the database with your real data -- 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: Blocking INSERT/UPDATE on SLAVE (replication)
Thank you. I though it could have a way to avoid updates/inserts without touching my 'mysql' database, so it would be a permanent, exact copy of my master server. []s, Conrado - Original Message - From: [EMAIL PROTECTED] To: cvarda [EMAIL PROTECTED] Cc: Alan Williamson [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 6:14 PM Subject: Re: Blocking INSERT/UPDATE on SLAVE (replication) Add the following line to you slave my.cnf file: replicate-ignore-db=mysql Original Message On 3/16/04, 2:44:53 PM, cvarda [EMAIL PROTECTED] wrote regarding Re: Blocking INSERT/UPDATE on SLAVE (replication): I'm currently replicating all databases, so this would happen. This means that I should change my setup to do not replicate the 'mysql' database. Is there a way to explicity do not replicate only 'mysql' and replicate all others, including new databases? []s, Conrado - Original Message - From: Alan Williamson [EMAIL PROTECTED] To: cvarda [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 5:30 PM Subject: Re: Blocking INSERT/UPDATE on SLAVE (replication) cvarda wrote: But this wouldn't conflict with 'mysql' database replication? Changes on the master users would override my setup on the slave... am I wrong? yes you are wrong :) you only mirror/replicate certain DATABASES, not the whole server. Therefore you wouldn't not mirror the 'mysql' database as this would then cause the problems you describe. Only mirror the database with your real data -- 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: Blocking INSERT/UPDATE on SLAVE (replication)
Another way you can do something similar, rather than messing around with permissions is to use the read-only option. This option exists in MySQL 4.0+. It prevents anyone except for the mysql root user or the replication thread from being able to change data -- regardless of their permissions. You can even set it on the fly with something like: SET GLOBAL read_only = 1; Regards, Harrison On Tue, 16 Mar 2004, cvarda wrote: I'm currently replicating all databases, so this would happen. This means that I should change my setup to do not replicate the 'mysql' database. Is there a way to explicity do not replicate only 'mysql' and replicate all others, including new databases? []s, Conrado - Original Message - From: Alan Williamson [EMAIL PROTECTED] To: cvarda [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 5:30 PM Subject: Re: Blocking INSERT/UPDATE on SLAVE (replication) cvarda wrote: But this wouldn't conflict with 'mysql' database replication? Changes on the master users would override my setup on the slave... am I wrong? yes you are wrong :) you only mirror/replicate certain DATABASES, not the whole server. Therefore you wouldn't not mirror the 'mysql' database as this would then cause the problems you describe. Only mirror the database with your real data -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: ORACLE to MySQL migration
Perl/DBI is a possibility. --Walt -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 8:48 AM To: [EMAIL PROTECTED] Subject: ORACLE to MySQL migration Hello colleagues, I have to migrate a lot of ORACLE 8.1.7 databases to MySQL 3.23 I'm looking for a tool or for an algorithm which fully supports any ORACLE structures ... If needed I may use a commercial tool, otherwise a free software / shared software should be very appreciated Can anyone give me some suggestions? thanks a lot Enrico -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/mysql? [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
just the list please!
Can people please just email the list and not the person *AND* the list!!! i get duplicate emails and its very annoying to what is a great list so far. kinda puts me off from answering peoples questions! thanks! :) - Original Message - From: Alan Williamson [EMAIL PROTECTED] To: cvarda [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 5:30 PM Subject: Re: Blocking INSERT/UPDATE on SLAVE (replication) -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
PHP and using mysql_last_id()
Hi can anyone tell me how to use php's mysql_last_id() or MySQL's INSERT_LAST_ID I have a page registration page, using a username, password and member level text box. I want to send the user (upon successful insert) to a member's detail form where the password table primary key is avaliable it can be kept and entered to subsequent tables as a Foriegn Key. But when I have tried it all I ever get is a value of 1. I have looked at the manuals online and found a couple of books that list these functions, and understand the syntax qnd what it does, but can not find a working example or inducation as to where it goes etc any pointers would be much appreciated stu -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: PHP and using mysql_last_id()
Hi can anyone tell me how to use php's mysql_last_id() or MySQL's INSERT_LAST_ID - php's function is mysql_insert_id() and not mysql_last_id(), there is no php function called mysql_last_id()...if you saw that in a manual, i'd email the owner of the document. http://php.net/mysql_insert_id hth Jeff _ I have a page registration page, using a username, password and member level text box. I want to send the user (upon successful insert) to a member's detail form where the password table primary key is avaliable it can be kept and entered to subsequent tables as a Foriegn Key. But when I have tried it all I ever get is a value of 1. I have looked at the manuals online and found a couple of books that list these functions, and understand the syntax qnd what it does, but can not find a working example or inducation as to where it goes etc any pointers would be much appreciated stu -- 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: just the list please!
On 16 Mar 2004, at 21:31, Alan Williamson wrote: Can people please just email the list and not the person *AND* the list!!! i get duplicate emails and its very annoying to what is a great list so far. kinda puts me off from answering peoples questions! This is something the list admins might be able to sort out. It's common for mailing lists to set a reply-to header, so that replies automatically go to the list, and not to the originating poster (all the mailing lists that I run do so) but this list does not. Tim -- Dr Tim Cutts Informatics Systems Group Wellcome Trust Sanger Institute Hinxton, Cambridge, CB10 1SA, UK -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: PHP and using mysql_last_id()
sgannon60 wrote: Hi can anyone tell me how to use php's mysql_last_id() or MySQL's INSERT_LAST_ID I personnaly think mysql_last_id will never work..., but try mysql_insert_id() This will generate the ID of the PREVIOUS insert query. So it has to be mysql_insert_id()+1 Alex -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: just the list please!
On Tuesday 16 March 2004 02:19 pm, Tim Cutts wrote: This is something the list admins might be able to sort out. It's common for mailing lists to set a reply-to header... snip here we go again -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Wish List of Features
Hi Mark, 1. See the mysqldump utility. (separate to the mysqlcc and mysql). You can dump the whole server, a selected db, or table including or excluding the table data (ie structure only). eg. mysqldump -B mydb -a -d -uuser -p dumpfile.sql will dump the structure of database mydb to file dumpfile.sql. (where user is the user used to connect to the DB). 2. In mysqlcc, when in edit mode, click on the entry you wish to insert the new field before, then click new field on the toolbar. This will insert a new field before the one you selected. Being honest, don't worry too much about the table structure. I know I don't. Yours Sincerely Darran -Original Message- From: Mark Manning [mailto:[EMAIL PROTECTED] Sent: Wednesday, 17 March 2004 01:38 To: [EMAIL PROTECTED] Subject: Wish List of Features I downloaded MySQL and began playing with it. It is a very impressive program and many awards should go to everyone who has ever worked on this project. :-) Since I'm mainly just playing around with the server right now I could never be considered a real user until I've created a few databases and have gotten into the feel of MySQL. Still, after having played with it (and mysqlcc) for a while - there were a few things I wanted to ask about. Especially since these features might already exist and I just haven't gotten to them in the MySQL book. (I'm using the Paul DuBois book.) I used to use FoxBase+ quite a bit and eventually, where I work, I wrote several database applications using my own code. One of the things I found very useful was: 1. LIST STRUCTURE. Which would dump an exact copy of the commands used to create a table in a database. Thus, in MySQL, this command would display the correctly coded CREATE TABLE command for each table. This command used to be in FoxBase+ and I have found it very useful several times. I know about the SHOW COLUMNS command - it is not the same although I could write some code to extract it and then create the CREATE TABLE command from it. (This is just one of those ease of use/convience things.) The second thing I can not figure out, is how to rearrange my entries in the table. In MySQLCC, I can not find any command which will allow me to move items up and down in the list. Granted that, if there is data in the database, this could cause problems - but if you are just trying to set up a database and you go Oops! I forgot to put in X - you can not put X anywhere except at the very bottom of the list. So my next thing is a question: 2. Is there a way to reorganize your table's layout in MySQLCC? Or do I have to delete the entire table and start over? Again, I am pulling from my FoxBase+ background. In FoxBase+ you can insert new fields into the table and what it would do in the background is to change the name of the table to a temporary name, build the new field list, and then port the old table over to the new one and get rid of the temporary table. This is (again) an ease of use/convience thing. A script could be written to do this I suppose but then I'd still have to create the new table, get out of mysqlcc, run the script, and then get back in again. It would be nicer if mysqlcc had this built in. (I hope! :-) ) TIA! To whomever answers this message. :-) Mark -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
MySQL Cluster Software
I recently saw and article that says MySQL will be shipping its cluster software starting April 14th during the Users Conference Expo this year. Does anyone have any information about this? My company is considering using the Emic clustering software. Has anyone had experience with that? Will the MySQL branded one be better? Thanks! Tom ONeill InfoWorld Article http://www.infoworld.com/article/04/03/12/HNmysqlcluster_1.html
Re: just the list please!
On 16 Mar 2004, at 22:30, Gabriel Guzman wrote: On Tuesday 16 March 2004 02:19 pm, Tim Cutts wrote: This is something the list admins might be able to sort out. It's common for mailing lists to set a reply-to header... snip here we go again Oops - is that a bad button to push? :-) If it's the policy of the list managers not to set the reply-to header, then so be it, and the OP will just have to put up with it! Some lists I subscribe to have the opposite extreme policy - no-one must reply to the list at all; they reply to the original poster, and then some time later the original poster posts a summary of the replies. Works quite well, and keeps the traffic down, but does take some discipline. Tim -- Dr Tim Cutts Informatics Systems Group Wellcome Trust Sanger Institute Hinxton, Cambridge, CB10 1SA, UK -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: just the list please!
on 3/16/04 1:31 PM, Alan Williamson at [EMAIL PROTECTED] wrote: Can people please just email the list and not the person *AND* the list!!! i get duplicate emails and its very annoying to what is a great list so far. kinda puts me off from answering peoples questions! Personally, I like em, the list is often slow, by a fact of a half hour at times, that is too long to wait for a message to show up. With the reply to list and sender, you get the answer faster, and you also help the list keep a good archive so others can be helped later. I think it would be very simple to create a rule in your email application to nuke the messages that you do not want. -- - Scott HanedaTel: 415.898.2602 http://www.newgeo.com Fax: 313.557.5052 [EMAIL PROTECTED]Novato, CA U.S.A. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: just the list please!
Scott Haneda wrote: on 3/16/04 1:31 PM, Alan Williamson at [EMAIL PROTECTED] wrote: Can people please just email the list and not the person *AND* the list!!! i get duplicate emails and its very annoying to what is a great list so far. kinda puts me off from answering peoples questions! Personally, I like em, the list is often slow, by a fact of a half hour at times, that is too long to wait for a message to show up. With the reply to list and sender, you get the answer faster, and you also help the list keep a good archive so others can be helped later. I think it would be very simple to create a rule in your email application to nuke the messages that you do not want. I agree. When someone has a MySQL problem, it is often urgent. While most of my posts to the list seem to appear withing a few minutes, I can remember many occasions when they took more than a few hours. What I have a problem with is people piggy-backing off other people's threads. If you have a new topic, start a new topic... -- signature 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: MySQL 4.0 - Download - Viruses ?
Kevin Carpenter wrote: While downloading this a I got a number of virus warnings from McAfee. I aborted the download. Anyone else experienced this? I emailed MySQL but didn't hear back. Kevin: Were you downloading a Windows or some other binary? If it was Windows, I would be concerned - the build machine could have gotten infected. The unfortunate thing is that MySQL build team could very easily miss it because so many Windows machines out there are already infected anyway that spreading a virus through the Windows binary would probably not make things that much worse. If it was some other binary, this is fairly common - by an odd coincidence tar.gz of MySQL binary contains byte strings similar to some viruses known to McAfee. There is no reasonable way a non-Windows tar.gz could infect a Windows machine. A theoretical possibility, of course, exists, but the Earth being hit by a large asteroid by tonight is more likely. -- 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]
LDAP Athenticaiton for MySQL
Hello Is there a way I can get a MySQL database to authenticate users against an LDAP database without any 3rd party coding? I want to store mysql usernames and passwords in ldap. Thanks Matt -- Matt Silva Empower Software Technologies, LLC 27851 Bradley Rd. Suite 120 Sun City, CA 92586 PH: (909) 672-6257 WB: www.storagecommander.com EM: [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
select statement question
I know this'll look scary : select distinct book.bid, title, price, condition, author.name, edition from book left join purchase on book.bid=purchase.bid left join student on 1 = 1 left join edition on edition.bid = book.bid left join author on 1 = 1 left join author_book on 1 = 1 where purchase.bid is null and book.bid = author_book.bid and author_book.aid = author.aid and gender=2 and title like '%java%' order by price The reason for the so many left joins is to avoid the nullification of a result in the situation where a table is empty (Yes, normal joins give an empty result if any tables participating in the join are empty). I want to make sure that the book is not purchased, so I left join to the purchase table, then choose the results with purchase.bid = NULL. I'm getting the following result TitleEditionAuthorPriceConditionjava how to program2deitel deitel11 JDUsed Which is good, except that this book is owned by a male. Gender = 1, regardless of the complexity of the above query. How am I getting a result with a male when my where clause contains a gender=2 (female)condition??? Is it a bug? or have I gotten rusty on SQL? Do you Yahoo!? Yahoo! Mail - More reliable, more storage, less spam
Re: Administrator
Hi, On Tue, 2004-03-16 at 21:23, Daniel Kasak wrote: Newsletter wrote: After install the MySQL Administrator version 1.0.2b alpha there is an error about a msvcr70.dll not found. This problem was found in Windows 98SE and Windows 2000 server systems. Thanks for your attention Reinaldo Melo Filho from Brazil I searched for that dll on google and downloaded it from the first link I saw. That probably wasn't a good decision security-wise, but it worked :) Dan You are right. This was already reported as a bug. (Bug #3178 Won't start and giving an error message) This will be fixed in the next release of course. Ulli -- Ulrich Bayer, GUI Developer MySQL AB, www.mysql.com Austria, Vienna Want to swim with the dolphins? (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]
create sequence
hello, I have mysql version 4.0.16. I am trying to create a sequence to use for a customer_id field. Anyway I try this ... CREATE SEQUENCE new_num start 1 increment 1 maxvalue 9223372036854775807 minvalue 1 cache 1; or just CREATE SEQUENCE new_num; and both give me a sytax error. What am I doing wrong? Thanks, -- jdavis [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: MySQL Cluster Software
Tom O'Neill (MySQL User) wrote: I recently saw and article that says MySQL will be shipping its cluster software starting April 14th during the Users Conference Expo this year. Does anyone have any information about this? My company is considering using the Emic clustering software. Has anyone had experience with that? Will the MySQL branded one be better? I've tried to set up EMIC clustering once for an experiment. Unfortunately, it required more system configuration changes that I was willing to implement. Cannot say much about what is coming from MySQL, but being open-source is a big plus. This means quicker user base growth, and wider and more in-depth testing. Additionally, MySQL has a reputation for a quick turnaround on bugs, which is still the case, even though the company has gotten quite a bit bigger and a lot more commercial business-oriented. I would, however, not try to depend on either for your application if at all possible, and build a simple custom solution yourself instead. Clustering for a known system is a much easier problem that building a generic cluster - you can take many application-specific shortcuts that would not be acceptable in a general case. -- 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]
OS X 10.3.3 and byte ordering update
I saw a little blip about issues with MySql when updateing OS X to 10.3.3. It seems the byte order has changed and you will have to export and import all your data. I got the impression this only applies to OS X Server, and not client, so only the MySql installed by Apple. Anyone have any more data on this, or is it safe to update to 10.3.3 on a OS X client machine? -- - Scott HanedaTel: 415.898.2602 http://www.newgeo.com Fax: 313.557.5052 [EMAIL PROTECTED]Novato, CA U.S.A. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Optimise two mysql queries to one query
dr zoidberg wrote: Hello, $a = mysql_query(Select a,b FROM t WHERE category=1) while($a) { $x = $a[a]; //some echo //another query $b = mysql_query(Select * FROM t WHERE subcategory=$x) while ($b) { //some echo } } Not tested and might need some tweaking in the where clause, but should be at least close to what you need: select t2.* from t t1, t t2 where t1.category=1 and t2.subcategory = t1.a -- 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 Training in the North West of UK
Andrew McCall wrote: ** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error you must delete it and notify the system manager (e-mail: [EMAIL PROTECTED]). This banner also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. http://www.oldham.gov.uk ** Hi Folks, Sorry of this is off-topic, but I am running out of places to look! I am trying to find training for MySQL in the UK, located in the north-west. The course must cover MySQL database and system administration. The person who would be going on the course already has a vast amount of Oracle and MS-SQL knowledge however they currently know nothing about MySQL. I have done a Google for some courses, but I can only find courses in London or the south. Does anyone know anyone/anywhere that can help me? Andrew: You might be able to make some special arrangements with the MySQL Training Team, especially if you find other users in your area interested in the training. -- 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: Processlist : state Writing to net
rekin's janky wrote: Hi listers, Using MySQL 4.0.15-max-debug on Windows 2000, I am working with perlscripts. When one of my program runs, I have an unexpected long time for one query which take at least 10 min (in the best case, but it stayed blocked most of the time) instead of 10 sec when the query is on the mysql command line (a SELECT query about 81000 lines). The command SHOW PROCESSLIST shows that the state of that command is Writing to net ! I don't see what that means and how I can find a solution ? Anybody can help me ? Try $sth-{mysql_use_result} = 1; before $sth-execute() The problem, I think, is that your client system starts swapping hard while trying to allocate enough memory to store 81,000 rows. -- 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: Got an error reading communication packets - ???
Arunachalam wrote: Hi MySQLians, After such a long span (nearly 1 month) of searching the solution for the server restart while executing C API prepared statments I found that the execution met the error in the server ; 040315 17:48:55 Aborted connection 2 to db: 'test' user: '' host: `localhost' (Got an error reading communication packets). Hope this is well known error to experianced MySQLians... Suggest me possible remedies for this error I am using MySQL 5.0.0-alpha for windows Windows 2000 Service Pack 4 MS VC++ 6.0 The error is actually a red herring. It is not likely that it has anything to do with the restart. This message happens when the client for some reason drops the connection, or when it's been idle for longer than wait_timeout seconds, and is fairly harmless. To track down server restart, log all of your queries/commands and find which one does it. Then try to find a way to duplicate it and submit a bug report. 5.0.0 is a very early alpha with a lot of new untested code (more alpha than 4.1.1, if that makes any sense), and server-crashing bugs would be more common. I still thing it is more stable than the average production mega-bucks database release, though. -- 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: Wish List of Features
Dude. http://www.phpmyadmin.net/ Daevid Vincent http://daevid.com -Original Message- From: Mark Manning [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 7:38 AM To: [EMAIL PROTECTED] Subject: Wish List of Features I downloaded MySQL and began playing with it. It is a very impressive program and many awards should go to everyone who has ever worked on this project. :-) Since I'm mainly just playing around with the server right now I could never be considered a real user until I've created a few databases and have gotten into the feel of MySQL. Still, after having played with it (and mysqlcc) for a while - there were a few things I wanted to ask about. Especially since these features might already exist and I just haven't gotten to them in the MySQL book. (I'm using the Paul DuBois book.) I used to use FoxBase+ quite a bit and eventually, where I work, I wrote several database applications using my own code. One of the things I found very useful was: 1. LIST STRUCTURE. Which would dump an exact copy of the commands used to create a table in a database. Thus, in MySQL, this command would display the correctly coded CREATE TABLE command for each table. This command used to be in FoxBase+ and I have found it very useful several times. I know about the SHOW COLUMNS command - it is not the same although I could write some code to extract it and then create the CREATE TABLE command from it. (This is just one of those ease of use/convience things.) The second thing I can not figure out, is how to rearrange my entries in the table. In MySQLCC, I can not find any command which will allow me to move items up and down in the list. Granted that, if there is data in the database, this could cause problems - but if you are just trying to set up a database and you go Oops! I forgot to put in X - you can not put X anywhere except at the very bottom of the list. So my next thing is a question: 2. Is there a way to reorganize your table's layout in MySQLCC? Or do I have to delete the entire table and start over? Again, I am pulling from my FoxBase+ background. In FoxBase+ you can insert new fields into the table and what it would do in the background is to change the name of the table to a temporary name, build the new field list, and then port the old table over to the new one and get rid of the temporary table. This is (again) an ease of use/convience thing. A script could be written to do this I suppose but then I'd still have to create the new table, get out of mysqlcc, run the script, and then get back in again. It would be nicer if mysqlcc had this built in. (I hope! :-) ) TIA! To whomever answers this message. :-) Mark -- 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]
Full-Text on double rows
If I got a full-text table with X rows, and some search takes 5 sec.. Now if I got a full-text table with 2X rows, how much time will take the same search on twice amount of rows? Is the difference linear??? thanks in advance, -Lorderon -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Full-Text on double rows
Lorderon wrote: If I got a full-text table with X rows, and some search takes 5 sec.. Now if I got a full-text table with 2X rows, how much time will take the same search on twice amount of rows? Is the difference linear??? thanks in advance, -Lorderon Which version of MySQL?? The difference will be different (!!) depending on the version in use. In general, full text search uses a tree-structure. Doubling the number of entries in the tree is likely to result in a time difference of not very much at all! Best regards, Chris -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Full-Text on double rows
Chris Nolan [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Which version of MySQL?? The difference will be different (!!) depending on the version in use. In general, full text search uses a tree-structure. Doubling the number of entries in the tree is likely to result in a time difference of not very much at all! Currently using version 4.0.16 but will move to 4.1 and 5 when they're released.. How it works on those versions? According to what you described as a tree-structure.. then spliting a big full-text table into 2 smaller tables and use UNION just makes the situation worse... thanks -Lorderon. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: PHP and using mysql_last_id()
Does php have a function like mysql_insert_id but support a zerofill auto increment int? ~Elle~ -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 17, 2004 5:19 AM To: [EMAIL PROTECTED] Subject: Re: PHP and using mysql_last_id() Hi can anyone tell me how to use php's mysql_last_id() or MySQL's INSERT_LAST_ID - php's function is mysql_insert_id() and not mysql_last_id(), there is no php function called mysql_last_id()...if you saw that in a manual, i'd email the owner of the document. http://php.net/mysql_insert_id hth Jeff _ I have a page registration page, using a username, password and member level text box. I want to send the user (upon successful insert) to a member's detail form where the password table primary key is avaliable it can be kept and entered to subsequent tables as a Foriegn Key. But when I have tried it all I ever get is a value of 1. I have looked at the manuals online and found a couple of books that list these functions, and understand the syntax qnd what it does, but can not find a working example or inducation as to where it goes etc any pointers would be much appreciated stu -- 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]
Re: PHP and using mysql_last_id()
It is better run a query with: SELECT LAST_INSERT_ID(); immediately after making the insert query. that way you'll get the exact ID.. Elly Wisata [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Does php have a function like mysql_insert_id but support a zerofill auto increment int? ~Elle~ -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 17, 2004 5:19 AM To: [EMAIL PROTECTED] Subject: Re: PHP and using mysql_last_id() Hi can anyone tell me how to use php's mysql_last_id() or MySQL's INSERT_LAST_ID - php's function is mysql_insert_id() and not mysql_last_id(), there is no php function called mysql_last_id()...if you saw that in a manual, i'd email the owner of the document. http://php.net/mysql_insert_id hth Jeff _ I have a page registration page, using a username, password and member level text box. I want to send the user (upon successful insert) to a member's detail form where the password table primary key is avaliable it can be kept and entered to subsequent tables as a Foriegn Key. But when I have tried it all I ever get is a value of 1. I have looked at the manuals online and found a couple of books that list these functions, and understand the syntax qnd what it does, but can not find a working example or inducation as to where it goes etc any pointers would be much appreciated stu -- 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]
Re[2]: PHP and using mysql_last_id()
Hello Lorderon, Wednesday, March 17, 2004, 3:39:35 AM, you wrote: L It is better run a query with: L SELECT LAST_INSERT_ID(); L immediately after making the insert query. that way you'll get the exact L ID.. Why? What difference does that give between using the PHP function that returns the last ID - other than the fact it takes another query on the database? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Set user password by using PowerBuilder
Hi, I am using the version 4.01 of MySQL and the Powerbuilder. I want to create a function in PowerBuilder which allows user to reset its MySQL password. Could anybody help me and give me some advices? -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Set user password by using PowerBuilder
Basically to set the password you want to effect a GRANT on the Table here is example mysql create database test_dummy; Query OK, 0 rows affected (0.00 sec) mysql grant all on test_dummy.* to dummy; Query OK, 0 rows affected (0.00 sec) mysql set password for 'dummy'=password('testpass'); Query OK, 0 rows affected (0.00 sec) mysql flush privileges; HTH, Martin - Original Message - From: TH Leung [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, March 16, 2004 11:24 PM Subject: Set user password by using PowerBuilder Hi, I am using the version 4.01 of MySQL and the Powerbuilder. I want to create a function in PowerBuilder which allows user to reset its MySQL password. Could anybody help me and give me some advices? -- 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: create sequence
I believe you want an AUTO_INCREMENT column. CREATE TABLE yourtable (customer_id AUTO_INCREMENT NOT NULL PRIMARY KEY, other_columns...); See the manual http://www.mysql.com/doc/en/CREATE_TABLE.html and http://www.mysql.com/doc/en/example-AUTO_INCREMENT.html for more. Michael jdavis wrote: hello, I have mysql version 4.0.16. I am trying to create a sequence to use for a customer_id field. Anyway I try this ... CREATE SEQUENCE new_num start 1 increment 1 maxvalue 9223372036854775807 minvalue 1 cache 1; or just CREATE SEQUENCE new_num; and both give me a sytax error. What am I doing wrong? Thanks, -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
New version of sql-bench is available from BitKeeper
Dear MySQL users, MySQL benchmark team is proud to announce availability of the new version of sql-bench suite. It is currently available only in BitKeeper tree, named mysql-bench. This is still development release and we would really appreciate your testing, bug reports as well as comments you might have. Please mail these to [EMAIL PROTECTED] For the additional instructions how to work with MySQL BitKeeper tree please refer to: http://www.mysql.com/doc/en/Installing_source_tree.html manual page. After couple of months of testing we plan to replace elder version currently shipped with MySQL distribution with this one. The command you can use to clone the mysql-bench tree is: bk clone bk://mysql.bkbits.net/mysql-bench mysql-bench To compile the tree you'll need to run: cd mysql-bench aclocal autoconf automake ./configure make To quickly run all tests with default options you may use ./run-all-tests script. The changes in this new sql-bench version include: - ability to run with large database sizes - support for new MySQL 4.0 and 4.1 features, such as UNION, Subqueries - AS3AP test - Separate Multi-User AS3AP test - Many new test cases -- Peter Zaitsev, Senior Support Engineer MySQL AB, www.mysql.com Meet the MySQL Team at User Conference 2004! (April 14-16, Orlando,FL) 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: revoke question
[EMAIL PROTECTED] wrote: I was trying to allocate a new user and I typed something like: grant all privileges on pail to [EMAIL PROTECTED] identified by 'hill'; Here you grant [EMAIL PROTECTED] all privileges on a table named pail. I realized I made a mistake needing to specify (at least) 'pail.*', intending to grant the user access to a database I created. So to clean up I tried: revoke all privileges on mysql.pail from jill; ERROR 1141: There is no such grant defined for user 'jill' on host '%' You didn't specify the host (localhost), so you got the default, which is %. You don't have a user named '[EMAIL PROTECTED]', however, so you got an error. In the privilege tables there is an entry for the user in 'user' and an entry in 'tables_priv'. Nothing any where else. The entries look reasonable (to me). In user: all privileges='N'; In pail: Table_priv: Select,Insert,Update,Delete,Create,Drop,References,Index,Alter I assume this is my error and I can remove the two entries manually but I would like to know what I am doing wrong. You can clean up with REVOKE ALL PRIVILEGES FROM [EMAIL PROTECTED] then use GRANT ALL ON pail.* to [EMAIL PROTECTED] identified by 'hill' to grant rights to the pail db. _ Douglas Denault [EMAIL PROTECTED] Michael -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Downgrade Mysql from 4 to 3.23
Hi, I am developing a database in mysql 4.Is it possible to downgrade the same into mysql 3.23.If its possible then how? -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: MySQL 4.0 - Download - Viruses ?
At 17:25 -0700 3/16/04, Sasha Pachev wrote: Kevin Carpenter wrote: While downloading this a I got a number of virus warnings from McAfee. I aborted the download. Anyone else experienced this? I emailed MySQL but didn't hear back. Kevin: Were you downloading a Windows or some other binary? If it was Windows, I would be concerned - the build machine could have gotten infected. The unfortunate thing is that MySQL build team could very easily miss it because so many Windows machines out there are already infected anyway that spreading a virus through the Windows binary would probably not make things that much worse. I hope everyone recognizes that this is speculation. If it was some other binary, this is fairly common - by an odd coincidence tar.gz of MySQL binary contains byte strings similar to some viruses known to McAfee. There is no reasonable way a non-Windows tar.gz could infect a Windows machine. A theoretical possibility, of course, exists, but the Earth being hit by a large asteroid by tonight is more likely. -- Sasha Pachev Create online surveys at http://www.surveyz.com/ -- 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: Set user password by using PowerBuilder
Thanks Martin, But, I want to know the script in PowerBuilder, because my current version of MySQL does not support store procedure, so I don't know how to code the set user password statements in PB. Basically to set the password you want to effect a GRANT on the Table here is example mysql create database test_dummy; Query OK, 0 rows affected (0.00 sec) mysql grant all on test_dummy.* to dummy; Query OK, 0 rows affected (0.00 sec) mysql set password for 'dummy'=password('testpass'); Query OK, 0 rows affected (0.00 sec) mysql flush privileges; HTH, Martin -Original Message- From: TH Leung Sent: Wednesday, March 17, 2004 12:24 PM To: '[EMAIL PROTECTED]' Subject: Set user password by using PowerBuilder Hi, I am using the version 4.01 of MySQL and the Powerbuilder. I want to create a function in PowerBuilder which allows user to reset its MySQL password. Could anybody help me and give me some advices? -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Problem in setting Table Level Privileges
Hi Everybody Commands: mysql -uroot mysql grant select,insert,update,delete on try.TBL_MACIP to 'tryAdmin1'@'localhost'; mysql -utryAdmin1 mysql use try mysql select * from TBL_MACIP; /etc/init.d/mysql restrat mysql -utryAdmin1 mysqluse try ERROR 1044 (42000): Access denied for user: ''@'localhost' to database 'try' mysqlshow grants for 'tryAdmin1'@'localhost'; No privilege is set. Using Server version 4.1.1-alpha-standard Protocol version10 Connection Localhost via UNIX socket UNIX socket /var/lib/mysql/mysql.sock OS i686 GNU/Linux (RH9) Used RPM to upgrade from 3.23 to 4.1.1 Should I send this problem as BUG? Any Suggestion/HELP!!! Thanks in Advance. with regards Udbhav Shah B.E (Computer Engg) Ahmedabad,Gujarat India = Thinking is the Assets Enterprise is the Way Hard Work is the Solution - Ignited Minds __ Do you Yahoo!? Yahoo! Mail - More reliable, more storage, less spam http://mail.yahoo.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]