You are on page 1of 10

Page |1

NAME: VINAY
DATIR REG. ID:
201080065
BRANCH: INFORMATION TECHNOLOGY
BATCH: C

SPATIAL & GRAPH DATABASES


LAB
EXPERIMENT 4

AIM:
pgAdmin - Postgres's Graphical User Interface

Perform following queries on the nyc database :

1. Read all records of nyc_census_blocks, nyc_homicide, nyc_neighborhoods,


nyc_streets, nyc_subway_stations and visualize the data by clicking on the geometry-
viewer icon available in the column header of the geometry data-type.

2. SELECT name, ST_Transform(geom, 4326) FROM nyc_neighborhoods;

3. Find the total length of all the streets in New York City.

4. Find the total area of New York City.

5. (a) What is the well-known text (WKT) of Broad Street subway station?

(b) What neighborhood intersects that subway station?

(c) What streets are within 10 meters of Broad Street subway station?

THEORY:
pgAdmin is a management tool for and derivative relational databases such as EDB Advanced Serv
PostgreSQL is a powerful, open-source object-relational database system. It has more than 15 years
It supports text, images, sounds, and video, and includes programming interfaces for C / C++, Java
PostgreSQL supports four standard procedural languages, which allows the users to write their own c
are - PL/pgSQL, PL/Tcl, PL/Perl and PL/Python.
PGAdmin is a web-based GUI tool used to interact with the Postgres database sessions, both locally a
PGAdmin to perform any sort of database administration required for a Postgres database.
Page |2

pgAdmin Interface

OUTPUT :
1. Read and Visualize the data of nyc_census_blocks :
Page |3

2. Read and Visualize the data of nyc_homicides :


Page |4

3. Read and Visualize the data of nyc_neighborhoods :


Page |5

4. Read and Visualize the data of nyc_streets :


Page |6

5. Read and Visualize the data of nyc_subway_stations :


Page |7

6. Read and Visualize the result of the query ->


( SELECT name,ST_Transform(geom,4326)
From nyc_neighborhoods;) :
Page |8

7. Total length of nyc_streets :


Page |9

8. Total Area of nyc :

9. Well Known Text(WKT) of Broad Street Subway Station :

10. Neighborhood which intersects Broad St. Subway


station :
Page |

11. Streets within 10m of Broad Street Subway Station :

CONCLUSION:
We have studied basic functionalities of pgAdmin and how to visualize data in
pgAdmin.

You might also like