Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Pro*C Question - printing varchar
On Thu, 14 Oct 2004 20:11:30 -0400, Kareem Nutt wrote:
> I have the following:
>
> varchar name[21];
> ... select statement puts value into name ...
> ....
> name.arr[name.len] = '\0';
> printf ("name is %s.\n", name.arr);
>
> Example of what I get when I do this I get:
> "name is bob."
>
> What I want is to have all the extra spaces printed out as well:
> "name is bob."
>
> Anyone know how to do this?
/* Are you sure that this is an appropriate forum for the basic C language questions? */
printf("name is %+50s",name.arr);
-- Artificial Intelligence is no match for natural stupidity.Received on Fri Oct 15 2004 - 07:15:25 CDT