Quantcast
Channel: All Forums
Viewing all articles
Browse latest Browse all 28058

Logparser query at sql query window

$
0
0

Hello,

I am a newbie at write SQL statements :-(

I get from logparser import at one SQL Table the field EntryTime with this value: 2012-11-19 17:15:35.000

How did i get the date and Hour from this string?

I hope somebody can help me,

Horst

The query from logparser look like this but this is not working for me at sql query window :-(((

SELECTTO_LOCALTIME(QUANTIZE(TO_TIMESTAMP(date, time), 3600)) AS [DateTime], COUNT(*) AS [Requests] INTO HourlyDayReport.txt FROM ex0902*.logGROUPBY[DateTime] ORDERBY[DateTime]"

"SELECTTO_STRING(TO_LOCALTIME(TO_TIMESTAMP(date, time)), 'yyyy-MM-dd') AS [Day], COUNT(*) AS [Requests] INTODayReport.txt FROM ex1003*.logGROUPBY[Day] ORDERBY[Day]"


Viewing all articles
Browse latest Browse all 28058

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>