|> How can i fetch a date from the database|
> and rename a file with that date(how to get
> a value from database in a variable in batch file).
There's 2 ways to handle this:
- go to the database (whatever the tool is) and find a feature that allows writing to a file (if it exists). Some DB-query languages have such a tool, others have not. Ask an application-programmer that works on writing software for the application which uses that database.
- The other way is my favorite, and that is the other way round. Use the OS command line, to query something on the database (the date, for example), and redirect output to a file (or to the command line) and work with that, in a OS script kind of matter. You will need a non-graphic (command line) interface program with your database, for this to work ... or, be lucky that you have a GUI which allows all ouput to be forwarded to a file.
What is the database, what is the tool used to access the DB ?