Skip to Main Content

Database Software

Comparing String Arrays Pointer

3875643Jan 27 2019 — edited Jan 27 2019

Sorry,  I did not know capitalized words are shouting

Need help from an Expert.( This is a Pro*C code)

I need to comapare

i need to compare a string array ( char elementname[5]) with a column (elname varchar2(5)) in a table by a function void get_name(* char).

the contents of the element name is  got from another table by this select elname into :elementname where condition is met ( this part is ok, i have the elementname='iron'.

but when i pass the elementname in a function get_name(elementname) to do a comparision in where it does not work:

function get_name(elementname) {
          select       x,y,z      
          from q       
          where elname=:elementname;

this condition can not work, since the where condition does not accept the statement elname=:elementname; (to compare a pointer char with a column (elname varchar2(5)) .

could someone help me out, please.


Message was edited by: 3875643

Message was edited by: 3875643

Post Details
Added on Jan 27 2019