Hi Marc,
> Hi,
> 
> I'm searching an API for changing the appearance of values in self built
> strings for use in SQL statements to the right form.
> ...
> If I want to make SQL strings myself and fire them from OO.o to a
> connected DB this difference has to be detected and handled. At the
> moment I have to ask the databases metadata for every single field what
> type it is, have in mind what types are possible (decimal, float,
> currnecy, ...) and do the right thing. That is a tedious and error prone
> task.
> 
> How is it done inside OO.o and is there a publicly available
> service/inteface for shrinking my code?

Inside OOo, this kind of string creation is deep inside some parser
code, and not available as UNO service. At a low level, the
XLocaleData.getLocaleItem might at least help you in obtaining the
proper separators.

At a higher level, the XSingleSelectQueryComposer, in particular its
appendFilterByColumn method, are the only way to let an UNO service
generate the string representations. However, this contradicts your wish
to create the SQL strings yourself, it seems.

Ciao
Frank

-- 
- Frank Schönheit, Software Engineer         [EMAIL PROTECTED] -
- Sun Microsystems                      http://www.sun.com/staroffice -
- OpenOffice.org Database                   http://dba.openoffice.org -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to