Re: conversion numeric to string while using servlet
From: Thomas Smith (removespam-thomas.smith_at_cox.net)
Date: 10/04/03
- Next message: nsb: "JDBC - sending Clob data via RMI"
- Previous message: Joan MacEachern: "[SUN] Take Sun Security Course and Get a Digital Camera"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sat, 4 Oct 2003 00:54:39 -0400
well, the easiest way, and very probably the best way. Is to use
getObject(int) instead of trying to get the individual data types. then you
can just call the toString() method(after checking if it is null).
"Manish Sandow" <manishsandow@indiatimes.com> wrote in message
news:e5db6a72.0309260603.32b6ba64@posting.google.com...
> Dear all,
>
> I m facing a problem while i want to fetch data from the database. I m
> unable to convert numeric datatype to string.
>
>
> if(rs.next())
> String char_toneid = String.valueOf(TONEID);
> output_toneid = rs.getString("char_toneid");
>
> saying undefined variable TONEID
>
> regards,
> Manish Sandow
- Next message: nsb: "JDBC - sending Clob data via RMI"
- Previous message: Joan MacEachern: "[SUN] Take Sun Security Course and Get a Digital Camera"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]