Welcome to the homepage of  XSelect

 

Click here if you are interessted in our DirScout which is an easy to use folder launcher and directory switching tool

Click here if you are interessted in our tool VBSInc that allows VBScript developers to use include files in their VBS code


What is  XSelect ?

xSelect is a command-line utility that allows you to search textfiles :

 

However,  unlike tools like "grep" or "find",  xSelect allows you to use a SQL-query statement for analyzing textfiles incl. filtering, sorting, ordering and grouping

 

Usage :

xSelect [sql-query] FROM [filename] [WHERE sql-conditions] #-[switch] -[switch]"
 

Use   xSelect -?   for some details

Several switches allow you to customize the SQL-query.

Switches are passed after "#" in the commandline :

Switches:
Field-Delimiter for input file           : -din [delimiter]  eg: -din  ; Default : -din ,
Field-Delimiter for screen output        : -dout [delimiter] eg: -dout ; Default : -dout ,
Flag whether inputfile has headline      : -hh [yes/no] eg: -hh no Default: -hh yes
Flag whether display headline            : -dh [yes/no  eg: -dh no Default: -dh yes
number of lines to skip at begin         : -s [number]  eg: -s 5 Default: -s 0
skip all lines beginning with character  : -ss [character] eg: -ss # Default: dont skip anything
display some statistics                  : -stat eg: -stat Default: dont display stats
 

Here are some examples:

Example 1:

Let's say that you have a textfile - for example a file called "customers.csv" - which you want to filter and sort  for some criteria using an SQL statement :

Customers.csv :

Name,City,ZIP,Orderdate,amount

Miller,New York,1234,150.00

Smith,Washington,4321,200.00

Brown,New York,1234,300.00

 

Using xSelect you can run SQL queries like this:

xSelect * from Customers.csv where ZIP="1234"

xSelect Name, sum(amount) as Total from Customers group by Name order by Total desc

 

Example 2:

If the delimiter in a textfile is not  ,  but  ;   then you can use the  "-din"   switch that allows you to set the delimiter used :

Customers.csv :

Name;City;ZIP;Orderdate;amount

Miller;New York,1234;150.00

Smith;Washington,4321;200.00

Brown; New York,1234;300.00

xSelect Name,Orderdate from Customers.csv where ZIP="1234"   #-din ;

 

Example 3:

If the textfile has no headline  then you can use the  "-hh no"   switch:

Customers.csv :

Miller;New York,1234;150.00

Smith;Washington,4321;200.00

Brown; New York,1234;300.00

xSelect * from Customers.csv where col3="1234"   #-din ;  -hh no

Note that if there is no headline then the columns will be named from Col1...to Col[n]

In the above example the column "ZIP"  will be used as "Col3"

 

Example 4:

If the textfile has no headline  and some comment lines beginning with * that must be skipped then you can use the  "-ss"    switch:

Customers.csv :

*sample data

*created 04/08/2009

Miller;New York,1234;150.00

Smith;Washington,4321;200.00

Brown; New York,1234;300.00

xSelect * from Customers.csv where col3="1234"   #-din ;  -hh no  -ss *

 

Download:

The download contains a xSelect-demo that is limited in that way that it will only display half of the resulting records - but it will allow you to test all features of xSelect

Download xSelect v 2.0

 

After the download has finished unzip the archiv.

Run xSelect from a console window

Use   xSelect -?   for some help

 

You can try some of the included examples.

If you copy xSelect.exe a directory that is part of the search-path (PATH) - like c:\windows  or  c:\windows\system32 - then you can use xSelect directly from a console window.

 

Compatibility:

xSelect will run under Windows only and has been tested under Windows 2000\2003\2008 Server and Windows 2000 Pro\Vista

xSelect is a standalone application and is non-dependent on any other windows-components like .NET or dataproviders\drivers like ODBC/ADO etc.

 

License:

Please note that only registered uses are entitled to priority email-support

 

Buy:

We use   to process your order 

 

xSelect Home Edition    : 19 Euro BUY

xSelect Business Edition: 69 Euro BUY

All prices are plus local TAX / VAT

 

After we have received your order we will send you an email with your licence key that will unlock xSelect

Please allow 1 business day for delivery.


(C) 2008, 2009 www.Scout-Soft.com