Hi folks, I'm trying to create an OA report, solely for the purpose of exporting the data to CSV, but I need some help in trying to figure out how to write line breaks in SQL, so they are passed to PHP, and ultimately as CR/LF to the CSV
SELECT service.id as 'ID', 'TechnologyService' as 'Type', service.name as 'Name', concat('"','http://(servername)/open-audit/index.php/devices/',system.name, 'CR/LF','CR/LF', 'Service Description: ',service.description,'CR/LF', 'Service Executable: ',REPLACE(service.executable,'"',''),'CR/LF', 'Service User: ',service.user,'CR/LF', 'Service Start Mode: ',service.start_mode,'CR/LF', 'Service State: ',service.state,'"') as 'Documentation' FROM System, Service WHERE @filter AND system.id = service.system_id
WHERE @filter AND system.id = service.system_id
_________________ Old OA Setup: 500 Windows 7 workstations & 200 Apple OSX with OA v1.5.2 on Windows Server 2003 and WAMP 2 New OA Setup: 100 Windows servers with OA 2.2 on Windows Server 2016 and WAMP 3
Last edited by el_geto on Sat Sep 15, 2018 2:01 am, edited 1 time in total.
|