Q:

I need a tool for generating CSS selector based JQuery validator for xml custom schema

Do anybody know a tool that do this or something similar (in any language) because I want to create one?
I think of something that will create array of CSS selectors for the xml schema, and generates snippet of jquery code.

A:

If you want to query XML, then XPath is the way to go without question.  It's easily more powerful than jQuery's CSS style selectors.  
If you want a tool to generate jQuery selectors for an XHTML document for reuse with actual jQuery, I'm not aware of any such tool which exists.  The problem is that for a given element or set of elements, there can be dozens or even hundreds of selectors which pick that element out.  The more specific you are (eg, $('html body table:eq(0) tbody tr:eq(0) td:eq(3)')), the more likely this is to break with very minor modifications to the source document.  

