Sponsored Content
Full Discussion: Typecasting problem??
Top Forums Shell Programming and Scripting Typecasting problem?? Post 302771591 by Vikram_Tanwar12 on Thursday 21st of February 2013 04:50:36 AM
Old 02-21-2013
Code:
cat vikram13.sh
23470330,s2ZsUMmoMCdllhIdZSWxdBl7cH0=,S40,1.6.52,MTN
2398774,s2ZsUMmoMCdllhIdZSWxdBl7cH0=,S40,1.6.52,MTN
2379162,pSSDGuUiPRX5c2MQUaBKYjvzOwg=,S30,4.0,MTN

Code:
vi vikram14.sh
#!/bin/sh
verbiage=('"Nigeria","Can Nigeria succeed in their quest for a top 4 finish? Get daily Nigeria news, GOALS and LIVE Match updates for 30days at N200.Click Accept to SUBSCRIBE"')
echo $verbiage
sed -i "s/\$/, $verbiage/" vikram13.sh

After running the script
Code:
vikram14.sh

Code:
cat vikram13.sh
23470330,s2ZsUMmoMCdllhIdZSWxdBl7cH0=,S40,1.6.52,MTN, "Nigeria","Can Nigeria succeed in their quest for a top 4 finish? Get daily Nigeria news, GOALS and LIVE Match updates for 30days at N200.Click Accept to SUBSCRIBE"
2398774,s2ZsUMmoMCdllhIdZSWxdBl7cH0=,S40,1.6.52,MTN, "Nigeria","Can Nigeria succeed in their quest for a top 4 finish? Get daily Nigeria news, GOALS and LIVE Match updates for 30days at N200.Click Accept to SUBSCRIBE"
2379162,pSSDGuUiPRX5c2MQUaBKYjvzOwg=,S30,4.0,MTN, "Nigeria","Can Nigeria succeed in their quest for a top 4 finish? Get daily Nigeria news, GOALS and LIVE Match updates for 30days at N200.Click Accept to SUBSCRIBE"

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

problem with dd command or maybe AFS problem

Hi, folks. Sorry for bothering, but maybe someone could help me please. The problem is the following: there is some script that copies files from local file system to AFS. The copying is performed with dd command. The script copies data into some AFS volumes. The problem appeared with one... (0 Replies)
Discussion started by: Anta
0 Replies

2. Shell Programming and Scripting

ssh script problem problem

Hi Please help me with the following problem with my script. The following block of code is not repeating in the while loop and exiting after searching for first message. input_file ========== host001-01 host001-02 2008-07-23 13:02:04,651 ConnectionFactory - Setting session state... (2 Replies)
Discussion started by: pcjandyala
2 Replies

3. AIX

user login problem & Files listing problem.

1) when user login to the server the session got colosed. How will resolve? 2) While firing the command ls -l we are not able to see the any files in the director. but over all view the file system using the command df -g it is showing 91% used. what will be the problem? Thanks in advance. (1 Reply)
Discussion started by: pernasivam
1 Replies

4. Red Hat

Mail Problem. Maybe, it is a DNS Problem!

Hi, i've a redhat linux 9 upadated by redhat from 7 version to 9 version. A couple of days ago i was a problem with my mail, in other words i'm not able to get any email nor to send any email. I've a proxy configuration and i tried to set iptables in order to verify the port. The 110,255 and 995... (1 Reply)
Discussion started by: pintalgi
1 Replies

5. UNIX for Dummies Questions & Answers

DHCP problem and eth1 problem

At work I am trying to get this one Linux machine (let's call it ctesgm07) to behave like another Linux machine that we have (let's call it test007). test007 returns the following version info: cat /etc/debian_version: lenny/sid uname -a: Linux test007 2.6.27-7-generic #1 SMP Tue Nov 4... (0 Replies)
Discussion started by: sllinux
0 Replies

6. AIX

AIX OS problem? network problem?

Dear ALL. I installed AIX OS on customer sites. but Only one site is too slow when I connected telnet, ftp.. Ping is too fast. but telnet and FTP is not connected.. of course i check the configuration file on aix but it's normal. Do any Idea?? thanks in advance. - Jun - (3 Replies)
Discussion started by: Jeon Jun Seok
3 Replies

7. IP Networking

Problem with forwarding emails (SPF problem)

Hi, This is rather a question from a "user" than from a sys admin, but I think this forum is apropriate for the question. I have an adress with automatic email forwarding and for some senders (two hietherto), emails are bouncing. This has really created a lot of problems those two time so I... (0 Replies)
Discussion started by: carwe
0 Replies

8. Programming

C Programming.. Typecasting of structure pointers..

Hi, I need to pass a typecasted structure pointer of one structure to another structure pointer.. The parameters of both structures are different say if first structure has int, char datatypes and second structure has float, double,char.. Please help.. I need to get the values of one... (3 Replies)
Discussion started by: Priya Amaresh
3 Replies

9. UNIX for Dummies Questions & Answers

sed Or Grep Problem OR Terminal Problem?

I don't know if you guys get this problem sometimes at Terminal but I had been having this problem since yesterday :( Maybe I overdid the Terminal. Even the codes that used to work doesn't work anymore. Here is what 's happening: * I wanted to remove lines containing digits so I used this... (25 Replies)
Discussion started by: Nexeu
25 Replies

10. IP Networking

Router problem or ISP problem ?

Hi everyone, I am experiencing discontinuity of Internet service, this started 1 month ago. Everything worked very well for 1 year of intensive use, but now, I have problems reaching my gateway. The gateway is not my router but a node belonging to my ISP and I share the same public IP with... (3 Replies)
Discussion started by: remic
3 Replies
ppmtosixel(1)						      General Commands Manual						     ppmtosixel(1)

NAME
ppmtosixel - convert a portable pixmap into DEC sixel format SYNOPSIS
ppmtosixel [-raw] [-margin] [ppmfile] DESCRIPTION
Reads a portable pixmap as input. Produces sixel commands (SIX) as output. The output is formatted for color printing, e.g. for a DEC LJ250 color inkjet printer. If RGB values from the PPM file do not have maxval=100, the RGB values are rescaled. A printer control header and a color assignment table begin the SIX file. Image data is written in a compressed format by default. A printer control footer ends the image file. OPTIONS
-raw If specified, each pixel will be explicitly described in the image file. If -raw is not specified, output will default to com- pressed format in which identical adjacent pixels are replaced by "repeat pixel" commands. A raw file is often an order of magni- tude larger than a compressed file and prints much slower. -margin If -margin is not specified, the image will be start at the left margin (of the window, paper, or whatever). If -margin is speci- fied, a 1.5 inch left margin will offset the image. PRINTING
Generally, sixel files must reach the printer unfiltered. Use the lpr -x option or cat filename > /dev/tty0?. BUGS
Upon rescaling, truncation of the least significant bits of RGB values may result in poor color conversion. If the original PPM maxval was greater than 100, rescaling also reduces the image depth. While the actual RGB values from the ppm file are more or less retained, the color palette of the LJ250 may not match the colors on your screen. This seems to be a printer limitation. SEE ALSO
ppm(5) AUTHOR
Copyright (C) 1991 by Rick Vinci. 26 April 1991 ppmtosixel(1)
All times are GMT -4. The time now is 01:07 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy