The problem I'm having is with boolean type (B). The boolean values in my csv file are either "false" or "true", and they are not parsed correctly such that all of them are set to 0 in rawtab. How do I change this csvutil.q file to make it parse this boolean values correctly? I tried some things but didn't work. Any help appreciated
thanks
Jack Andrews
unread,
Jan 27, 2013, 7:54:53 PM1/27/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to personal...@googlegroups.com
you can read the values as syms and then update.
q)rawtab:([]n:1 2 3; s:`False`True`False)
q)update b:s=`True from `rawtab
`rawtab
q)show rawtab
n s b
---------
1 False 0
2 True 1
3 False 0
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to personal...@googlegroups.com, ja...@ivorykite.com
Problem is that although this example is simple, in my table there are close to 50 columns and 15 boolean columns, so doing it this way is cumbersome. I've to change the parser to get this done efficiently.
Sam
unread,
Jan 29, 2013, 10:38:29 PM1/29/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to personal...@googlegroups.com, ja...@ivorykite.com
Finally was able to revise the parser to recognize "True" and "False". thanks