Display Capture Geometry Attributes inserted in Sql Non Query
Good Morning! I am working on a workflow that allows a user to select an area of road segments using a Display Capture Geometry Activity, creates a feature set using a Query Task, displays a Display Form so the user can enter the status of the road segments (Open or Closed), and then that info gets inserted into a SQL table. That table has a 'Status' field, which is being pulled into a view, which is what the map is point at. So, when a 'Closed' status is entered by a user, the view sees that status change in the table and the road should turn red.
I have the skeleton of the workflow created but am having difficulty getting the info inserted correctly into the SQL table. In theory, the roadlink field should be populated with the OBJECTID's of all of the road segments that were selected from the Display Capture Geometry activity...
_img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=90660000000Ckj0&feoid=Body&refid=0EM600000001TYA"_/_img_
Ideas? My workflow is below...
https://drive.google.com/file/d/0B9MJ7nq1HIUCNEwxR2liSEotRTQ/view?usp=sharing
0
-
Hi Lisa,
Looking at your workflow it looks like your providing the @objectid variable with a NULL value, nothing has been assigned the objectid in your variable list. I would have expected to see the OBJECTID returned from the Query Activity from earlier in the workflow.
On that note, if you only need the OID returned from the query I would suppled the out fields of the activity to be "OBJECTID". Then use featureSetInitialSelection.Features(0).Attributes("OBJECTID") as the value that you assign to the @objectid parameter that you use in you SQL activity.
Warren0 -
Ah upon, re-reading this you'll need to use a loop within your workflow as your selection polygon contains a number of street segements... 0 -
Hi Warren, thank you for the suggestion. I 've added the featureSetInitialSelection.Features(0).Attributes("OBJECTID") to the parameters in the SQL Non-Query activity:
_img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=90760000000GsCQ&feoid=Body&refid=0EM60000000UkKp" _/_img_
but I am now getting this error:
_img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=90760000000GsCQ&feoid=Body&refid=0EM60000000UkKk"_/_img_
which I've discovered is because I am trying to enter an 'object' data type into an integer field in the SQL database:
_img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=90760000000GsCQ&feoid=Body&refid=0EM60000000UkKu"_/_img_
Do you have any suggestions on how to convert the OBJECTID Object to an integer in order to insert it into the SQL table?
And using a loop to process multiple line segements will be a whole other struggle! One problem at a time though!
Thank you!0 -
Use CInt(featureSetInitialSelection.Features(0).Attributes("OBJECTID"))0
Please sign in to leave a comment.
Comments
4 comments