Find and remove similar or duplicate content using PHP

Often we want to search, find or remove duplicate and similar content from our data base containing articles, text, messages etc. It is easy to do so manually if you have only 100 or so records in your database. But to handle large number of records it is bit time consuming and for even more … Read more

How to get a value from a table using functions and return count

How to get a value from a table using functions and return count: Write a simple query and pass the parameters: function somename($tablename, $colnam, $colvalue, $mode, $returncolnam) { Select $returncolnam from $tablenam where $colnam=$colval } Note: For $returncolnam you can also use array number starting from 0.

SQL Basic Queries

Basically FOUR SQL commands used very often. These four commands are SELECT, INSERT, UPDATE, DELETE By using these four basic commands you can do a lot of queries. SELECT select * from tablename INSERT insert into tablename SET col1=”, col2=” UPDATE update tablename SET col1=”, col2=” WHERE col3=” DELETE delete from tablename WHERE col1=”