by Dinesh Thakur Category: DataBase

Visual Basic uses Structured Query Language (SQL) to create new dynasets. SQL is an Industrial Standard language for processing relational database.

 

Visual Basic uses SQL to create new recordsets.Set the data controls RecordSource property to an SQL query and execute a Refresh method

Visual Basic use SQL to select fields and records from a table and join the fields from row tables.

 

Syntax:

 

Select [ distinct ] FieldList From TableNames

Where SearchConditions

Group By FieldList

Having GroupCriteria

Order By FieldList

 

Example:

 

Select * From Books

Select * From Books, Subjects

Where Books.Subject_Code = Subjects.SubjectCode

Order By Title

Select Distinct Author from Books

 





About Dinesh Thakur

Dinesh ThakurDinesh Thakur holds an B.SC (Computer Science), MCSE, MCDBA, CCNA, CCNP, A+, SCJP certifications. Dinesh authors the hugely popular blog. Where he writes how-to guides around Computer fundamental , computer software, Computer programming, and web apps. For any type of query or something that you think is missing, please feel free to Contact us.