Tuesday, June 9, 2009

More database progress

And with a little more persistence this afternoon, I expanded the Perl program to insert records into a database table. This test shows that I have the proper rights granted and the proper SQL syntax for updates.

Next will be some improvements to the programs on the remote computer. They collect statistics on source code. I have the raw lines of code (LOC) and now need to collect the source lines of code (SLOC) which is the count of program lines. SLOC excludes comments and whitespace. To collect that I need filters for source files. C, C++, C#, and Java are fairly strightforward. Perl, with its =cut blocks, here files, and regular expressions that can be delimited by anything make the comment-removal task somewhat trickier. I may leverage a program such as SLOCcount.

I also need to add some options for the database name and host computer. I've hard-coded those values for the first version, so I could focus on the DBI and SQL portions. Now that they are working, I can make the program more flexible.

No comments:

Post a Comment