Hi LipTeck,
I can run that query you’ve provided me using the following code:
PS C:\Users\sbiggs> ipython
Python 3.8.2 (tags/v3.8.2:7b3ab59, Feb 25 2020, 23:03:10) [MSC v.1916 64 bit (AMD64)]
Type 'copyright', 'credits' or 'license' for more information
IPython 7.18.1 -- An enhanced Interactive Python. Type '?' for help.
In [1]: import pymedphys
In [2]: sql_string = "select Last_Name from staff where staff_role=0 and Machine_Type=1"
...:
...: with pymedphys.mosaiq.connect('msqsql') as cursor:
...: result = pymedphys.mosaiq.execute(cursor, sql_string)
...:
In [3]: result
Out[3]:
[('William ',),
('#william2 ',),
('William2 ',),
('Alice ',),
('Joe ',),
('ELE ',),
('2619 ',),
('2694 ',)]
Hope that helps :)
Also, can you please make new threads on the mailing list for queries unrelated to the original topic?
Cheers :),
Simon
From: LipTeck CHEW [mailto:liptec...@gmail.com]
Sent: Friday, 6 November 2020 11:32 AM
To: Simon Biggs
Cc: PyMedPhys; Simon Biggs
Subject: Re: PyMedPhys Activity Report -- The new PyMedPhys GUI
Hi Simon
Could you show me the way to run this SQL query CML inside pymedphys?
select Last_Name from staff where staff_role=0 and Machine_Type=1
From Mosaiq, the linac name is VersaHD. It is 3316 inside the TRF. Hope this can verify.
Regards
LipTeck
On Mon, 2 Nov 2020 at 1:23 PM, Simon Biggs <sbi...@riverinacancercare.com.au> wrote:
Hi LipTeck,
I have attempted to automatically bypass this if that issue occurs. Would you be able to try the new dev release and see if that works?
pip install pymedphys[user]==0.34.0-dev6
Cheers,
Simon
--
You received this message because you are subscribed to the Google Groups "PyMedPhys" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pymedphys+...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/pymedphys/CA%2B5_vkOYr1DZ5R%3D6cLNUzKwFS7zUa_10fZQ7x0Q7FBFW4CWSOg%40mail.gmail.com.