![]() |
|||
PHP
IT Tags
local server photo gallery Stop Script UPDATE Simplexml Parser Mobile site control panel server shutdown my_thread_global_end SimpleXML mysql server objects Combo box php mail sdf check domain Solr XML indexing solr magento ecommerce associative arrays XHTML include connection to MYSQL Overlapping Layers ajax local server PHP and FLash multiple file uplo Remove Duplicate Xampp |
PHP Interview Questions
By: Shailesh Singh | 04 Sep 2008 10:47 pm
I have some queries, can you please clarify it. How can I reduce that time? What about, if products table have 10Lacs records and 1Lac product names are wrong. Is for loop working? Comments
Ans for Q4
Without using loops concept,i found one solution. By using LOAD DATA INFILE. 1.I have product table with fields pid and pname. 2.I am uploading excel file by using browse option. 3.Now i am creating temporary table with fields tid and tname. 4.I am loading LOAD DATA INFILE into temporary table. LOAD DATA INFILE "./a.xls" INTO TABLE temporary 5.By using below command,i am updating wrong product names. Update product p LEFT JOIN Temporary t where p.pid=t.tid and p.pname!=t.tname set p.pname=t.tname 6.Finally droping temporary table. drop table if exists temporary; If you need to count of wrong ones,by using mysql_affected_ rows() you will find the count.
By: PHP Guru | 05 Sep 2008
Ans 1Q
use *document.forms[ 0].name. *this will give you the name of the first form in the page. similarly using *document.forms[ 0].elements[ 0].name* you can get the name of the first element in the first form
By: PHP Guru | 05 Sep 2008
|
