Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Saturday, August 23, 2025 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Architect Forums - SalesLogix Scripting & Customization
Forum to discuss writing script in Architect plugins for SalesLogix & general SalesLogix customization topics (for Windows client only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Scripting & Customization | New ThreadView:  Search:  
 Author  Thread: Troublesome SQL in SLX Ticketing on V6.2
Chris
Posts: 6
 
Troublesome SQL in SLX Ticketing on V6.2Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 13 Mar 08 9:04 AM
Currently we are running version 6.2(.6), our system isn't heavily modified but we have a mid to large sized database. We have just activated ticketing out of the box and it's taking clients 40-90 seconds to open the ticket window. After digging through whats ran with SLX Profiler I turned up this gem:

SELECT A1.ATTACHID, A1.DESCRIPTION, A1.USERID, A1.ATTACHDATE, A1.FILESIZE, A1.TICKETID, A1.FILENAME FROM ATTACHMENT A1 WHERE A1.TICKETID = ?

This friendly little snippit seems to want a ticket ID and on initial load isn't getting one. Instead we're getting well in excess of 320,000 rows returned over the better part of a minute. I've dug everywhere and we had the help of a contractor digging everywhere, so now I'm genuinely stumped. We changed the navbar button to open in details view and still we get it. If anybody has any ideas where to tackle this I'd be greatly appreciated. (I can say the SQL disappears in later versions of SLX so someone, somewhere, must have noticed this.)

Thanks,
-Chris


-Sorry for the double post, twitchy finger.
[Reply][Quote]
Timmus Agersea
Posts: 328
 
Re: Troublesome SQL in SLX Ticketing on V6.2Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 14 Mar 08 2:01 PM
This is likely caused by the Attachments tab on the Ticket Main View. If you unbind the bindid of the datagrid on that form, it will not load when the form loads. You could then put a hidden textbox on the form that is bound to the Ticket.TicketID. Add an event to the onchange of that control that sets the bindid property of the grid to the text property of the textbox. I dont think you have to call Datagrid.Refresh as setting the bindid should load the data.

Timmus
[Reply][Quote]
Chris
Posts: 6
 
Re: Troublesome SQL in SLX Ticketing on V6.2Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 17 Mar 08 8:03 AM
Worked great! Thanks!
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Troublesome SQL in SLX Ticketing on V6.2Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 18 Mar 08 11:10 AM
Quote:
Originally posted by Timmus Agersea

If you unbind the bindid of the datagrid on that form, it will not load when the form loads. You could then put a hidden textbox on the form that is bound to the Ticket.TicketID. Add an event to the onchange of that control that sets the bindid property of the grid to the text property of the textbox.


Great idea Timmus. There's a few other OOTB grids in the system that this will help quite a bit in making them more usable.

-Ryan
[Reply][Quote]
Chris
Posts: 6
 
Re: Troublesome SQL in SLX Ticketing on V6.2Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 19 Mar 08 12:32 PM
grdAttach.SQL = "SELECT top 50 A1.ATTACHID, A1.DESCRIPTION, A1.USERID, A1.ATTACHDATE, A1.FILESIZE, A1.TICKETID, A1.FILENAME FROM ATTACHMENT A1 WHERE A1.TICKETID = '" & eTickID.Text & "'"

Tossed that in AXFORMCREATE/AXFORMCHANGE to prevent it from ever returning a couple hundred thousand rows from the database (under the assumption a ticket will very likely never have more than 50 attachments, but that can be adjusted to taste), used the hidden textbox linked the the ticket id and problem solved! Also a good fail safe incase for some reason that variable isn't filled. Works good for many grids in SLX too, so long as you know how many results to expect.
[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2025 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 8/23/2025 10:26:27 AM