Search Chinese Simplified
Hello, everyone. I would like to ask something about searching Chinese simplified characters from the database. Every time I searched, it won't display data,but if I searched without a condition it displayed all data including Chinese simplified characters.
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Simplified
UPDATE bookings AS b,rallies AS r SET b.charged=TRUE, r.charged=TRUE WHERE b.rally_id='123' AND r.rally_id='123' There will be multiple matches on rally_id in the bookings table and only one in the rallies table. This seems to be crying out for a JOIN but I can't figure it. It's that double 'rally' comparison in the WHERE clause that's bothering me.
Financing Simplified
I want to let you see this Homeowner You have been pre-approved for a $491,327 Home Loan at a 3.76 Fixed Rate. This offer is being extended to you unconditionally and your credit is in no way a factor. To take Advantage of this Limited Time opportunity All we ask is that you visit our Website and complete The 1 minute post Approval Form http://FWwAUKgiT.discount-financing...x/ryn/taYvgtYbY
Chinese Chars OK
I have mysql 5 and php 5.1.2 with chinese chars in utf8 on mysql. Browsing the tables in phpmyadmin shows correct chinese characters. However, a custom php page to display them shows only ??? At the top of my php page I did include: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http:// www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
Chinese Characters
I use 'LOAD DATA INFILE'. bUT can not load Chinese characters from a txt file to a table
Importing Chinese Characters
I've got a problem with importing chinese characters into a mysql-table and have read several mailings but didn't find a solution. i have a utf-8 text file that contains chinese characters. the table where i want to import the data using "load data local infile" has collation utf8_unicode_ci. but after the import is done, the chinese characters are converted into so strange characters. to show the chinese symbols in a php-script i use mb_convert_encoding() which shows me the characters properly, but the problem is that i have to order by the col that contains the chinese characters, so the chinese characters mustn't be converted after importing. when i use the form in phpmyadmin to add data it is possible to store the characters properly. is there a way to achieve this by using load data local infile?
Can't Insert Chinese Characters
In my local machine, I am using: ASP.NET 1.1 MySql 5.0 MySQL Connector Net 1.0.6 I can retrieve and update tables contain Chinese characters without problems. But when I pushed everything into the hosting site, I can retrieve but can't insert or update Chinese characters. It will show "?" instead. The hosting site is using MySQL 4.1.14.
Chinese Characters - UTF8
I am attempting to store Chinese text in a table with UTF-8 encoding and utf8_general_ci collation. After being stored, they are retrieved and displayed on a web page. On that page, which is properly set to use the UTF-8 character set, about 95% of the characters are correct, but a few are replaced with question marks and boxes. the fact that most are correct indicates to me that my settings are correct in all places, but perhaps the UTF-8 Character set is incomplete. Characters that work fine (Hex): ? (C3A5CB86E280BA) ? (C3A9E282ACC2A0) ? (C3A7C5B8C2A5) ? (C3A7E280B0C592) Characters that are not working (Hex): ? (C3A53F3F) ? (C3A5E2809C3F) ? (C3A6CB863F) I am using ColdFusion MX 7 and the MySQL ODBC connector on a Windows machine. This is a shared hosting environment, so I may not be able to upgrade anything.
Displaying Chinese Characters
I install MySQL v4.1.14 in WindowXP as a service. I store all the data in the plain text file and load it into the database. All the data are stored in the database successfully but all the chinese characters become '????' Every time I need to set the character set to big5 before I can see the chinese characters in the command line interface. How can I set the big5 as the default character set? Although I can see most of the chinese characters after setting to big5, some of the characters are still in '????' Why this happens? Thirdly, even if I can see the chinese characters in the command line interface, all the chinese characters change back to the '????' again when I use the web browser to see the data. How to fix up this problem?
Displaying Chinese Characters
I am designing a website that needs to be bilingal English/Chinese. I decided to create a MySQL table to hold page contents with a field called language with values en or cn. I have two PHP pages, one queries on all records with en and has a character set "iso-8859-1" the other queries on all records with cn and has a character set "gb2312". I have decided to enter the data using an Access database linked to the MySQL database using MyODBC. When I enter english characters all works fine. when I enter chinese charcters, they initially display fine on my PC as chinese characters, but once the record has been entered these are replaced with ?? symbols. The question marks appear to originate from the MySQL database because they show up in the Access database, the online chinese page and using PHP MyAdmin.
Databasing Chinese Content
My company is looking into developing spanish and chinese versions of their website. Building a custom content management system seems to be the best route for this but I'm curious as to MySQL's ability to database chinese (and other non alphabetic languages like arabic and japanese) content.Has anyone dealt with this issue or have a recommendation on another database platform I could use that offers support for this requirement?
Chinese/Unicode From Php And Mysql
I searched the forum regarding this problem already and attempted to solve the problem, but fail regardlessly.I entered chinese characters directly into a table column A which has collation utf8_unicode_ci using phpmyadmin. The chinese/unicode characters actually appeared in phpmyadmin's "select * from tableT". However, when I create a php script with a query "select * from tableT", it appears in the form of question marks e.g. ????.Any idea how to resolve this? If I can view the chinese characters in phpmyadmin via the web browser, it shouldn't be a problem to display it in a php file, right? Not sure whether this is a php or a mysql problem.
Can Not Load Chinese Characters
I use 'LOAD DATA INFILE' syntax to insert records into a table. The txt file contains Chinese characters.After executing the command,there was no error dsplayed,but the Chinese characters were not inserted into the table,instead there was blank when I typed 'select * from table'.
Can't Enter Chinese Characters
I have tried to follow instructions online as well as other threads in this forum, so far to no avail. I am using JSP, Java 1.4, MySQL 4.1 and Tomcat 5.5 on Windows XP. 1) I have set my JSPs to use UTF-8 wherever possible. I have a form where I can enter Chinese characters into a form, which hits a servlet, but text always arrives to the servlet garbled. 2) When I try to directly do an INSERT to a column and insert a chinese character, it comes up as ??? mySQL Query browser says "Data truncated to column 'translation' at row 1' ErrorNumber 1265. 3) I have made sure that each table's encoding is UTF-8. Not sure what else to do. I can't find any easy instructions to do this. If you know of one,
Sorting Chinese, Japanese
I have been asked to look into support for sorting non-latin 'alphabets' such as Chinese and Japanese. I already know that MySQL supports UTF-8, though my interest is in finding out how well MySQL support sorting of entries for these writing systems and what supplementary configuration I may need to do.
Store Chinese Character In Mysql
My site is 90% english, however there are some pages that i need to display in chinese character. In fact, arabic, russia, spanish. In mysql, i try to use collation utf8_general_ci . So when i input the data using phpmyadmin, i type chinese character e.g •ź(lucky) into the record, save it. Unfortunately when i use php to get the data from mysql database and present it on the web, it appear as '?' (question mark). How do i show it on the web correctly ?
How To Save Chinese Record In MySQL?
I am now using MySQL database to save Chinese, my OS if Chinese Windows2000, and my MYSQL version is 4.2, but I couldn't save some Chinese characters at all, some can be saved, others are lost or displayed in a mass, you won't understand the meaning at all. Can anyone tell me how to solve this problem, how to save Chinese informaiton in MySQL?
How To Show Chinese Character Correctly?
i'm using Mysql5.0 now, it's char_set is latin_1 and my os is WinXP Chinese Edition. In my tables, chinese characters can be shown correctly from mysql command line, but chaos when i use mysql GUI tools and phpMyAdmin. what's wrong? what should i do ?
Store And Read Chinese Characters
I'm writing a vbscript application that reads UTF-8 XML containing Chinese characters. Any suggestions how to store these characters in MySql 4.0.x ? Do I need to set a special encoding such as Big5 on the database ? Does MySql support storing UTF-8 ? If so what data types / encoding do I need to use ? Are there any special considerations for using MySql/ODBC and ADO to get and put the data.
Search: Remove Quotes From Database For Search
I am making a book site and currently in the database are book titles likes "John's Trip" and "Peter's new bike". I have a search function where the customer can type in "Peter's" and it will bring up everything with "Peter's" in it. But i was wonderind is there any way i can search for "Peters" and "Johns".
I Have A Search Form To Search Through The DB.
I have a DB with 50,000 entries. I have a search form to search through the DB. If the recno=30123456 and you search the recno, you get that one file. what if i want a query that searches alll recno's that contain 30?? Can I do that using mysql or do I need to program that in my java app?
Best Way To Search
I am a little confused on the best way to search a mySQL database with PHP. Which is better? 1. Search with LIKE and a trimmed term SELECT * FROM tablename WHERE field1 LIKE "%$trimm%" OR field2 LIKE "%$trimm%" OR field3 LIKE "%$trimm%" ORDER BY field1 DESC 2. Using mySQL's 'match against'
Search WHERE SUM
What would be the proper way of generating a query like the following; SELECT id FROM sales WHERE SUM( totalsales) <= '20000' GROUP BY id; Assuming the table looks like this; Sales: Id| totalsales| monthyear 1 | 100| 2003-09 1 | 10000| 2003-08 1 | 2000| 2003-07 2 | 30000| 2003-05 3 | 10000| 2003-06 3 | 10000| 2003-05 I want the query to return id 1 and 2 as the sum of their totalsales is smaller then 20000.
DB Search
I am working a search tool for users to find members based on First Character of lastname. How can I have mysql or PHP only look at the first character of the string?
Search
I have an ASP page that searches a database. Although the entire database is searched, I use a filter on certain fields. The below filter (I could only use a little bit for the post to work)is for a field [LEDef_ActiveInd] that has either the number 1 or 2 or the text of true or false and it works and returns all "LEDef_ActiveInd" that carries the value of true. ..strQS = ..strL & "...LEDef_ActiveInd+true nd all+" & Trim(strR) What I would like to do is also filter a field [LEDef_Cd] which has text data such as "10-Name" or "40-Name", etc. I need a filter/code that would return the results of all the "10-Names".
My SQL Search
I'm currently using the following mysql statement to perform a search. Right now it is only returning the results which are found in the description field. How do I modify this statement so that it is searching the following fields: company_name, product_name, description. SELECT product_id, company_name, product_name, url, description FROM product, company WHERE product.product_id = company.company_id AND description regexp '#FORM.query#
Search
i have several tables. they have some fields in common, but some different ones. table 1 id author title journal year 1 brown java computing 2005 2 black sql database 2000 table 2 id author title publisher year 1 brown c++ pen 2006 how do i search both tables for i.e. author ? the author can exist in only the one table or both. so if i search brown i get: id author title journal year 1 brown java computing 2005 id author title publisher year 1 brown c++ pen 2006 if i search black i just get : id author title publisher year 2 black sql database 2000
Search
I have a search box on my site which works fine but I would like to improve. at the moment it will not return a result for a two word search unless those words are adjacent ie red box but not for return for red big box I would like to make it give results for multiple word searches when the: words are found In this order all words in search adjacent all words in search (not neccesarily adjacent) any of the words I assume the following tells it what to look for and how to display results (I hope so any way) Code:
Search Box
I am trying to have a search box on every web page in the site - like everybody seems to have these days, anyway, according to DW help the search page results holds the key to how it searches the database, but the trouble I am having is what to put in the sql box for the query? I know SELECT * FROM table will select everything and I know SELECT * FROM table WHERE location = 'town' ORDER BY price etc,etc. But what I need to know is how to have the results page display one set of results if a user enters one topic in the search box and another set of results if something else is entered. And if there is nothing to display, how do you configure that?
SQL To Use For Search
I am creating a script that searches the table "sites" in the database "actionhostsearch". I have a column in my table called "keywords" and i want to check that against my entered text, I am currently using LIKE but don't get a good result, is there a way I can refine it? The keywords are space separated, but i want it to search like multiple keywords. Is there anyway of doing this or would i have to separate the keywords out using php?
Search WHERE SUM
What would be the proper way of generating a query like the following; SELECT id FROM sales WHERE SUM( totalsales) <= '20000' GROUP BY id; Assuming the table looks like this; Sales: Id| totalsales| monthyear 1 | 100| 2003-09 1 | 10000| 2003-08 1 | 2000| 2003-07 2 | 30000| 2003-05 3 | 10000| 2003-06 3 | 10000| 2003-05 I want the query to return id 1 and 2 as the sum of their totalsales is smaller then 20000.
Search
I've heard that a friend searches by using a "like" querywith a select... But i searched in the mysql manual, and gcoudlnt' find anything on it... What are some other methods of searching in mysql databases?
SQL Search
I am migrating my site over to mysql and was wondering how I can implement my same type of search into the territory of mysql. Basically this is how the search worked for the db files (terribly inefficient but it worked well). Spliting each line at the deliminator, it would match the query against 10 different values and depending on the value being matched if a match was found the item would get a score. Each column had a higher score depending on which was most important. I basically used a regex expression to count the matches and multiply it by the matchscore. Is there anyway to use LIKE and find out how many times it matched? Can I use REGEXP and get a match count with the global switch?
Using LIKE In A Search
First off, I apologize if I am in the wrong forum. My question is kind of simple, if I use "SELECT from INVENTORY WHERE item_desc like '%blue%' OR item item_desc like '%stand%'; can i assume that LIKE is "not" case sensative????? so far that is the case, however, I can't find where in the documention to make sure of it. doing a search for LIKE in the documention is just ever so special. so i want to ask people who know. is LIKE case sensitive, or not?
Search EVERYTHING For ANYTHING
I got a database here with multiple rows/columns inside. Example: I have columns date, text1, text2, text3, and so on... Select * from db where "%" = "1969" So I wanna search EVERYTHING in the db for ANYTHING that says 1969. Whats the query to do this?
Search?
I builded a little propert database. I added a search function to the site but have the following problem: I used "SELECT * FROM table1 WHERE area ='province' and type like'%type_1%' and town like'%town_1%' and descr like '%descr_1%' and suburb like '%sub_1%'" But it do not do the like thing. If I search for 3 bed and the actual data is 3 bedroom it gets the data, but if I search for 3 bedrooms (extra s) it do not get it or if I make spelling mistake I do not get a result either. So it seems that it rather search for the exact term instead of the like term. How can I get it to really search for only a phrase, part of a word or a spelling error?
Using LIKE To Search
I have been using the following to search: WHERE FirstName LIKE '%$firstName%' AND LastName LIKE '%$lastName%' AND Email LIKE '%$email%' AND EmployerLocationName LIKE '%$venue%' AND State LIKE '%$state%' AND MemberApproved LIKE '%$status%' AND tblmanager.mngNBR LIKE '%$mng%' It has been working well but the only thing I realised with the mngNBR, if the user selects say 'Joe Bloggs' and in the database he is number '2', it also outputs all the results of other managers who have number '2'... so Matt Smith '22', John Smith '24'... I'm assuming this is because I have used like but is there any other way I can do it?
Search Using LIKE
I need to pull all records where the First letter of each word in the record begins with the entered variable. Here's my query: CODE"SELECT * FROM hgs_contacts WHERE name LIKE '".$_GET['l']."%'";
Search Between A - J
I been looking a ways to do this but I can't seem to do it or get my head around it. I want to basically search my table for all "titles" begining from A - J. I want the SQL to check the first letter of the "title" and if the first letter starts with any letter between A - J I want it to be displayed. How would I do this? So far I have: Code: SELECT title FROM pmc_keyclients WHERE LEFT(key_title, 1) = 'A' But this let me search BETWEEN latters
Search By Number
I have a question regarding a mySQl search Basically I have a list of numbers stored in a field in my database representing different features of a venue For example 1,16,17,10,8,13, Now I want to give my client the ability to look for specific venues with a specific feature by typing in the number for the feature they are looking for, ie if they want to find all venues with a bar and 1 = bar then they enter 1 into the search and are presented with all the venues with a bar Now my problem is if I do a search for Ƈ' using LIKE then and a wild card (ie %1%) I will get all the features that have a 1 (ike 16, 17, 10, 13). Is there anyway I can write a search that will only return venues that just have the number 1? Also the numbers can appear in ANY order so it might be 10,8,26,1,32 ....
Search Index
I have text stored in a database that I'd like to be searchable. However, searching through long strings and blobs seem like a very inefficient way of doing things. In MS Server there's an index server that will take all strings and create indexes out of words. This can significantly speed up text searches. Is there such a feature or tool for MySQL?
Fulltext Search
Below code is from a CMS's search script. When you search for plain words like Britney Spears it displays the results correctly. But when you search for a URL like http://www.sitepoint.com then it does not return any results. Is there anything wrong with the following SQL code? ... $this->sql = "SELECT story_id, story_date WHERE $where $sterms "; ... $where = " MATCH (story_title, story_url, story_tags, story_content) AGAINST ('$words') "; Note: story_url stores URLs exactly as http://www.sitepoint.com not encoding etc. story_url field is FULLTEXT same as others.
Search On Dates?
I have 2,000 stories saved in a database (Not my DB) and I want to perform a search on the section of story and the date it appeared on the website. The trouble is the DB is dodgy and dates are saved in a format like: 2007-1-8 //Today Ie YYYY-M-D Now what I want to do is perform a MySQL statement whereby I perform a search on the date in this format: 2007-1-8 //Today Ie YYYY-M-D IE: "Y-n-j" And then my SQL finds the date I asked for, but then - Checks it’s not greater than today’s date (NOW) by using unix_timestamp on both the appreared field and published field. And then output all the results to the screen. Now I thought this may work: PHP $sql = "select id,headline,appeared from news_stories where section = '$searchstring' AND date_format('$appeared','%Y-%m-%d') = date_format(appeared,'%Y-%m-%d') AND unix_timestamp(published) <= unix_timestamp(now())";
Search Functionality
When a website adds search functionality, more so than bulletin boards, but take the Facebook for example (not as complex as what they do but a good example, and the only i can think of at the moment). You can do a basic search for 'John' and the results returned will contain people named John, it will contain people who date a John, anyone who remotely has 'John' show up in any field in their profile. Is the query for this simply a matter of a large amount of OR statements is there something else to it?
Search & Replace?
Newbie here. I have a DB with two tables. Table 1 has three fields - a unique ID#, a first name (i.e - John), and a last name (i.e. - Smith). Table 2 had many fields, one of them being a first name/last name combination (i.e. John Smith). I want to replace the first/last combo field in table 2 with the unique ID# from table 1 which matches the concat of the first name field and the last name field from table 1. I know I can do it by hand, but there are thousands of them in table 2 that need to be replaced and the data in table 2 is in the format that I will be receiving from an outside source, so I will need to search & replace this data on a regular basis.
Help With REGEXP Search
I have a database of English words. This thing is huge. Which means that when I do a search like SELECT word FROM wordlist WHERE word LIKE 'k__p' I get almost 300 results. What I want to do is limit my results to only those words with a repeated letter taking up that middle spot, e.g. "keep" but not "kelp". Is there any way to do this in a MySQL query, or am I stuck doing this in my application (which is what I'm currently doing)? I've tried some REGEXP tricks I know, but MySQL REGEXP apparently doesn't have capturing subpatterns or backreferencing.
|