Choose one result in Splunk table Query - splunk-query

I would like to add radio button / any way to select - one of the results of my below REST query search,
QUERY : |rest /services/data/ui/views | table id label updated "eai:userName" "eai:data" "eai:appName"
Dashboard showing the results
This Query search is saved as a dashboard (auto-refresh) and I have added few text boxes (User Name, Commit Branch, User Token) as show in the attached image. These text boxes will be manually filled by user.
Use Case: I need to choose any one row via radio button (or any other technical way) and then click on the SUBMIT button to send the selected row data and text box (manually entered by user) data to my custom python script.
What is the way to achieve this use case in Splunk, Any help on this is appreciated.

If you want to pass results of a Dashboard elsewhere, you need to use a drilldown
See the Dashboard XML reference for more
Splunk will only send to a URL, however - so if you want it to go to a "custom python script", it will need to be accessible via URL
What does your "custom python script" do?

Related

Selenium XPath for WebTable using parent & sibling

I am trying to automate the web table on the demoqa site https://demoqa.com/webtables where I am aiming to click the edit and delete button for a specific user. Please find the attached screenshot for reference.
Screenshot
I am trying to click the edit and delete button for the user 'Cierra' hence I have created the customize XPath '//div[contains(text(),'cierra#example.com')]//following::div[text()='Insurance']//following::div//div//span[#title='Edit']'
Trying to click the edit and delete button using the contains text with email 'cierra#example.com' however I see four results even I use the unique username. Could anyone help me with this?
(//div[contains(text(),'cierra#example.com')]//following::div[text()='Insurance']//following::div//div//span[#title='Edit'])[1]
you can enclose the result in bracket and call [1] , to get first one:
But you don't have to over complicate it , just get email then go back to parent and get span under that parent ,:
//div[contains(text(),'cierra#example.com')]/..//span[#title="Edit"]
if you still want to use fancy xpath locator then use :
//div[contains(text(),'cierra#example.com')]/following-sibling::div[contains(text(),'Insurance')]/following-sibling::div//span[#title='Edit']

Beginner Oracle APEX - Using ITEMS for a query

So I'm trying to select some names from a table where their set dates are between two dates that I enter via keyboard.
If it was for a single input, where I only use something like (:x) in the region source, I could just create a Text Field Item X where I enter something and press ENTER.
What if I need multiple inputs? like (:x) and (:y).
Upon creating 2 items and entering their values nothing happens when I press ENTER.
The Region Source is this:
SELECT * FROM TOYS WHERE SALE_DATE BETWEEN upper(:x) AND upper(:y);
What am I supposed to do in order to enter two inputs?
If you need to initiate an action (submit the page, for example) by changing value, you have to find a property Submit when Enter pressed in item's settings and set it to Yes. For select lists, the same property is Page Action on Selection, and desired value for it - Submit Page.
Or, you can just create a button. Button's action by default is also "submit page".

SQL Server Reporting Services 2005 hyperlink value?

I am using SSRS 2005 and am running a report, where an ID is displayed for each entry. Is it possible to hyperlink each ID to the same exact page, however passing the value of the ID in the url? For example..
The user clicks ID 1, and brings them to something like:
http://mywebpage.com/index.pl?ID=1
Same Web page, but the end would be ID=2,etc..
Is this possible? And if so, how? I don't know what to Google for this Haha.
Thanks for any and all help!
I think the easiest way to do this would be to: Right click in the id field, go to properties, select "Action", click the radio button "Go to URL" - click in the expression and type ="http://mywebpage.com/index.pl?ID=" & Fields!ID.Value

How to generate adidional fields inside Yii form

I have:
Table "user"
id, username, password
Table "freedate"
id, user_id, start_date, end_date
Each user can have 1 or more (unlimited) number of "freedate" entries.
Now i have form with 2 text fields (username and password), and 2 date pickers (one for start date and another one for end date).
How can i enable user to inserd aditional datepicker pairs so they can enter as much of "freedate" entires as they need to?
I was wondering about insertind aditional button inside form, that would somehow create aditional fields when pressed, but u have no idea how to do it.
I don't need working example (even tho one would help ofc). What i need i suggestion from your own expirience if you had similar problem.
You can use javascript as noted above. Though that can get tricky to get the new fields associated with the datepicker.
You can also submit after each pair is entered. On returning back to form after save insert a new set of start/end date fields to the end of the form. This way they always have a freedate pair they can enter. (a bit slower overall)
You need javascript to generate these fields on the fly. Or a fixed amount of extra fields could be hidden and shown one by one using javascript as the user clicks the button. You would need to keep track of the number of fields being shown in a javascript var.
You need to write custom javascript in order to do that. It isn't hard, you would need to do something along these lines:
You need to create a button and, when that button gets clicked (onClick event or jquery click() function) you can add the html for your field (<input type=.... /> and so on to your form) and remember to use the correct name for these fields so that they get sent correctly when the user submits the form.

Show / Hide Fields in Pentaho Report Based on User Input

I'm trying to show / hide fields in a Pentaho report based upon user input.
For example, I would like to offer a checkbox to the user saying "Show Product Count" -- if the box is unchecked, it will not include that column in the report.
Is there a way to do this in Pentaho Report Designer, perhaps using Parameters?
Thanks for the help -Monica
Yes, you have half the answer. Have a Yes/No Parameter "ShowProductCount"
Then on the conditional fields, go to the visible property, click the + formula icon and enter:
=IF([ShowProductCount]="Yes"; TRUE(); FALSE())
Simple! :)
There is more to this that the above answer. For example, if you don't want a field to show on the report, you pass the value mentioned above by Codek but the field will not show but the space for it will. The field has to be in a BAND and the band layout has to be set to ROW. Also, on the field you want to not display or display based on user selection, you have to set that field's style properties under size & position - invisible-consumes-space = false.