Link to home
Start Free TrialLog in
Avatar of notta3d
notta3dFlag for United States of America

asked on

csv design help

Hey guys, I currently have a script written in AutoIt that our team uses to run on every machine we work on. Basically the script prompts for information such as first name, last name, room, building,..... It also pulls some information in the background like model, serial number, IP address, and so on. Once the submit button is hit the file is copied to a share on our server in a computername.csv file. We have about 1000 computername.csv files on the server(1 for each machine.) This has been working really well and now I want to take it to the next level.
Now I want to start gathering some more info such as all the software installed on the machine and maybe the hardware information. The problem I'm having is that when I start gathering variable things like software installed or hardware I don't know the best way to format the csv file. What I mean is the current csv file is in the form of firstname,lastname,room,building,serial,ipaddress,model, and so on. It's really nice right now because all I have to do is open the file, read in the one line, split the line into an array and then I can access any element I want because I know each position is the same in each file. Meaning array[1] is always firstname.
With the amount of software being different on each machine I lose the ability to access each element. See what I mean? I know you guys are going to say use a database for this, but that is something for down the road, but right now I have to work with the csv files. Can you guys help me find the best way to design the file format? Thanks guys.
ASKER CERTIFIED SOLUTION
Avatar of zoofan
zoofan
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Short of that idea,

Load all software into an array, sort the array alphabetically and then concatenate the array using a different delim then the ',' like '||' and put the concatenated array into one element of the csv at that point what ever your using to query the csv can still be coded with static element addresses and coded to handle the strsoftwarelist = split(arrCell(x), '||' of the software element displaying that internal list as you wish.


zf