| |
| |
| |
|
Comments:
<0> Hello <0> someone online? <1> yes <0> Someone <0> ?
<1> yes? <0> hello DC[treatise] <0> have 5 min to help me with a perl script <0> i don`t know why doesn`t execut a sql command <0> ...... <1> I'm not familiar with SQL. Do you have the module installed? <0> 5 sec plz <0> need to restart <2> \HI (newbie perl programmer): Anyone know an elegent way to load an array with a string? ie. i have read soem data and formatted it to look like $my_data="one", "two", "three" and now want to get it into an array @myArray[0]="one" etc. @myarray=$my_data does not work (even if I add brackets) - any ideas? <2> Update : i've go the regulare expression to isolate a single Quoted dtring from my long, muliple quotes string: $FormDistList =~m/\"(.*?)\"/ Now I just need to work out how look conditionly loop through and load up my array <2> Update : i've go the regular expression to isolate a single Quoted string from my long, muliple quotes string: $FormDistList =~m/\"(.*?)\"/ Now I just need to work out how to conditionly loop through and load up my array <2> urm, now looking at @myarray=split(",",FormDistList); ...... <2> yippee - I've now mastered the split command :) <2> problem sorted - ta <3> $tmp{'Content-Attachment-ID${i}'} <= do you think this a correct hash? <4> for? <3> im trying to make a hash table, which $i is a running numeric increament <5> Need double quotes. <5> $HashTable{$i}=$Content; <5> hmmm... Can't quite remember it.
<3> yeah, quotes works, alternatively there's another way, $HASH{'foo'.$i} <5> $HashTable{$Row}{$Column}=$Value; is what you ultimately want. <5> Or, if you've constructed it so that the row is already in a hash: <5> $HashTable{$Row} = { %RowData }; <5> Youe construction wouldn't have $HoH{...{...}}, it'd be $HoH{...}{...} <5> It's under records or something... <5> 4.7.4 Hashes of Hashes in the Camel book. <3> alright thanks <5> np <3> so i would just replace $hash{$i}{'name'} <3> that would be neat tho <5> Yes, you'd need a value for it, though: $hash{$i}{'name'}='value'; <5> I ***ume that your table has column names and numbered rows? <3> yeps <5> Actually, wouldn't it be easier to use an array of hashes instead of having numbers as keys in a hash? <5> As in push @Table, { %RowData }; Where %RowData is a hash of $RowData{'ColumnName'}='value'; <5> So an elemnt on the second row would be read: $Table[1]{'ColumnName'}; <3> and if were to store value, $Table[$i]{'foo'} = value? <5> If the array was already created, yes. What I was doing with the push statement. <3> alright, thanks man <6> np. Goodnight. <4> still
Return to
#perl or Go to some related
logs:
quotes from faana
velentine s day #allnitecafe #kl #chat-world #allnitecafe vaara vaara Aathi #kl nerdesin sevgilim gel #java
|
|