Contributions
JDBC Prepared parameter that is comma separated used in another SQL query
My problem is similar to questionSQL Datasource Prepared Properties using a Property that is a comma separated list but with one difference: The Prepared property comes from another JDBC SQL Datasource: I have nested JDBC Datasources. The outer one returns the customerID and uses the DB2 listagg() function to list the customer's account_numbers, so say a customer with 3 accounts would look like this: '0010012345',111111,22222,333333 (Customer_id is a string and account numbers are integers). The inner DataSource uses 2Prepared Properties customerId and account_numbers and the WHERE clause includes: and T1.customer_id = :customerId and T1.account_Id IN (:account_numbers). This returns nothing. I have tried as the above question suggests to use quotes '0010012345',111111','22222','333333 but this does not work either. I "solved" my issue by making the outer datasource return one account per row, but this means I then call the API multiple times using the customer ID and one account per call (so for the above example I call the API 3 times) but that means I never get to call/test the API with multiple accounts.170Views0likes0CommentsRe: How can I interrupt a JDBC query
Thanks for taking the time to reply Rao. Greatly Appreciated. Different steps for different filters is out of the question, because then I'll need to maintain more scripts. Some of my scripts are very complicated with multiple CTEs, accessing data from 30-40 tables, with lots of case statements (even in where clauses) and window functions like ROW_NUMBER() OVER (PARTITION BY..), listagg() within group etc. The last thing I need is to have multiple versions of them 🙂 The commenting/uncommenting of course happens only during development or modifications. Otherwise I'm running tests for 1000s or records so the timeout reduction will not work. So, the short answer is: No, there is no practical way offered by the ReadyAPI query editor to interrupt a query (other tools like SSMS and SQL Workbench/J have a menu button and/or menu option to cancel the execution)2 years agoPlace ReadyAPI QuestionsReadyAPI Questions575Views0likes0CommentsRe: How can I interrupt a JDBC query
The "accident" happens more often than what I'd like to. As part of my WHERE clause I have a general: ORDER BY RAND() FETCH FIRST n ROWS ONLY -- Vary n to the number of customer IDs you want to test or ORDER BY customerId LIMIT x OFFSET y I also have above: AND custimerId IN ('xxxxxx','yyyyyy','zzzzzz') and I comment out one or the other to allow me to test multiple random, multiple sequential chunks or individual customerIds. So, if I'm testing an individual case so ORDER BY RAND() FETCH FIRST n ROWS ONLY is commented out, and then I want to test random customerIds, I comment the AND custimerId IN ('xxxxxx','yyyyyy','zzzzzz') and before I know it, I hit execute so I'm selecting ALL customerIds since both clauses are now commented out! 😞2 years agoPlace ReadyAPI QuestionsReadyAPI Questions583Views0likes0Comments- 2 years agoPlace ReadyAPI QuestionsReadyAPI Questions619Views0likes0Comments
How can I interrupt a JDBC query
I am using JDBC as datasource queries and usually return a limited number of rows (say customer IDs) for testing. In a couple of cases, after editing a query and re-running the test, I found that I accidentally commented out the limiting clause (say in DB2: Order by rand() fetch first 400 rows only) of my first CTE so the query is selecting every single customerId in the database and it takes forever to return any results! Is there a way in ReadyAPI (I'm using Ver 3.45.0) to somehow close the connection and interrupt the query, or stop/cancel the test? I've been closing ReadyAPI but this seems to be a bit extreme...620Views0likes7CommentsSQL editor does not scroll in ReadyAPI 3.43.1
Hi, I just updated my ReadyAPI to the latest version 3.43.1. Now I lost the ability to mouse-wheel-scroll, page Up/Down, arrow up/down and go to the end of any SQL scripts displayed in the SQL editor of Data Source test steps. The only way to modify an SQL script is to Select all: Ctrl+A, copy: C trl+C then paste it in another SQL editor, edit it and copy it back. The ReadyAPI SQL editor is already very restrictive as it only shows a few lines and you can't even make the editing box bigger. Now it's completely useless! Anybody else has this issue?323Views0likes0CommentsDoes anyone have experience with JWT (Jason Web Tokens) and/or 2 factor Authentication using OTP
I'm trying to automate the end to end testing for open banking. To do so I first need to create a URL using JWT authentication to log in onto a portal, enter the customer number and password, enter a one-time-password (OTP) received via email or mobile and give permission for my accounts to be accessed by other banks. Then using an access token generated by the above process I "pretend to be another bank app" and call APIs to retrieve information about the accounts: balances, transactions etc. I'm stuck... Security will not let me use gmail for OTP so I need to use a "virtual" mobile. I'm looking into Twilio... As far as JWT authentication via readyAPI ... I'm using ReadyAPI Ver 3.10.1 Any help would be really appreciated3 years agoPlace ReadyAPI QuestionsReadyAPI Questions325Views0likes0CommentsError when referencing java.util.stream
I'm trying to write some code to process One-Time-Passwords using APIs. I have to read the SMSs as a Stream so I "import java.util.stream" but I get a compilation error "unable to resolve class java.util.stream". If I "import java.util.*" then the compilation error moves to line 14 where I define the Stream: "unable to resolve class Stream @ line 14, column 1. def private Stream getMessages() { ^" Java docs say that java.util.stream has been around since java 1.8 Code sample: import com.twilio.* import java.util.*; import com.twilio.* import com.twilio.base.* import javax.jms.Message; //import java.util.*; //uncommented gives error at line 14 -see below import java.util.stream //compile error: "unable to resolve class java.util.stream" ; def public static String getMessage() { return getMessages().filter(m -> m.getDirection().compareTo(Message.Direction.INBOUND) == 0) .filter(m -> m.getTo().equals("+61999999")).map(Message::getBody).findFirst() .orElseThrow(IllegalStateException::new); } def private Stream getMessages() { //line 14 ResourceSet messages = Message.reader(SID).read(); return StreamSupport.stream(messages.spliterator(),false); } String SID="xxxxxx..." String AUTH_TOKEN= "yyyyyy...."3 years agoPlace ReadyAPI QuestionsReadyAPI Questions555Views0likes1CommentRe: Not able to install Postman plugin
I have the same issue. The above message says: "Unable to install plugin: Connection timed out." The messages I get are: "Unable to install the plugin: Connection reset" (when I set Proxy=off), and: "Unable to install the plugin: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 504 Gateway Timeout" (when I have Proxy= ON (automatic)). However, I was able to upgrade ReadyAPI from 3.6 to 3.10 just last week...3 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.3KViews0likes1Comment-Doauth2.access.token.retrieval.timeout= in .vmotions not working
I've been managing my own OAuth2 token renewals via code but since upgrading to 3.10 I get a compilation error "unable to resolve class" forimport com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2AzureClientFacade which is the main class used for getting a new token. However in the new features for 3.10 I noticed the new-Doauth2.access.token.retrieval.timeout vm setting. So I set-Doauth2.access.token.retrieval.timeout=300000 (300 seconds) and restarted ReadyApi. Soon after my tests started failing so I don't know if-Doauth2.access.token.retrieval.timeout works or not. My main question is, how do I get the first access token before my test starts running? Till now I used code in TestRunListener.beforeRun Event but this code does not work any more as it uses thecom.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2AzureClientFacade class.3 years agoPlace ReadyAPI QuestionsReadyAPI Questions347Views0likes0Comments