Getting Data In

listdown the sourcetype from the index

splunkpoornima
Communicator

Hi all

i used the below code..to list down the sourcetype of the main indx in the dropdown ..




| metadata type=sourcetype index=main

please correct me if i made an mistake..

thanks in advance

Tags (1)
0 Karma

Ayn
Legend

type=sourcetype is incorrect, it should be type=sourcetypes.

PLEASE PLEASE consult the docs as a first resort.

splunkpoornima
Communicator

finnaly i got the output.now the problem is, i created two dropdowns one for sourcetypes so if i select source type i want the ist of sources in that sourcetype



| metadata type=sourcetypes index="main"



sources $tokenusedindropdown$

0 Karma

Drainy
Champion

That sounds like you have a space somewhere you shouldn't, could you edit your question with the updated xml?

0 Karma

Ayn
Legend

Doesn't sound like a problem in the dropdown.

0 Karma

splunkpoornima
Communicator

actually i changed everything u said..after runing the code..i got got the error as

Error in 'search' command: Unable to parse the search: Comparator '=' is missing a term on the right hand side.

0 Karma

Ayn
Legend

Other errors include: it's populatingSearch, not populatingsearch. It's sourcetype, not SourceType.

splunkpoornima
Communicator

no actually i used type=sourcetypes only but when typing here i missed

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...