Splunk Search

DBxquery help

jerinvarghese
Communicator

HI All,

I have a DB querry, need a help in date filter. 

 

| dbxquery connection="ITDW" shortnames=true  query="SELECT
GETDATE() as 'CurrentTime',
[Incident_Number],
INC.[Company],
[Customer],
PPL.Region as 'Customer_Region',
PPL.Site_Group as 'Customer_Site_Group',
PPL.Site as 'Customer_Site',
[Summary],
[Notes],
[Service],
[CI],
[Impact],
[Urgency],
[Priority],
[Incident_Type],
[Assigned_Support_Group],
[Assigned_Support_Organization],
[Status],
[Assignee],
[Status_Reason],
[Resolution],
[Reported_Date],
[Responded_Date],
[Closed_Date],
[Last_Resolved_Date],
[Submit_Date],
[Last_Modified_Date],
[Owner_Group]
FROM [shared].[ITSM_INC_MAIN] INC
LEFT OUTER JOIN [shared].[ITSM_CMDB_People_Main] PPL
ON 
INC.Customer_ID = PPL.Person_ID
WHERE (([Assigned_Support_Group] = 'Ops-WAN'))
AND [Submit_Date] BETWEEN DATEADD(D,-700,GETDATE()) AND GETDATE()"

 

I want some data which is old , filter only data that is of 2019, but when i search for more than 300 days. its not showing the accurate data.

 

how can i add a specific year or between date in the code. 

0 Karma
Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...