Re: Documentation on character sets for version 4.0.17

2004-05-04 Thread David Jourard
Victoria ,

Thank-you.

At 01:35 PM 5/4/04 +0300, Victoria Reznichenko wrote:

David Jourard [EMAIL PROTECTED] wrote:

 I got the 4.0.17 documentation but when it discusses character sets it
 discusses this topic wrt 4.1

 Where can I find documentation specifically in regards to the production
 version on how to work with,  store, and search asian character sets
 specifically Japanese.

In version 4.0.17 you should specify character set with 
--default-character-set option. For Japanese language take a look at sjis 
and ujis character sets:
http://dev.mysql.com/doc/mysql/en/Character_sets.html


a. I'm working with a table where some fields are using the Latin 1 ch. 
set. and other fields using Japanese.

Can I work with both character sets?

Can I run a query with both or do they have to be separate.

b. Also the application is on a hosted web site so they do not have control 
over the settings of the mysql server.  How does one set the character 
set?  Is this done from the connection string or via the select query?

Thank-you
David J.
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.662 / Virus Database: 425 - Release Date: 4/20/04

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

Re: Documentation on character sets for version 4.0.17

2004-05-04 Thread David Jourard
Nils,

At 05:30 PM 5/4/04 +0100, you wrote:
Basically the best guess would be the documentation that comes with your
download. Note that online documents at www.mysql.com are always a mixture of
several documentation versions really.


Thats the problem.  Yesterday, I downloaded 4.0.1x yet the documentation 
that comes with it in regards to asian character set etc. is 4.1

But the application I'm working with is a perl/cgi/mysql thing on a virtual 
hosted site and is using 4.0.15 (which means I can only set things from the 
application level or via the connection string.)

I need to know how to set this up for this version not 4.1

From your documentation I gather I need to tell the server what character 
set to use and also about data coming from and going to the client.

My problem is I'm not too sure how to start.

Here is the data flow:

Storing Data

1. web page (uses shift_sjis) --
2. cgi app captures form data  with mixed fields eg. english and japanese
3. cgi app --- saves data to mixed fields in a table.
Is there something I do at the point data is being saved. Save one field in 
one kind of encoding and the other in another kind of coding.

OR is there something I indicate by a property of the field

Retrieving Data
---
1. cgi app searches on varchar fields both japanese and in english
2. cgi app searchs on text fields using fulltext engine for keyword searches.
Everything works fine for the english but the searches in japanese are not 
working.

I'm thinking maybe it has something to do with the encoding in the japanese 
fields which I'm not sure how to do at the field level for version 4.0.15

Thanks

David J.




---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.662 / Virus Database: 425 - Release Date: 4/20/04

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

Help with search on Japanese and version 4.015

2004-05-03 Thread David Jourard
Hi,

I'm implementing a search on fields some using the latin character set and 
others the Japanese character set; however because its virtually hosted I'm 
limited to using mysql 4.015

Is the documentation for this version online. I tried to find but could 
only get for the latest version which discusses search over different 
characters sets but specifically to 4.1.

Thank-you
David
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.662 / Virus Database: 425 - Release Date: 4/20/04

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

Documentation on character sets for version 4.0.17

2004-05-03 Thread David Jourard
Hi,

I got the 4.0.17 documentation but when it discusses character sets it 
discusses this topic wrt 4.1

Where can I find documentation specifically in regards to the production 
version on how to work with,  store, and search asian character sets 
specifically Japanese.

Thank-you
David Jrt; x-avg-checked=avg-ok-8ED7DEB
Content-Disposition: inline
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.662 / Virus Database: 425 - Release Date: 4/20/04
-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Japanese in version 4.0

2004-01-25 Thread David Jourard
Hi,

I need to implement a search in japanese (and also in english).

Can 4.0 accept japanese characters and sort them

From the documentation I see that it supports:

EUC-JP Japanese  or Shift-JIS Japanese

a. What are the differences btw the two.

b. How do i get the mysql to implement the sort.

c. Does the mysql have to be configured to support these characters sets

Any advise for a first-timer in this area is appreciated.

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


Setup Query to search smallest subset on a Conditional And?

2002-10-21 Thread David Jourard
Hi,

In previous e-mail I asked how to improve a word search and used some of 
the suggestions. Now I'm doing a 2 word search and need a little advice.

Background:

There are 2 tables: word and content.

content consists of 2 fields:

   rec_id int(11) unsigned not null,
   description varchar(200) not null


