Hi. Our intention is create a console app (C#) using EntitySchemaQuery that query an entity (like Account or Contact) and gets its rows to populate a local table. We are trying to connect our bpmonline using this example: source: https://www.bpmonline.cz/bpmonlinesdken/UsingEntitySchemaQuery.html ////////// // Creating a query instance, adding columns and a data source in the query. Select selectQuery = new Select(UserConnection) .Column("Id") .Column("Name") .From("Contact"); // Executing a database query and getting the resulting dataset. using (DBExecutor dbExecutor = UserConnection.EnsureDBConnection()) { using (IDataReader reader = selectQuery.ExecuteReader(dbExecutor)) { while (reader.Read()) { // Handling the query results. } } }
/////////////
The problem is we do not know how to create the connection string (UserConnection) to our cloud services, https://mycompany.bpmonline.com.
How to create this UserConnection? Someone has an example or may guide us?
Like
Theoretically, it's possible to use bpm'online local .dll-s and create the connection. However, it's very hard and usually pointless. If you need to get data from bpm'online, please create a web service in bpm'online. The service should get the needed data and give it to the requested.
This is how to create a service.
https://academy.bpmonline.com/documents/technic-sdk/7-14/creating-configuration-service
This is how to log in and call it
https://academy.bpmonline.com/documents/technic-sdk/7-14/executing-odata-queries-using-fiddler
Eugene Podkovka writes:
However, it's very hard and usually pointless.
I don't think it's useless.
I'm trying to achieve the same goal to increase our developers' productivity.
We usually use task script in the process designer to manipulate data using EntitySchemaQuery.
Each time, we have to update the process, run it and check the log or attach visual studio debugger (which is painful) to verify our code.
Imagine if we are able to get a UserConnection instance directly into a standalone app. we can test our functions faster and increase the overall productivity.
@Eugene Podkovka: can you please help us!
Thank you
Mohamed
We can use this approach!
https://academy.creatio.com/documents/technic-sdk/7-15/developing-configuration-server-code-user-project
Thank you
Mohamed