Help Desk Rules forum?
Is there any plan to create a custom help desk rules forum? I've got a ton of useful stuff to share. The Reports forum is great! However, it would be nice if a few other forums were created as well - Assets, Help Desk (maybe even break out Custom SQL Rules as a sub-forum), Security, Scripting, etc.
1 Comment
[ + ] Show comment
Answers (11)
Please log in to answer
Posted by:
bkelly
14 years ago
Posted by:
GillySpy
14 years ago
Posted by:
airwolf
14 years ago
Posted by:
snissen
14 years ago
Hey, airwolf, since you asked for people writing help desk rules...
I want to write custom SQL that updates a custom inventory field in the ASSET_DATA_5 table from a field in the corresponding record in the MACHINE table, as linked through the corresponding ASSET table record. (BTW, why am I doing this? I'm trying to set up for a periodic Computer Asset import based on serial number.)
Now, I can write the correct SELECT query for this, and I refined and tested it using MySQL Workbench, thanks to your first blog article. I can see from the SELECT query that I'm getting the correct data with the correct table relationships.
I can't test the actual UPDATE query with its SET clause, because MySQL Workbench doesn't have write access to the database. But I'm pretty sure I have the syntax of the UPDATE query correct, because I've written quite a few UPDATE queries before in various SQLs, and because the equivalent UPDATE query works in a mirror database in Microsoft Access.
So what am I asking you? I'm not sure how to fill in the Ticket Rule : Edit Detail screen. I know my UPDATE query goes into the "Update Query" textbox, but what do I put in the "Select Query" textbox, since I'm not doing anything related to tickets? Do you have any rules that use custom SQL to update something not related to tickets? If so, could you post an example here?
I think that's where my problem lies, because when I try to run the rule with the "Select Query" textbox empty, I get an error message, something about 0 records returned in the Select Query EXECUTE(). (I'll have to get the exact error message on Sunday night, and I'll post it here.)
Any examples, or any advice, would be greatly appreciated. I may not be feeling so adventurous by next week... Sande
I want to write custom SQL that updates a custom inventory field in the ASSET_DATA_5 table from a field in the corresponding record in the MACHINE table, as linked through the corresponding ASSET table record. (BTW, why am I doing this? I'm trying to set up for a periodic Computer Asset import based on serial number.)
Now, I can write the correct SELECT query for this, and I refined and tested it using MySQL Workbench, thanks to your first blog article. I can see from the SELECT query that I'm getting the correct data with the correct table relationships.
I can't test the actual UPDATE query with its SET clause, because MySQL Workbench doesn't have write access to the database. But I'm pretty sure I have the syntax of the UPDATE query correct, because I've written quite a few UPDATE queries before in various SQLs, and because the equivalent UPDATE query works in a mirror database in Microsoft Access.
So what am I asking you? I'm not sure how to fill in the Ticket Rule : Edit Detail screen. I know my UPDATE query goes into the "Update Query" textbox, but what do I put in the "Select Query" textbox, since I'm not doing anything related to tickets? Do you have any rules that use custom SQL to update something not related to tickets? If so, could you post an example here?
I think that's where my problem lies, because when I try to run the rule with the "Select Query" textbox empty, I get an error message, something about 0 records returned in the Select Query EXECUTE(). (I'll have to get the exact error message on Sunday night, and I'll post it here.)
Any examples, or any advice, would be greatly appreciated. I may not be feeling so adventurous by next week... Sande
Posted by:
airwolf
14 years ago
If your update query works standalone, then you can put any query in the "Select query" box - as long as it returns results. For example, SELECT * FROM HD_TICKET. Whatever you use MUST return results in order for the Update Query to be run.
The purpose of the Select query statement is to pass ticket IDs to the Update Query (i.e. filter results in your select query, and then pass the IDs to the update query using <TICKET_IDS>. This allows you to make a very simple update query - you're basically splitting the work in to two pieces). You can also use this to pass other data to the Update Query, but you have to "trick" it into moving data by naming whatever column you want data from to "ID".
The purpose of the Select query statement is to pass ticket IDs to the Update Query (i.e. filter results in your select query, and then pass the IDs to the update query using <TICKET_IDS>. This allows you to make a very simple update query - you're basically splitting the work in to two pieces). You can also use this to pass other data to the Update Query, but you have to "trick" it into moving data by naming whatever column you want data from to "ID".
Posted by:
snissen
14 years ago
[font="trebuchet ms"]Got it! My rule now puts the serial number from the MACHINE table into a custom inventory field in the ASSET_DATA_5 table, as linked through the corresponding ASSET table record. Thanks, Andy!
I really appreciate a system that lets me store and schedule UPDATE queries on any table. In other systems without this capability, I spend a lot of time with Access queries I have to run manually. Thanks, KACE!
I really appreciate a system that lets me store and schedule UPDATE queries on any table. In other systems without this capability, I spend a lot of time with Access queries I have to run manually. Thanks, KACE!
Posted by:
JesseLara
14 years ago
If I am reading this correctly ( hopefully I am ) you are using items he client reports normally to fill in field(s) in the asset detail for custom fields?
I would love to see how you would be able to edit to fill in other fields as I would find this immensely useful. I currently have several custom fields I have to hand enter that is already reported by the client that I would LOVE to see automatically filled in for me such as model and chassis type.
Thanks!
I would love to see how you would be able to edit to fill in other fields as I would find this immensely useful. I currently have several custom fields I have to hand enter that is already reported by the client that I would LOVE to see automatically filled in for me such as model and chassis type.
Thanks!
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.
Thank you! - svmay 8 years ago