EPICS Home

Experimental Physics and Industrial Control System


 
2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  <20232024  2025  Index 2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  <20232024  2025 
<== Date ==> <== Thread ==>

Subject: Re: Create NTTable from JSON
From: Michael Davidsaver via Core-talk <core-talk at aps.anl.gov>
To: Karl Vestin <karl.vestin at ess.eu>
Cc: "core-talk at aps.anl.gov" <core-talk at aps.anl.gov>
Date: Wed, 5 Apr 2023 16:49:26 -0700
Hi Karl,

On 4/5/23 06:25, Karl Vestin via Core-talk wrote:
Dear all,

Are there any functions available to generate a NTTable from a JSON object or JSON schema? I have found a function to generate JSON from a PVObject, but not the other way around.

P4P has a helper which attempts to transpose a list of objects to a set of arrays needed
by NTTable.  My original idea was python RDB interactions.  A list of objects should be
similar enough to a database cursor, although I haven't done much testing.

https://github.com/mdavidsaver/p4p/blob/master/example/json_server.py

I don't recall ever doing anything with JSON schemas.  So I don't know what libraries
are available.  I don't think the builtin 'json' package handles these.  Something like
a schema might be a way to avoid needing to programmatically specify the column names and
data types.


References:
Create NTTable from JSON Karl Vestin via Core-talk

Navigate by Date:
Prev: Build failed: EPICS Base 7 base-7.0-896 AppVeyor via Core-talk
Next: [Bug 2015234] Re: newline problem with genVersionHeader.pl Dirk Zimoch via Core-talk
Index: 2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  <20232024  2025 
Navigate by Thread:
Prev: Re: Create NTTable from JSON Veseli, Sinisa via Core-talk
Next: Build failed: EPICS Base 7 base-7.0-896 AppVeyor via Core-talk
Index: 2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  <20232024  2025