Exemplo n.º 1
0
eq = EQread(conn)
pr = PRread(conn)
ep = EPread(conn)
ei = EIread(conn)
la = LAread(conn)
r = Rread(conn)
cv = CVread(conn)
s = Sread(conn)




print "Get all equipment: " ,eq.getAllEquipment()
print "Get all dataquality: " ,dq.getAllDataQuality()
print "Get all variable: " ,cs.getAllVariables()
print "Get all People: " ,cs.getAllPerson()#[0].PersonFirstName
print "Get all sites: " , sf.getAllSites()
print "Get all SamplingFeatures: ", cs.getAllSamplingFeature()
print "Get  SamplingFeatures by code: ",cs.getSamplingFeatureByCode(u'logan_river_outlet')



#shows that you can manipulate geometries within the code
#I can get back a union of two geometries( currently the Same Geometry),
#and convert from a string to Geometry type if it is in WKT

#Code that is being run
#Geom = self._session.query(Samplingfeature).first()
#TestGeom = "POINT (30 10)"
#GeomText = self._session.query(func.ST_Union(Geom.FeatureGeometry,func.ST_GeomFromText(TestGeom)).ST_AsText()).first()