Gossamer Forum
Home : General : Databases and SQL :

problem selecting long datatype

Quote Reply
problem selecting long datatype
I cant select long datatype in my table...

create table abc (num long);

insert into abc values (123123);

select * from abc where num = 234234;

this is not working....

please tell me quickly..
Quote Reply
Re: [danish_ara] problem selecting long datatype In reply to
You insert the number 123123, and select the number 234234, so that's why you are not seeing any results.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] problem selecting long datatype In reply to
that does not matter what I am selecting....

it should have displayed "0 rows selected" instead of displaying error something like "invalid long datatype handling"
Quote Reply
Re: [danish_ara] problem selecting long datatype In reply to
You need to escape the parameter value with single quotes, like the following:

Quote:

SELECT abc.* FROM abc WHERE num = '234234';

========================================
Buh Bye!

Cheers,
Me
Quote Reply
Re: [danish_ara] problem selecting long datatype In reply to
Well, you need to provide more details. What database server are you using in the first place, and cut and paste an example, as "error something like" is not helpful. We need to see exactly what the error is.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] problem selecting long datatype In reply to
when I use select qurey on above table I mentioned..it display this error

select * from abc where num = 1212312;

error : "illegal use of long datatype"