Pleasant good day
\nCan you guide me an trying to create a script
\nTo extract data form sql database and out put the data to a csv file names export and the system date this is a repetitive task
\nscr
\nCL<\/p>\n
Carlon Leotaud
\nTo:
\nCarlon Leotaud<\/p>\n
DECLARE @sqlCommand<\/span> VARCHAR(1000) SET @filePath<\/span> = 'D:\\Accounts' /Creating a date type variable<\/em>/ /* Setting the value of the date variable to today’s date*/ /Filtering the results by CREATE_DATE = Today & SETT_DT= Today & In_OUT = incoming(1)<\/em>/ Pleasant good day Carlon Leotaud DECLARE @sqlCommand<\/span> VARCHAR(1000) SET @filePath<\/span> = 'D:\\Accounts' /Creating a date type variable<\/em>/ /* Setting the value of the date variable to today’s date*/ /Filtering the results by CREATE_DATE = Today & SETT_DT= Today & In_OUT = incoming(1)<\/em>/ This looks to be SQL-based pseudo code. What kind of script language are you looking for? Also, please understand that we are not a script writing service. Though we will certainly help where we can, you kind of need to have at least made an attempt on your own, first. Also, it would help if you posted in the correct forum. So, if you’re looking for help with, for example, a PowerShell script, you might try posting in that forum. Spiceworks Community Support<\/strong> (where this was originally posted) is definitely the wrong place for this.<\/p>\n
\nDECLARE @filePath<\/span> VARCHAR(100)
\nDECLARE @fileName<\/span> VARCHAR(100)<\/p>\n
\nSET @fileName<\/span> = ‘ACCexport_’<\/p>\n
\nDECLARE @date<\/a> DATE<\/p>\n
\nSET @date<\/a> = CAST( GETDATE() AS Date )<\/p>\n
\nselect TRANSACTION_ID,INSTRUCTED_AMT,INSTRUCTED_CCY from REC_BDLR_PAYMENT
\nwhere CAST(CREATE_DATE as date) = @date<\/a>
\nand CAST (SETT_DT as date) = @date<\/a>
\nand IN_OUT=‘1’<\/p>","upvoteCount":4,"answerCount":2,"datePublished":"2020-11-24T21:00:10.000Z","author":{"@type":"Person","name":"kaallo4","url":"https://community.spiceworks.com/u/kaallo4"},"suggestedAnswer":[{"@type":"Answer","text":"
\nCan you guide me an trying to create a script
\nTo extract data form sql database and out put the data to a csv file names export and the system date this is a repetitive task
\nscr
\nCL<\/p>\n
\nTo:
\nCarlon Leotaud<\/p>\n\n
\nTue 11/24/2020 5:32 PMView more
\n/EXPORT SCRIPT<\/em>/<\/li>\n<\/ul>\n
\nDECLARE @filePath<\/span> VARCHAR(100)
\nDECLARE @fileName<\/span> VARCHAR(100)<\/p>\n
\nSET @fileName<\/span> = ‘ACCexport_’<\/p>\n
\nDECLARE @date<\/a> DATE<\/p>\n
\nSET @date<\/a> = CAST( GETDATE() AS Date )<\/p>\n
\nselect TRANSACTION_ID,INSTRUCTED_AMT,INSTRUCTED_CCY from REC_BDLR_PAYMENT
\nwhere CAST(CREATE_DATE as date) = @date<\/a>
\nand CAST (SETT_DT as date) = @date<\/a>
\nand IN_OUT=‘1’<\/p>","upvoteCount":4,"datePublished":"2020-11-24T21:00:10.000Z","url":"https://community.spiceworks.com/t/script-assistance/782897/1","author":{"@type":"Person","name":"kaallo4","url":"https://community.spiceworks.com/u/kaallo4"}},{"@type":"Answer","text":"