Hi, I have a column with the following format: 09:30 12:30 11:30 … I would like to separate the column into two columns by “:” asfollows: column_1 column_2 09 30 12 30 11 30 … Could you tell me what function I should use? Thanks in advance. Ning
vector split
?
“:” vs string 09:30
?
2009/10/25 Ninja Li <nickli2000@gmail.com>
Hi,
? I have a column with the following format:
? 09:30
? 12:30
? 11:30
? ?..? ?I would like to separate the column into two columns by “:” as
follows:
? ?column_1 ? column_2
? ? ? ? ?09 ? ? ? ? ? ?30
? ? ? ? ?12 ? ? ? ? ? ?30
? ? ? ? ?11 ? ? ? ? ? ? 30
? ? …? ? Could you tell me what function I should use?
? ? Thanks in advance.
? ? Ning
assuming they’re times, and you’re storing them as times:
q)tbl:(t:09:30 12:30 11:30)
q)tbl
t
-----
09:30
12:30
11:30
q)update h:hh$t,m:
mm$t from tbl
t h m
-----------
09:30 9 30
12:30 12 30
11:30 11 30
q)
I really appreciate all your help.NingOn Oct 25, 5:22?am, Simon Garland <simon.garl…> wrote:> assuming they’re times, and you’re storing them as times:>> > q)tbl:(t:09:30 12:30 11:30)> > q)tbl> > t> > -----> > 09:30> > 12:30> > 11:30> > q)update h:hh$t,m:
mm$t from tbl> > t ? ? h ?m> > -----------> > 09:30 9 ?30> > 12:30 12 30> > 11:30 11 30> > q)>> On 25.10.2009, at 05:35, Ninja Li wrote:>>>>>> > Hi,>> > ? I have a column with the following format:> > ? 09:30> > ? 12:30> > ? 11:30> > ? ?..>> > ? ?I would like to separate the column into two columns by “:” as> > follows:> > ? ?column_1 ? column_2> > ? ? ? ? ?09 ? ? ? ? ? ?30> > ? ? ? ? ?12 ? ? ? ? ? ?30> > ? ? ? ? ?11 ? ? ? ? ? ? 30> > ? ? …>> > ? ? Could you tell me what function I should use?- Hide quoted text ->> - Show quoted text -</simon.garl…>