word consists of 2 fields:
 word int(11) unsigned not null,
 rec_id int(11) unsigned not null

word is created from content.  Each actual word from the field
content.description is created as a record in the table word with its rec_id.

The field word.word is the CRC of the actual word hence the integer type.


I've setup a query as such for  the words: new york

There are ~70,000 records with the word new, and ~10,000 with the word new.

Query is:
select description from content, word w1, word w2 where w1.word=1810056261 
and w1.rec_id=content.rec_id and w2.word=3012632499 and 
w2.rec_id=content.rec_id ORDER BY w1.word, w2.word;

When I do an explain it shows that its checking over ~80,000 records

+-+++-+-+--- 
+---+-+
| table   | type   | possible_keys  | key | key_len | 
ref   | rows  | Extra   |
+-+++-+-+--- 
+---+-+
| w2  | ref| word_index1| word_index1 |   4 | 
const | 10982 | where used  |
| content | eq_ref | PRIMARY,content_index1 | PRIMARY |   4 | 
w2.rec_id | 1 | Using index |
| w1  | ref| word_index1| word_index1 |   4 | 
const | 84725 | where used  |
+-+++-+-+--- 
+---+-+

My question:  Is it possible to setup the query to tell mysql to search the 
smallest subset only when you have a conditional AND in this kind of join.

Thanks in advance.

regards
David



-
Before posting, please check:
  http://www.mysql.com/manual.php   (the manual)
  http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



Maximize Performance by Improving Search Program Logic - Help?

2002-10-09 Thread David Jourard

Hi,


I need to improve the performance of a 1-word search engine
which I've created.  Currently the RAM is 1 GIG and the key_buffer is set at
512 MB which has improved the search results but I think perhaps I can improve
my method of search with your help perhaps.  The program is coded to run in 
mod_perl or just perl.

It consists of 2 tables: word and content.

content consists of 2 fields:

rec_id int unsigned not null,
description varchar(200) not null


word consists of 2 fields:
  word varchar(50) not null,
  rec_id int unsigned not null

word is created from content.  Each actual word from the field
content.description is created as a record in the table word with its rec_id.

Both tables are indexed on rec_id and word respectively.

A keyword is entered such as book.

The search consists of 2 SQL queries

Query 1: select rec_id from word where word='book';

All the rec_ids are captured into an array.

Query2: select description from content where rec_id=?

I then loop over the rec_ids stored in the array @codes.

   my $SqlCmd = 'select description from content where rec_id=?';
   my $sth = $dbh-prepare( $SqlCmd );
   $sth-{'mysql_use_result'} = 1; # doesn't store entire result

   while ( $continue ) {

  if ($njk  $#codes) { last; }

  $cd = $codes[$njk++];
  $sth-execute($cd);
  @row = $sth-fetchrow_array;

  # Collect results for display etc ...

}
$sth-finish;

Test Results:
   Query 1   Query 2
pottery (915 records)   0 sec 1 sec
book (12456 records)0 sec13 sec
computer (21999 records)1 sec21 sec


Question: Is there a better way of doing this with respect to:
A. My definition of fields and their types.
B. My queries  - it seems that Query 2 could perhaps be made
   faster.

I thank you in advance.  It is my hope to increase to 2, 3 and 4 word searches
once I've maximized the above search logic.

regards
David Jourard



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: Perl Interface

2002-03-01 Thread David Jourard

Mike,

http://www.gossamer-threads.com/scripts/mysqlman/index.htm

Its good.

David

At 11:51 AM 3/1/02 -0500, Mike Baranski wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I was wondering if anyone knows of a module for perl to talk to mysql w/o
DBI/DBD.  Some sort of shell interface or something.

Mike.
- --
*
* Mike Baranski *
* Security Managment Consulting *
* 919-788-9200 Phone*
* 919-510-0037 Fax  *
* [EMAIL PROTECTED]  *
*

GPG Key located on:
http://www.keyserver.net/en/
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE8f7Gun0XmoxBj3PwRAtMUAJ9Gz5DwcpbD0lIJN4x2+jOKoH24/wCfT+LL
STwfIAAPDxZ+khMFylKkGgs=
=mmex
-END PGP SIGNATURE-

-
Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail 
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Best Free Web Panel for mySQL

2001-12-13 Thread David Jourard

Hi,

Could someone recommend the best perl web panel to maintain the databases 
and tables for mysql.

Something similar to phpMyAdmin but in perl.

Thank-you
David

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php