Archive

Posts Tagged ‘index’

Searchable Google AppEngine with Compass

April 11th, 2009 Jigish Thakar No comments

Google App Engine was released yesterday for Java. It provides the ability to deploy Java based web applications onto the App Engine, and provides a data store service (with JPA and JDO on top of it), memcached, and others. So, what I decided to do is try and get Compass integrated with Google App Engine to allow for easy full text search of Google App Engine apps (yea, the irony). Basically, it took me a couple of hours, and we have something ready to use.

What are the steps needed?

  • Make your domain model searchable.
  • Create a Compass instance. Configure it to store the index using GAE data store (there is also support for native Lucene applications). Configure it not to use threads.
  • Create a Compass Gps, have it automatically mirror changes done using the JDO/JPA API to the search engine. Call index operation to completely reindex your application.

Thats it. Pretty simple no? Especially since these are the steps you use to enable any Java application with full text search using Compass :) .

source

Sphinx

March 3rd, 2009 Jigish Thakar No comments

Sphinx is a full-text search engine, distributed under GPL version 2. Commercial license is also available for embedded use.

Generally, it’s a standalone search engine, meant to provide fast, size-efficient and relevant fulltext search functions to other applications. Sphinx was specially designed to integrate well with SQL databases and scripting languages. Currently built-in data sources support fetching data either via direct connection to MySQL or PostgreSQL, or using XML pipe mechanism (a pipe to indexer in special XML-based format which Sphinx recognizes).

As for the name, Sphinx is an acronym which is officially decoded as SQL Phrase Index. Yes, I know about CMU’s Sphinx project.

for more information click here

Yahoo Re-Launched IndexTools As Its Web Analytics

October 13th, 2008 Jigish Thakar No comments

padding:5px;Yahoo has re-launched IndexTools as Yahoo Web Analytics. IndexTools is a web analytics package which brought in April 2008. Yahoo Web Analytics is an enterprise site analytics tool that provides real time visitor behavior on website. With the powerful and flexible tools and dashboards, it able to provide the marketers and website designer with useful analysis reports that will enhance their visitor experience, increase sales, increase traffic and reduce marketing cost.

ywa wa img pu 2 Yahoo Re Launched IndexTools As Its Web Analytics Read more…

Cookies Vs Sessions

October 8th, 2008 Jigish Thakar No comments

Both cookies and sessions are available to you as a PHP developer, and both accomplish much the same task of storing data across pages on your site. However, there are differences between the two that will make each favourable in their own circumstance.

Cookies can be set to a long lifespan, which means that data stored in a cookie can be stored for months if not years. Cookies, having their data stored on the client, work smoothly when you have a cluster of web servers, whereas sessions are stored on the server, meaning in one of your web servers handles the first request, the other web servers in your cluster will not have the stored information.

Sessions are stored on the server, which means clients do not have access to the information you store about Read more…

Basic About PHP 1

September 12th, 2008 Jigish Thakar 2 comments

hey guys with this i m starting new thing on my blog

as per my brother request now i ll post stuff for PHP Beginners also..

Command can be used to connect to ur server that is WAMP server

<?php

mysql_connect(“localhost”,”root”,””)or die(“can not connect to server“);

?>

To select database

<?php

mysql_select_db(“database_name”)or die(“no database found”);

?>

How to write query

<?php

$qr = “select name, class from tablename”;

?>

Its always better to write query and store it in some variable its good practice

How to execute query

<?php

$rs = mysql_query($qr)or die(mysql_error());

?>

$rs is result set obtained by query execution

now how to print result

if u r sure result is single row then

$row = mysql_fetch_row($rs);

echo “name : ”;

echo $row[0];

echo “<br>”;

echo “class : ”;

echo $row[1];

if result is more then one row then

while($row = mysql_fetch_row($rs))

{

Echo “name : ”;

echo $row[0];

echo “<br>”;

Echo “class : ”;

echo $row[1];

}

different methods to fetch data from resultset

$row = mysql_fetch_array($resultset)

different methods to fetch data from resultset

this will give result set in array and u can access this array using index or associates i.e.

$row[0]

$row[1]

$row[2]

Or

Associates

$row[‘name’]

$row[‘class’]

$row[‘rollnumber’]

$row = mysql_fetch_row($resulset)

here array can be accessed just by index

i.e.

$row[0]

$row[1]

$row[2]

$row = mysql_fetch_assoc($resultset)

Here only associates

$row[‘name’]

$row[‘class’]

$row[‘rollnumber’]

there is one more method i.e.

$row = mysql_fetch_object($resultset)

Here u can access by creating object

i.e.

 $row->name;

$row->class;