SQL View

PS Query will automatically generate SQL based on how you design your query.

When you go to the "View SQL" tab, you can see the SQL code.

You cannot modify the SQL from this page.

Basics of SQL syntax

Oracle/PeopleSoft utilizes a subset of SQL standard functions
Simply, SQL is a set of instructions listing the SELECT on of specific fields, FROM specific tables WHERE certain circumstances exist.

  • SELECT: lists fields or column names used in the query
  • FROM: lists tables or records used in the query
  • WHERE: lists filters to include or exclude data

Back to top

Distinct

When you wish to have a row of data appear only once—even though it may meet the criteria more than once—use the DISTINCT criteria. Distinct removes duplicate rows of output from the results.  

Suppose you want a query that does not show every prospect, but you're interested in the last school attended for each career. 

Without Distinct


With Distinct


Career

Lst School

Career

Lst School

GRAD


GRAD


GRAD

000000001

GRAD

000000001

UGRD

000000001

MEDS

000000001

UGRD

000000001

UGRD


UGRD

000000001

UGRD

000000001

UGRD

000000001

UGRD

000010005

UGRD

000000001

UGRD

000010008

UGRD

000000001

UGRD

000010009

UGRD




GRAD

000000001



UGRD

000000001



UGRD

000010009



UGRD

000010005



UGRD

000010008



UGRD

000010009




*more*




To set a query to "distinct" mode, click the Properties link and check the Distinct checkbox. 

Back to top

Attachments:

worddav20ca24f1745f7952afd6b86e7b3a051e.png (image/png)
worddav106b3a16570909675c126fd87fd969dd.png (image/png)
worddav838ada6d9adc4cc07c776858afe6b2a3.png (image/png)
worddav979b0450b42d4a433fcf655cc6d5042c.png (image/png)
worddav3695d423d3acf4a4ed5412c2d8523a3d.png (image/png)
worddavf75602d73d57b8d05391c695f5cce461.png (image/png)
worddave9300a881e6c5d71350cb97cc44448a4.png (image/png)
worddav2737ea365897202b5c7a55614feb648e.png (image/png)
worddave8d4e106096e189031efafe9f16ae0f1.png (image/png)
worddavc547c88e96b9ff107b7412f56f7bc489.png (image/png)
worddav913e3e33618d11297c1e285a919ff95e.png (image/png)
worddav616c84c248a37076181c4a553721a86b.png (image/png)
worddave79d9eb36e8c59211ee56cc57aaf89d8.png (image/png)
worddavd4a640e4cffb5be3812ce989cc6c3381.png (image/png)
worddavb6b4f7fafdbf85d6119993384a9e2442.png (image/png)
worddav5098cb76cec007cb1e9b1da6f0688759.png (image/png)
worddavacc30bb267fb06136404567521b41453.png (image/png)
worddavd54fb5f1f40e279485b6afb1a411edf5.png (image/png)
worddavfe8c8c5e5948385050b4edb2501a236a.png (image/png)
worddavf5ef63d8ca055318e3f7242fb756c30e.png (image/png)
worddavc0bb04fbab1d3b78c09e44565130bd79.png (image/png)
worddav95e655de2123635d1208e6835752689a.png (image/png)
worddavb6e22efa1f98b4319b74d5e51a3a1604.png (image/png)
worddav27117601dd8334f4e0497fe1d48491ae.png (image/png)
worddav673734001cc59f05451124d81fcdb6d7.png (image/png)
worddav47c2648af7ea095db48c07a5f59d2ec0.png (image/png)
worddav34f2dd77ee11ce0cc120dac83b038e2c.png (image/png)
worddav26ce96367c0baddfc65a39521a535988.png (image/png)
worddav7379d7eb630747dca53d7a612b50c611.png (image/png)
worddav6f7fda11df05b47cd74862ec14298216.png (image/png)
worddavf60f58be0c804af767e89c26e06c09a4.png (image/png)
worddava0f33f7d59dd286e1c16b28d0259a0e6.png (image/png)
worddavbe24a01d465e6c9adcf708ac079ce60d.png (image/png)
worddavdbe8793532f8f8b6005c1f53382095fd.png (image/png)
worddav06bf3599167d58df613565d8ce2d568c.png (image/png)
worddav7fc2e7eb2ed0bd792841f797bce6d4d7.png (image/png)
worddav844ca67051abae31657694a949dbf5f0.png (image/png)
worddav647036642ca76b98d52581c0ffa26696.png (image/png)
worddava894fac2531533c55f62c464929bab6d.png (image/png)
worddav9afcec107ff7bbb4e5d4046a7caa85ba.png (image/png)
worddav24f187d98e87aa2308738207f767b8dc.png (image/png)
worddavd3aa6678679b03909505e8c7cecf1eee.png (image/png)
worddav1f07f315e9f5da9905219c1feeebf613.png (image/png)
worddav7710af73687b7a850ef734a80d0e0c5e.png (image/png)
worddavd16a03c4d1b6ffe5ee9c5e49f28a820d.png (image/png)
worddavd7054fd42ea816b929bc18dc54e2dbeb.png (image/png)
worddavda25205d93d0a9b61803df6a3c474e9b.png (image/png)
worddavc3a5d99bea7c2d43e2e66dc620b034d7.png (image/png)
worddav36e8b288c51b0cdeed3d5199931a3719.png (image/png)
worddav4159b99c2530482073ee71e340c4183c.png (image/png)
worddav91437d78072e7de44046479ce8949783.png (image/png)
worddav5d4a8badbfd280cf84b5aaf5d02ad9e9.png (image/png)
worddav74a308b13873c96e7447c68c6b54765a.png (image/png)
worddavdb4a04410be2d81ca988327595924465.png (image/png)
worddav0568c48bfb80c1bf702d4d666a4d74ef.png (image/png)
worddaved652bf08e7c81af5468b1e7fed51220.png (image/png)
worddav1cebc6d5da6fe3242973b34a643d801b.png (image/png)
worddav495dc69a9bac7d24771ec4eb4320d362.png (image/png)
worddav570c712f17bdfebea18639c9569c3d45.png (image/png)
worddavc1f27e6433247945a9cefcd68a7c1dbb.png (image/png)
worddav7f390470e434bf220635d72da90d4617.png (image/png)
worddav0684ee5e4479aa525ac700507cab4b0b.png (image/png)
worddav10fad5d0aa71e1cdac0e4fa8964ab33c.png (image/png)
worddav17ae38336472d78c06a3dcf258e07919.png (image/png)
worddav6d34de831429f0eca05691d7873c7bb6.png (image/png)
worddav5111862e6c5ca03aacd77a741ea8946a.png (image/png)
worddav6bf427ff78ad7ef63d8fdcadbc958a2d.png (image/png)
worddavbe8762541d9f53311b8330bae33e2e1c.png (image/png)
image2022-3-24_13-59-4.png (image/png)
image2022-3-25_9-4-59.png (image/png)
Help-button-800px.png (image/png)