Hi,
I want to use edsbr to generate a file with a list of extensions and phone names. I use
edsbr
clear
dir
name
go file
but the file being generated is always /tmpd/edsbr.out. Can i change the name of this file, to e.g. /tmpd/myfile.out?
How to set the output file for edsbr?
Re: How to set the output file for edsbr?
mv /tmpd/edsbr.out /tmpd/myfile.out
Other way is not possible as edsbr calls just /usr2/oneshot/mtcl/edmcs with fixed options.
Or use:
cdmao;echo "SELECT Mcdu,S_Name,F_Name,UTF8_S_Name,UTF8_F_Name FROM PHONEB;"|cuser|grep "\-\-" |grep -v Mcdu |cut -c5- >/tmpd/myfile.out
Other way is not possible as edsbr calls just /usr2/oneshot/mtcl/edmcs with fixed options.
Or use:
cdmao;echo "SELECT Mcdu,S_Name,F_Name,UTF8_S_Name,UTF8_F_Name FROM PHONEB;"|cuser|grep "\-\-" |grep -v Mcdu |cut -c5- >/tmpd/myfile.out
-
krutarthap
Re: How to set the output file for edsbr?
Thanks a lot! The second command is very useful, it is much simpler than edsbr.
Is the database structure (tables & fields) documented anywhere? I think there may be other useful queries that we don't know about yet.
Is the database structure (tables & fields) documented anywhere? I think there may be other useful queries that we don't know about yet.
Re: How to set the output file for edsbr?
I think so but have never seen it. It's R&D internal and I'm not an ALU developer.krutarthap wrote:Is the database structure (tables & fields) documented anywhere?
-
emning
Re: How to set the output file for edsbr?
I've been working on a simple extension that required this as well, and found the table names by looking at the files in /DHS3data/mao.krutarthap wrote:Is the database structure (tables & fields) documented anywhere? I think there may be other useful queries that we don't know about yet.
In other words, this should give you a list of table names:
Code: Select all
cdmao
for x in $(ls *.idx); do echo ${x%%M.*}; doneRe: How to set the output file for edsbr?
Easier: cat /usr2/fab/tbl2obj.refemning wrote:I've been working on a simple extension that required this as well, and found the table names by looking at the files in /DHS3data/mao.krutarthap wrote:Is the database structure (tables & fields) documented anywhere? I think there may be other useful queries that we don't know about yet.
In other words, this should give you a list of table names:
From there a simple "select * from" on a table will give you field names and contents.Code: Select all
cdmao for x in $(ls *.idx); do echo ${x%%M.*}; done

